This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/35830] ICE with PROCEDURE(<interface>) containing array formal arguments
- From: "burnus at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 7 Jun 2008 17:30:35 -0000
- Subject: [Bug fortran/35830] ICE with PROCEDURE(<interface>) containing array formal arguments
- References: <bug-35830-13404@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #12 from burnus at gcc dot gnu dot org 2008-06-07 17:30 -------
It turned out to be a attr-related thing. f needs to be 0 in the following and
it was 1:
trans-expr.c:2525 gfc_conv_function_call
int f;
f = (fsym != NULL)
&& !(fsym->attr.pointer || fsym->attr.allocatable)
&& fsym->as->type != AS_ASSUMED_SHAPE;
f = f || !sym->attr.always_explicit;
The problem is that sym->attr.always_explicit is 0 instead of 1.
Index: gcc/fortran/resolve.c
===================================================================
--- gcc/fortran/resolve.c (Revision 136517)
+++ gcc/fortran/resolve.c (Arbeitskopie)
@@ -7905,6 +7905,7 @@ resolve_symbol (gfc_symbol *sym)
sym->ts.interface = ifc;
sym->attr.function = ifc->attr.function;
sym->attr.subroutine = ifc->attr.subroutine;
+ sym->attr.always_explicit = ifc->attr.always_explicit;
copy_formal_args (sym, ifc);
}
else if (sym->ts.interface->name[0] != '\0')
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35830