[Bug fortran/42804] ICE with -fcheck=bounds and type bound procedure call on array element
janus at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Tue Jan 19 17:12:00 GMT 2010
------- Comment #6 from janus at gcc dot gnu dot org 2010-01-19 17:11 -------
(In reply to comment #3)
> The problem is that e(xpr)->where->lb == NULL.
Exactly. What's important is that the expression "e" here is the passed-object
argument.
Now the problem really is that when we construct this passed-object argument,
we do not set a locus for it. But this is easily fixed:
Index: gcc/fortran/resolve.c
===================================================================
--- gcc/fortran/resolve.c (revision 156040)
+++ gcc/fortran/resolve.c (working copy)
@@ -4777,6 +4777,7 @@ extract_compcall_passed_object (gfc_expr* e)
po->expr_type = EXPR_VARIABLE;
po->symtree = e->symtree;
po->ref = gfc_copy_ref (e->ref);
+ po->where = e->where;
}
if (gfc_resolve_expr (po) == FAILURE)
--
janus at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |janus at gcc dot gnu dot org
|dot org |
Status|NEW |ASSIGNED
Last reconfirmed|2010-01-19 15:41:22 |2010-01-19 17:11:49
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42804
More information about the Gcc-bugs
mailing list