+2004-06-21 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
+
+ * resolve.c (resolve_symbol): Add comment in function body.
+ (check_data_variable): Change type of mark to ar_type, adapt code
+ accordingly.
+
2004-06-21 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
* array.c (gfc_insert_constructor): Avoid redundant call to
}
}
+ /* Assumed size arrays and assumed shape arrays must be dummy
+ arguments. */
+
if (sym->as != NULL
&& (sym->as->type == AS_ASSUMED_SIZE
|| sym->as->type == AS_ASSUMED_SHAPE)
mpz_t size;
mpz_t offset;
try t;
- int mark = 0;
+ ar_type mark = AR_UNKNOWN;
int i;
mpz_t section_index[GFC_MAX_DIMENSIONS];
gfc_ref *ref;
switch (ref->u.ar.type)
{
case AR_FULL:
- mark = 1;
+ mark = AR_FULL;
break;
case AR_SECTION:
ar = &ref->u.ar;
/* Get the start position of array section. */
gfc_get_section_index (ar, section_index, &offset);
- mark = 2;
+ mark = AR_SECTION;
break;
default:
/* Assign initial value to symbol. */
gfc_assign_data_value (var->expr, values.vnode->expr, offset);
- if (mark == 1)
+ if (mark == AR_FULL)
mpz_add_ui (offset, offset, 1);
/* Modify the array section indexes and recalculate the offset for
next element. */
- else if (mark == 2)
+ else if (mark == AR_SECTION)
gfc_advance_section (section_index, ar, &offset);
mpz_sub_ui (size, size, 1);
}
- if (mark == 2)
+ if (mark == AR_SECTION)
{
for (i = 0; i < ar->dimen; i++)
mpz_clear (section_index[i]);