http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50981
Tobias Burnus <burnus at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |burnus at gcc dot gnu.org --- Comment #27 from Tobias Burnus <burnus at gcc dot gnu.org> 2012-01-25 22:29:53 UTC --- (In reply to comment #22) > Created attachment 26386 [details] > Updated patch +gfc_array_spec * +symbol_as (gfc_symbol *sym) +{ + if (sym->ts.type == BT_CLASS) + return CLASS_DATA (sym)->as; I think the function rather belongs to symbol.c than to resolve.c, unless it is "static". But the real issue is the "if" condition. It should be: if (sym->ts.type == BT_CLASS && sym->attr.class_ok) otherwise, one might get a segfault with gfortran.dg/coarray_poly_1.f90