2 ! Check "double" allocations of allocatable components (PR 20541).
4 ! Contributed by Erik Edelmann <eedelmann@gcc.gnu.org>
5 ! and Paul Thomas <pault@gcc.gnu.org>
12 integer, dimension(:), allocatable
:: array
15 type(foo
),allocatable
,dimension(:) :: mol
16 type(foo
),pointer,dimension(:) :: molp
20 allocate (mol(1), stat
=i
)
22 if (i
== 0) call abort()
24 allocate (mol(1)%array(5))
25 allocate (mol(1)%array(5),stat
=i
)
27 if (i
== 0) call abort()
30 allocate (molp(1), stat
=i
)
32 if (i
/= 0) call abort()
34 allocate (molp(1)%array(5))
35 allocate (molp(1)%array(5),stat
=i
)
37 if (i
== 0) call abort()