1 ! Copyright 2019-2020 Free Software Foundation, Inc.
3 ! This program is free software; you can redistribute it and/or modify
4 ! it under the terms of the GNU General Public License as published by
5 ! the Free Software Foundation; either version 3 of the License, or
6 ! (at your option) any later version.
8 ! This program is distributed in the hope that it will be useful,
9 ! but WITHOUT ANY WARRANTY; without even the implied warranty of
10 ! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 ! GNU General Public License for more details.
13 ! You should have received a copy of the GNU General Public License
14 ! along with this program. If not, see <http://www.gnu.org/licenses/>.
19 type, public :: Number
22 procedure :: get => get_number
23 procedure :: set => set_number
28 function get_number (this) result (val)
29 class (Number), intent (in) :: this
32 end function get_number
34 subroutine set_number (this, val)
35 class (Number), intent (inout) :: this
38 end subroutine set_number
40 end module some_module
42 logical function is_bigger (a,b)
43 integer, intent(in) :: a
44 integer, intent(in) :: b
46 end function is_bigger
48 subroutine say_numbers (v1,v2,v3)
49 integer,intent(in) :: v1
50 integer,intent(in) :: v2
51 integer,intent(in) :: v3
53 end subroutine say_numbers
59 integer function fun1 (x)
63 integer function fun2 (x)
71 procedure(fun1), pointer:: fun_ptr => NULL()
73 call say_numbers (1,2,3) ! stop here
78 integer function fun1 (x)
84 integer function fun2 (x)