http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58906
Tobias Burnus <burnus at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |ice-on-valid-code Status|UNCONFIRMED |NEW Last reconfirmed| |2013-10-28 CC| |burnus at gcc dot gnu.org Summary|SELECT TYPE with CLASS IS |[OOP] SELECT TYPE with |generates ICE |CLASS IS generates ICE Ever confirmed|0 |1 --- Comment #1 from Tobias Burnus <burnus at gcc dot gnu.org> --- Confirmed. ICEs in resolve_select_type for: SELECT TYPE( iarr=>r%arr ) where "r%arr" is CLASS(*). Hence, (gdb) p code->expr2->ts.u.derived->attr.unlimited_polymorphic $6 = 1 (gdb) p code->expr2->ts.u.derived->ts.u.derived $7 = (gfc_symbol *) 0x0 but the code does the following (last line derefs a NULL pointer). 7914 if (code->expr2) 7915 { 7916 if (code->expr1->symtree->n.sym->attr.untyped) 7917 code->expr1->symtree->n.sym->ts = code->expr2->ts; 7918 selector_type = CLASS_DATA (code->expr2)->ts.u.derived;