diff options
Diffstat (limited to 'gcc-4.9/gcc/testsuite/gfortran.dg/array_constructor_48.f90')
-rw-r--r-- | gcc-4.9/gcc/testsuite/gfortran.dg/array_constructor_48.f90 | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/gcc-4.9/gcc/testsuite/gfortran.dg/array_constructor_48.f90 b/gcc-4.9/gcc/testsuite/gfortran.dg/array_constructor_48.f90 new file mode 100644 index 000000000..5916eddf8 --- /dev/null +++ b/gcc-4.9/gcc/testsuite/gfortran.dg/array_constructor_48.f90 @@ -0,0 +1,17 @@ +! { dg-do compile } +! +! PR fortran/57549 +! +! Contributed by Vladimir Fuka +! + type t + end type + type(t),allocatable :: a(:) + a = [t::t()] + print *, [ integer :: ] +end + +subroutine invalid() + print *, [ type(integer) :: ] ! { dg-error "Syntax error in array constructor" } + print *, [ type(tt) :: ] ! { dg-error "Syntax error in array constructor" } +end subroutine invalid |