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

janus at gcc dot gnu.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |ASSIGNED
   Last reconfirmed|                            |2012-07-31
         AssignedTo|unassigned at gcc dot       |janus at gcc dot gnu.org
                   |gnu.org                     |
     Ever Confirmed|0                           |1

--- Comment #2 from janus at gcc dot gnu.org 2012-07-31 10:13:29 UTC ---
Patch:

Index: gcc/fortran/dependency.c
===================================================================
--- gcc/fortran/dependency.c    (revision 189984)
+++ gcc/fortran/dependency.c    (working copy)
@@ -261,6 +261,9 @@ gfc_dep_compare_expr (gfc_expr *e1, gfc_expr *e2)
   n1 = NULL;
   n2 = NULL;

+  if (e1 == NULL && e2 == NULL)
+    return 0;
+
   /* Remove any integer conversion functions to larger types.  */
   if (e1->expr_type == EXPR_FUNCTION && e1->value.function.isym
       && e1->value.function.isym->id == GFC_ISYM_CONVERSION


With this, the test case compiles without error and produces the expected
result. Will commit as obvious after regtesting.

Reply via email to