This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/61454] ICE in simplification of initialization expression with array
- From: "fxcoudert at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 19 Jun 2014 09:23:59 +0000
- Subject: [Bug fortran/61454] ICE in simplification of initialization expression with array
- Auto-submitted: auto-generated
- References: <bug-61454-4 at http dot gcc dot gnu dot org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61454
Francois-Xavier Coudert <fxcoudert at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |ASSIGNED
Assignee|unassigned at gcc dot gnu.org |fxcoudert at gcc dot gnu.org
--- Comment #1 from Francois-Xavier Coudert <fxcoudert at gcc dot gnu.org> ---
In expr.c:scalarize_intrinsic_call(), we don't deal correctly with intrinsics
that have an optional kind argument. I'm testing this simple patch to fix it:
Index: expr.c
===================================================================
--- expr.c (revision 211685)
+++ expr.c (working copy)
@@ -1955,7 +1955,7 @@ scalarize_intrinsic_call (gfc_expr *e)
for (; a; a = a->next)
{
n++;
- if (a->expr->expr_type != EXPR_ARRAY)
+ if (!a->expr || a->expr->expr_type != EXPR_ARRAY)
continue;
array_arg = n;
expr = gfc_copy_expr (a->expr);