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/29657] Don't allow SAVE for functions



------- Comment #1 from burnus at gcc dot gnu dot org  2006-10-30 19:31 -------
A fix for this specific problem is below. But one should check whether there
are other things related to procedures/subroutines/functions which are be
prohibited and should be checked. (Thus not assigning to myself.)

The patch below gives:
 In file volatile.f90:8

    integer, save :: a
                     1
Error: FUNCTION attribute conflicts with SAVE attribute at (1)


Index: gcc/fortran/symbol.c
===================================================================
--- gcc/fortran/symbol.c        (Revision 118191)
+++ gcc/fortran/symbol.c        (Arbeitskopie)
@@ -367,6 +367,7 @@
   conf (entry, result);

   conf (function, subroutine);
+  conf (function, save);

   /* Cray pointer/pointee conflicts.  */
   conf (cray_pointer, cray_pointee);


-- 


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


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