diff options
Diffstat (limited to 'gcc/testsuite/gfortran.dg/size_dim.f90')
-rw-r--r-- | gcc/testsuite/gfortran.dg/size_dim.f90 | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/gcc/testsuite/gfortran.dg/size_dim.f90 b/gcc/testsuite/gfortran.dg/size_dim.f90 new file mode 100644 index 000000000..9d3938ed0 --- /dev/null +++ b/gcc/testsuite/gfortran.dg/size_dim.f90 @@ -0,0 +1,15 @@ +! { dg-do run } +! Check size with initialization expression value for dim= +! PR fortran/30882 +! +! Contributed by Joost VandeVondele <jv244@cam.ac.uk> +! +program main + integer :: a(10) + call S1(a) +contains + subroutine S1(a) + integer :: a(*) + if(size(a(1:10),1) /= 10) call abort() + end subroutine S1 +end program main |