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/60234] [4.9 Regression] [OOP] ICE in generate_finalization_wrapper at fortran/class.c:1883


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

janus at gcc dot gnu.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED
           Assignee|unassigned at gcc dot gnu.org      |janus at gcc dot gnu.org

--- Comment #4 from janus at gcc dot gnu.org ---
The test case in comment 0 compiles cleanly when adding the following to the
patch in comment 2:

Index: gcc/fortran/class.c
===================================================================
--- gcc/fortran/class.c    (revision 207804)
+++ gcc/fortran/class.c    (working copy)
@@ -637,9 +637,10 @@ gfc_build_class_symbol (gfc_typespec *ts, symbol_a
       if (!gfc_add_component (fclass, "_vptr", &c))
     return false;
       c->ts.type = BT_DERIVED;
-      if (delayed_vtab
-      || (ts->u.derived->f2k_derived
-          && ts->u.derived->f2k_derived->finalizers))
+      if ((delayed_vtab
+       || (ts->u.derived->f2k_derived
+           && ts->u.derived->f2k_derived->finalizers))
+      && !ts->u.derived->attr.unlimited_polymorphic)
     c->ts.u.derived = NULL;
       else
     {


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