http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56730
Dominique d'Humieres <dominiq at lps dot ens.fr> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Last reconfirmed| |2013-03-26 Ever Confirmed|0 |1 --- Comment #2 from Dominique d'Humieres <dominiq at lps dot ens.fr> 2013-03-26 19:14:56 UTC --- The following comment has been mistakenly posted in pr56731#c3: AFAICT this has been fixed by revision 187192 (pr41600). I don't think this is a regression: I get the ICE for 4.5.3, 4.6.3, and 4.7.2 (CLASS is not part of 4.4). I don't know the best way to resolve this PR: WONTFIX or FIXED? Note that while r187192 contains many changes and does not look suitable for backporting, the following patch --- trunk/gcc/fortran/resolve.c 2012/05/05 07:59:22 187191 +++ trunk/gcc/fortran/resolve.c 2012/05/05 08:49:43 187192 @@ -4904,14 +4904,19 @@ { /* F03:C614. */ if (ref->u.c.component->attr.pointer - || ref->u.c.component->attr.proc_pointer) + || ref->u.c.component->attr.proc_pointer + || (ref->u.c.component->ts.type == BT_CLASS + && CLASS_DATA (ref->u.c.component)->attr.pointer)) { gfc_error ("Component to the right of a part reference " "with nonzero rank must not have the POINTER " "attribute at %L", &expr->where); return FAILURE; } - else if (ref->u.c.component->attr.allocatable) + else if (ref->u.c.component->attr.allocatable + || (ref->u.c.component->ts.type == BT_CLASS + && CLASS_DATA (ref->u.c.component)->attr.allocatable)) + { gfc_error ("Component to the right of a part reference " "with nonzero rank must not have the ALLOCATABLE " could cure the ICE for 4.7 (to be tested;-).