equal
deleted
inserted
replaced
585 /* subscript_list ',' subscript */ |
585 /* subscript_list ',' subscript */ |
586 // SYM_LIST(subscript_list_c) |
586 // SYM_LIST(subscript_list_c) |
587 void *print_datatypes_error_c::visit(subscript_list_c *symbol) { |
587 void *print_datatypes_error_c::visit(subscript_list_c *symbol) { |
588 for (int i = 0; i < symbol->n; i++) { |
588 for (int i = 0; i < symbol->n; i++) { |
589 int start_error_count = error_count; |
589 int start_error_count = error_count; |
590 symbol->elements[i]->accept(*this); |
590 symbol->get_element(i)->accept(*this); |
591 /* The following error message will only get printed if the current_display_error_level is set higher than 0! */ |
591 /* The following error message will only get printed if the current_display_error_level is set higher than 0! */ |
592 if ((start_error_count == error_count) && (!get_datatype_info_c::is_type_valid(symbol->elements[i]->datatype))) |
592 if ((start_error_count == error_count) && (!get_datatype_info_c::is_type_valid(symbol->get_element(i)->datatype))) |
593 STAGE3_ERROR(0, symbol, symbol, "Invalid data type for array subscript field."); |
593 STAGE3_ERROR(0, symbol, symbol, "Invalid data type for array subscript field."); |
594 } |
594 } |
595 return NULL; |
595 return NULL; |
596 } |
596 } |
597 |
597 |