PR inline-asm/84742
[official-gcc.git] / gcc / testsuite / gfortran.dg / class_11.f03
blobbf80c4e00e61fb66abd1495e8d32feeace784de1
1 ! { dg-do compile }
3 ! PR 41556
4 ! Contributed by Damian Rouson <damian@rouson.net>
6   implicit none
8   type ,abstract :: object
9   contains
10     procedure(assign_interface) ,deferred :: assign   
11     generic  :: assignment(=) => assign
12   end type 
14   abstract interface
15     subroutine assign_interface(lhs,rhs) 
16       import :: object 
17       class(object) ,intent(inout) :: lhs
18       class(object) ,intent(in)    :: rhs
19     end subroutine 
20   end interface
22 ! PR 41937
23 ! Contributed by Juergen Reuter <reuter@physik.uni-freiburg.de>
25   type, abstract :: cuba_abstract_type
26      integer :: dim_f = 1
27      real, dimension(:), allocatable :: integral
28   end type cuba_abstract_type
30 contains
32     subroutine cuba_abstract_alloc_dim_f(this)
33       class(cuba_abstract_type) :: this
34       allocate(this%integral(this%dim_f))
35     end subroutine cuba_abstract_alloc_dim_f
37 end