diff options
Diffstat (limited to 'gcc/testsuite/gfortran.dg/module_commons_2.f90')
-rw-r--r-- | gcc/testsuite/gfortran.dg/module_commons_2.f90 | 21 |
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 000000000..3c3214c20 --- /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" } } |