2 ! { dg-options "-std=f2003" }
9 integer, allocatable
:: i(:), j(:)
10 real, allocatable
:: x(:)
16 allocate(i(4), source
=42, source
=n
) ! { dg-error "Redundant SOURCE tag found" }
18 allocate(integer(4) :: i(4), source
=n
) ! { dg-error "conflicts with the typespec" }
20 allocate(i(4), j(n
), source
=n
) ! { dg-error "Fortran 2008: SOURCE tag at .1. with more than a single allocate object" }
22 allocate(x(4), source
=n
) ! { dg-error "type incompatible with" }
24 allocate(i(4), source
=m
) ! { dg-error "must be scalar or have the same rank" }
26 allocate(i(4), source
=k
) ! { dg-error "shall have the same kind type" }