[Bug fortran/19425] New: Duplicate SAVE attribute problem

tow21 at cam dot ac dot uk gcc-bugzilla@gcc.gnu.org
Thu Jan 13 14:26:00 GMT 2005

Consider the following program: 
parabrisas:~/test% cat C578.f  
      subroutine s( ) 
      logical frstme 
      save frstme 
Under constraint C578 of the f95 standard this is illegal, since a global save 
is not permitted in the same scoping unit as any other explicit use of the 
save attribute or save statement. gfortran correctly recognises this and 
diagnoses an error. 
However, this constraint did not exist in F77 (I am unsure about F90). 
Therefore, the above is a perfectly legal F77 program (and, indeed g77 
compiles it without complaint).

           Summary: Duplicate SAVE attribute problem
           Product: gcc
           Version: 4.0.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: tow21 at cam dot ac dot uk
                CC: gcc-bugs at gcc dot gnu dot org


More information about the Gcc-bugs mailing list