This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/55827] ICE with multiple fortran modules and character lenght determined by an interfaced pure function
- From: "mikael at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 28 Dec 2012 22:41:22 +0000
- Subject: [Bug fortran/55827] ICE with multiple fortran modules and character lenght determined by an interfaced pure function
- Auto-submitted: auto-generated
- References: <bug-55827-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55827
Mikael Morin <mikael at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |mikael at gcc dot gnu.org
--- Comment #3 from Mikael Morin <mikael at gcc dot gnu.org> 2012-12-28 22:41:22 UTC ---
(In reply to comment #2)
> Here's a possible patch against trunk.
Hum, it doesn't look right to allow unnamed (symtree == NULL) functions.
Here is another possible patch. Basically untested.
diff --git a/module.c b/module.c
index cde5739..af908ac 100644
--- a/module.c
+++ b/module.c
@@ -4532,7 +4532,7 @@ read_module (void)
char name[GFC_MAX_SYMBOL_LEN + 1];
int i;
int ambiguous, j, nuse, symbol;
- pointer_info *info, *q;
+ pointer_info *info;
gfc_use_rename *u = NULL;
gfc_symtree *st;
gfc_symbol *sym;
@@ -4595,8 +4595,7 @@ read_module (void)
/* Some symbols do not have a namespace (eg. formal arguments),
so the automatic "unique symtree" mechanism must be suppressed
by marking them as referenced. */
- q = get_integer (info->u.rsym.ns);
- if (q->u.pointer == NULL)
+ if (info->u.rsym.ns == 0)
{
info->u.rsym.referenced = 1;
continue;