diff options
Diffstat (limited to 'gcc/testsuite/gfortran.dg/non_module_public.f90')
-rw-r--r-- | gcc/testsuite/gfortran.dg/non_module_public.f90 | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/testsuite/gfortran.dg/non_module_public.f90 b/gcc/testsuite/gfortran.dg/non_module_public.f90 new file mode 100644 index 000000000..3201a1598 --- /dev/null +++ b/gcc/testsuite/gfortran.dg/non_module_public.f90 @@ -0,0 +1,5 @@ +! { dg-do compile } +! PR20837 - A symbol may not be declared PUBLIC or PRIVATE outside a module. +! Contributed by Joost VandeVondele <jv244@cam.ac.uk> +integer, parameter, public :: i=1 ! { dg-error "outside of the specification part of a module" } +END |