This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/13249] Error when using COMMON
- From: "dann at godzilla dot ics dot uci dot edu" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 1 Dec 2003 01:28:49 -0000
- Subject: [Bug fortran/13249] Error when using COMMON
- References: <20031201012509.13249.dann@godzilla.ics.uci.edu>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From dann at godzilla dot ics dot uci dot edu 2003-12-01 01:28 -------
With: gcc version 3.5-tree-ssa 20031130 (merged 20031123)
mymod.f90
MODULE mymod
TYPE :: mymod_type
INTEGER field1
INTEGER field2
END TYPE
TYPE (mymod_type), DIMENSION(:), ALLOCATABLE :: AN_EXAMPLE
END MODULE mymod
test.f90:
SUBROUTINE mytest (MYARG)
USE mymod;
INTEGER :: MYARG
COMMON /AN_EXAMPLE/
END
> gfortran -c test.f90
In file test.f90:4
COMMON /AN_EXAMPLE/
1
Error: Cannot change attributes of USE-associated symbol at (1)
Intel's compiler compiles this code just fine.
Code like this can be found in SPEC2000.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13249