aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite
diff options
context:
space:
mode:
authorJanus Weil <janus@gcc.gnu.org>2010-11-08 10:03:50 +0100
committerJanus Weil <janus@gcc.gnu.org>2010-11-08 10:03:50 +0100
commit78a1d1490cc83f1444331c97121ad24fc6918513 (patch)
tree2a7aa681cd656adfd69e781f5887991ff2d95d3c /gcc/testsuite
parent06f0c25f2509d20b1245697670108fc3f990cdac (diff)
downloadgcc-78a1d1490cc83f1444331c97121ad24fc6918513.zip
gcc-78a1d1490cc83f1444331c97121ad24fc6918513.tar.gz
gcc-78a1d1490cc83f1444331c97121ad24fc6918513.tar.bz2
re PR fortran/46344 ([OOP] ICE with allocatable CLASS components)
2010-11-08 Janus Weil <janus@gcc.gnu.org> PR fortran/46344 * trans-types.c (gfc_copy_dt_decls_ifequal): Handle CLASS components. 2010-11-08 Janus Weil <janus@gcc.gnu.org> PR fortran/46344 * gfortran.dg/class_28.f03: New. From-SVN: r166430
Diffstat (limited to 'gcc/testsuite')
-rw-r--r--gcc/testsuite/ChangeLog5
-rw-r--r--gcc/testsuite/gfortran.dg/class_28.f0330
2 files changed, 35 insertions, 0 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 28d05af..395d987 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,8 @@
+2010-11-08 Janus Weil <janus@gcc.gnu.org>
+
+ PR fortran/46344
+ * gfortran.dg/class_28.f03: New.
+
2010-11-08 Andrey Belevantsev <abel@ispras.ru>
PR rtl-optimization/45352
diff --git a/gcc/testsuite/gfortran.dg/class_28.f03 b/gcc/testsuite/gfortran.dg/class_28.f03
new file mode 100644
index 0000000..cfd46a8
--- /dev/null
+++ b/gcc/testsuite/gfortran.dg/class_28.f03
@@ -0,0 +1,30 @@
+! { dg-do compile }
+!
+! PR 46344: [4.6 Regression] [OOP] ICE with allocatable CLASS components
+!
+! Contributed by Salvatore Filippone <sfilippone@uniroma2.it>
+
+module m
+
+ type t1
+ end type
+
+ type t2
+ class(t1), allocatable :: cc
+ end type
+
+ class(t2), allocatable :: sm
+
+end module m
+
+program p
+ use m
+ implicit none
+
+ type(t2), allocatable :: x(:)
+
+ allocate(x(1))
+
+end program p
+
+! { dg-final { cleanup-modules "m" } }