summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gfortran.dg
diff options
context:
space:
mode:
authorpault <pault@138bc75d-0d04-0410-961f-82ee72b054a4>2008-03-09 19:38:51 +0000
committerpault <pault@138bc75d-0d04-0410-961f-82ee72b054a4>2008-03-09 19:38:51 +0000
commitf714d9043912838b2e89275ff36c0bc148b5940a (patch)
treef16e6056a26aa61c3d1da107510fbc2a9e3df577 /gcc/testsuite/gfortran.dg
parent2c3b9819e0da54d2cfab55c2e8d16d6364692ce3 (diff)
downloadgcc-f714d9043912838b2e89275ff36c0bc148b5940a.tar.gz
2008-03-09 Paul Thomas <pault@gcc.gnu.org>
PR fortran/35474 * module.c (mio_symtree_ref): After providing a symbol for a missing equivalence member, resolve and NULL the fixups. 2008-03-09 Paul Thomas <pault@gcc.gnu.org> PR fortran/35474 * gfortran.dg/module_commons_2.f90 : New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@133063 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite/gfortran.dg')
-rw-r--r--gcc/testsuite/gfortran.dg/module_commons_2.f9021
1 files changed, 21 insertions, 0 deletions
diff --git a/gcc/testsuite/gfortran.dg/module_commons_2.f90 b/gcc/testsuite/gfortran.dg/module_commons_2.f90
new file mode 100644
index 00000000000..3c3214c20ff
--- /dev/null
+++ b/gcc/testsuite/gfortran.dg/module_commons_2.f90
@@ -0,0 +1,21 @@
+! { dg-do compile }
+! Tests the fix for PR35474, in which the PRIVATE statement would
+! cause the error Internal Error at (1): free_pi_tree(): Unresolved fixup
+! This arose because the symbol for 'i' emanating from the COMMON was
+! not being fixed-up as the EQUIVALENCE was built.
+!
+! Contributed by FX Coudert <fxcoudert@gcc.gnu.org>
+!
+module h5global
+ integer i
+ integer j
+ common /c/ i
+ equivalence (i, j)
+ private
+end module h5global
+
+program bug
+ use h5global
+end
+
+! { dg-final { cleanup-modules "h5global" } }