summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gfortran.dg/allocate_alloc_opt_7.f90
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/gfortran.dg/allocate_alloc_opt_7.f90')
-rw-r--r--gcc/testsuite/gfortran.dg/allocate_alloc_opt_7.f9018
1 files changed, 18 insertions, 0 deletions
diff --git a/gcc/testsuite/gfortran.dg/allocate_alloc_opt_7.f90 b/gcc/testsuite/gfortran.dg/allocate_alloc_opt_7.f90
new file mode 100644
index 000000000..e77f6b7c6
--- /dev/null
+++ b/gcc/testsuite/gfortran.dg/allocate_alloc_opt_7.f90
@@ -0,0 +1,18 @@
+! { dg-do compile }
+!
+! PR 44207: ICE with ALLOCATABLE components and SOURCE
+!
+! Contributed by Hans-Werner Boschmann <boschmann@tp1.physik.uni-siegen.de>
+
+program ice_prog
+
+type::ice_type
+ integer,dimension(:),allocatable::list
+end type ice_type
+
+type(ice_type)::this
+integer::dim=10,i
+
+allocate(this%list(dim),source=[(i,i=1,dim)])
+
+end program ice_prog