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/16479] COMMON block names are not private


------- Additional Comments From olchansk at panix dot com  2004-07-11 21:49 -------
This appears to fix the incorrect exporting of common block names. Tested:
common  block name is written into the .mod file if "private" is absent.

[olchansk@send fortran]$ cvs diff -u module.c
Index: module.c
===================================================================
RCS file: /cvsroot/gcc/gcc/gcc/fortran/module.c,v
retrieving revision 1.10
diff -u -r1.10 module.c
--- module.c    9 Jul 2004 22:27:15 -0000       1.10
+++ module.c    11 Jul 2004 21:46:55 -0000
@@ -3171,6 +3171,9 @@
   write_common(st->left);
   write_common(st->right);
 
+  if (!check_access (st->n.common->head->attr.access,
st->n.common->head->ns->default_access))
+    return;
+
   mio_lparen();
   mio_internal_string(st->name);
 
K.O.


-- 


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


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