diff options
Diffstat (limited to 'gcc/testsuite/gfortran.dg/pr83149_1.f90')
-rw-r--r-- | gcc/testsuite/gfortran.dg/pr83149_1.f90 | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/gcc/testsuite/gfortran.dg/pr83149_1.f90 b/gcc/testsuite/gfortran.dg/pr83149_1.f90 new file mode 100644 index 00000000000..3a8f5d55d9b --- /dev/null +++ b/gcc/testsuite/gfortran.dg/pr83149_1.f90 @@ -0,0 +1,24 @@ +! Compiled with pr83149.f90 +! { dg-do run } +! { dg-options "-fno-whole-file" } +! { dg-compile-aux-modules "pr83149.f90" } +! { dg-additional-sources pr83149.f90 } +! +! Contributed by Neil Carlson <neil.n.carlson@gmail.com> +! +subroutine sub(s) + use mod2 + real :: s + s = sum(get()) +end + + use mod1 + real :: s + ncells = 2 + call sub (s) + if (int (s) .ne. ncells) stop 1 + ncells = 10 + call sub (s) + if (int (s) .ne. ncells) stop 2 +end + |