This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/50050] Internal compiler error free_expr0 at expr.c:3709 via gfc_done_2


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

--- Comment #2 from Mikael Morin <mikael at gcc dot gnu.org> 2011-08-12 11:54:27 UTC ---
In gfc_expr_to_initialize, we copy an expression, 

  result = gfc_copy_expr (e);


and then change it to something else:

  /* Change the last array reference from AR_ELEMENT to AR_FULL.  */
  for (ref = result->ref; ref; ref = ref->next)
    if (ref->type == REF_ARRAY && ref->next == NULL)
      {
    ref->u.ar.type = AR_FULL;

    for (i = 0; i < ref->u.ar.dimen; i++)
      ref->u.ar.start[i] = ref->u.ar.end[i] = ref->u.ar.stride[i] = NULL;

    result->rank = ref->u.ar.dimen;
    break;
      }


Not very surprising that it fails.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]