PR inline-asm/84742
[official-gcc.git] / gcc / testsuite / gfortran.dg / generic_22.f03
blob040fddd95f0bc56cf64ebc71f16fdf5e5a60f992
1 ! { dg-do compile }
2 ! Test the fix for PR43492, in which the generic call caused and ICE.
4 ! Contributed by Salvatore Filippone <sfilippone@uniroma2.it>
6 module base_mod
7   
8   type  :: base_mat
9     integer, private     :: m, n
10   contains 
11     procedure, pass(a) :: transp1 => base_transp1
12     generic, public    :: transp => transp1
13     procedure, pass(a) :: transc1 => base_transc1
14     generic, public    :: transc => transc1
15   end type base_mat
17 contains
19   subroutine base_transp1(a)
20     implicit none 
21     
22     class(base_mat), intent(inout) :: a
23     integer :: itmp
24     itmp        = a%m
25     a%m         = a%n
26     a%n         = itmp
27   end subroutine base_transp1
28   subroutine base_transc1(a)
29     implicit none 
30     class(base_mat), intent(inout) :: a
31     
32     call a%transp() 
33 !!$    call a%transp1() 
34   end subroutine base_transc1
37 end module base_mod