This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/13249] [gfortran] Error when using COMMON


------- Additional Comments From dann at godzilla dot ics dot uci dot edu  2004-05-16 01:55 -------
Corrected testcase: 

      MODULE mymod
        
      TYPE :: mymod_type
        INTEGER          field1                                             
        INTEGER          field2
      END TYPE
      TYPE (mymod_type), DIMENSION(:), ALLOCATABLE :: AN_EXAMPLE
      END MODULE mymod
   
      SUBROUTINE mytest (MYARG)               
      USE mymod;
      INTEGER :: MYARG
      COMMON /AN_EXAMPLE/  Rx, Ry, Rz
      END


Fails with gfortran: 
 In file PR13249.f90:13
      COMMON /AN_EXAMPLE/  Rx, Ry, Rz
                       1
Error: Cannot change attributes of USE-associated symbol at (1)

It compiles with the  Intel and PGI compilers.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13249


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]