trans-array.c (gfc_set_loop_bounds_from_array_spec): Get the array dimension from the dim array.

2010-09-09  Mikael Morin  <mikael@gcc.gnu.org>

	* trans-array.c (gfc_set_loop_bounds_from_array_spec):
	Get the array dimension from the dim array.

From-SVN: r164109
This commit is contained in:
Mikael Morin 2010-09-09 14:12:08 +00:00
parent 5582cb29ba
commit e3cdb7cf9a
2 changed files with 9 additions and 2 deletions

View File

@ -1,3 +1,8 @@
2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
* trans-array.c (gfc_set_loop_bounds_from_array_spec):
Get the array dimension from the dim array.
2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
* trans-array.c (gfc_trans_preloop_setup): Unconditionally use the

View File

@ -562,9 +562,11 @@ gfc_set_loop_bounds_from_array_spec (gfc_interface_mapping * mapping,
tree tmp;
if (as && as->type == AS_EXPLICIT)
for (dim = 0; dim < se->loop->dimen; dim++)
for (n = 0; n < se->loop->dimen; n++)
{
n = se->loop->order[dim];
dim = se->ss->data.info.dim[n];
gcc_assert (dim < as->rank);
gcc_assert (se->loop->dimen == as->rank);
if (se->loop->to[n] == NULL_TREE)
{
/* Evaluate the lower bound. */