Commit 411e1a0f by Mikael Morin

re PR fortran/50420 ([Coarray] lcobound doesn't accept coarray subcomponents)

	PR fortran/50420
	* trans-intrinsic.c (walk_coarray): Allow subreferences after a
	coarray object reference.

From-SVN: r180146
parent 6b81e94d
2011-10-18 Mikael Morin <mikael@gcc.gnu.org>
PR fortran/50420
* trans-intrinsic.c (walk_coarray): Allow subreferences after a
coarray object reference.
2011-10-18 Mikael Morin <mikael@gcc.gnu.org>
PR fortran/50420
* trans-array.c (gfc_walk_array_ref): Allow zero rank arrays
if they are coarrays.
......
......@@ -943,10 +943,16 @@ walk_coarray (gfc_expr *e)
ss = gfc_get_array_ss (gfc_ss_terminator, e, 0, GFC_SS_SECTION);
ref = e->ref;
while (ref->next)
ref = ref->next;
while (ref)
{
if (ref->type == REF_ARRAY
&& ref->u.ar.codimen > 0)
break;
ref = ref->next;
}
gcc_assert (ref->type == REF_ARRAY && ref->u.ar.codimen > 0);
gcc_assert (ref != NULL);
ref->u.ar.type = AR_FULL;
ss->data.info.ref = ref;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment