------- Comment #5 from janus at gcc dot gnu dot org  2010-06-06 21:31 -------
I'm afraid you're right. r149586 indeed seems to be the culprit. The bug goes
away when reverting a part of that commit, more precisely this one:

Index: gcc/fortran/resolve.c
===================================================================
--- gcc/fortran/resolve.c       (revision 160347)
+++ gcc/fortran/resolve.c       (working copy)
@@ -11661,20 +11655,6 @@ resolve_symbol (gfc_symbol *sym)
       && !sym->attr.contained && !sym->attr.intrinsic)
     gfc_resolve (sym->formal_ns);

-  /* Make sure the formal namespace is present.  */
-  if (sym->formal && !sym->formal_ns)
-    {
-      gfc_formal_arglist *formal = sym->formal;
-      while (formal && !formal->sym)
-       formal = formal->next;
-
-      if (formal)
-       {
-         sym->formal_ns = formal->sym->ns;
-         sym->formal_ns->refs++;
-       }
-    }
-
   /* Check threadprivate restrictions.  */
   if (sym->attr.threadprivate && !sym->attr.save && !sym->ns->save_all
       && (!sym->attr.in_common


-- 


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

Reply via email to