Commit a513927a by Steven G. Kargl

gfortran.h (gfc_code): Rename struct member expr to expr1.

2009-05-13  Steven G. Kargl  <kargl@gcc.gnu.org>

	* gfortran.h (gfc_code): Rename struct member expr to expr1.
	* openmp.c (resolve_omp_atomic): Update expr to expr1.
	* interface.c (gfc_extend_assign): Ditto.
	* trans-expr.c (gfc_conv_expr_reference, gfc_trans_assignment,
	gfc_trans_init_assign): Ditto.
	* dump-parse-tree.c (show_code_node): Ditto.
	* trans-openmp.c (gfc_trans_omp_atomic): Ditto.
	* trans-stmt.c ( gfc_trans_label_assign, gfc_trans_goto, gfc_trans_call,
	gfc_trans_return, gfc_trans_pause, gfc_trans_stop, gfc_trans_if_1,
	gfc_trans_arithmetic_if, gfc_trans_do_while, gfc_trans_integer_select,
	gfc_trans_logical_select, gfc_trans_character_select
	forall_make_variable_temp, check_forall_dependencies
	gfc_trans_forall_1, gfc_trans_where_2, gfc_trans_where_3
	gfc_trans_where, gfc_trans_allocate, gfc_trans_deallocate): Ditto.
	* io.c (match_io_element, gfc_match_inquire): Ditto.
	* resolve.c (resolve_typebound_call, resolve_ppc_call,
	resolve_allocate_expr, resolve_allocate_deallocate, resolve_select,
	resolve_transfer, resolve_where, gfc_resolve_assign_in_forall,
	gfc_resolve_blocks, resolve_code, build_init_assign): Ditto.
	* st.c (gfc_free_statement): Ditto.
	* match.c (gfc_match_assignment, gfc_match_pointer_assignment,
	match_arithmetic_if, gfc_match_if, gfc_match_elseif
	gfc_match_stopcode, gfc_match_assign, gfc_match_goto,
	gfc_match_nullify, match_typebound_call, gfc_match_call
	gfc_match_select, match_simple_where, gfc_match_where
	gfc_match_elsewhere, match_simple_forall, gfc_match_forall): Ditto.
	* trans-io.c (gfc_trans_transfer): Ditto.
	* parse.c (parse_where_block, parse_if_block): Ditto.

From-SVN: r147497
parent 42657b07
2009-05-13 Steven G. Kargl <kargl@gcc.gnu.org> 2009-05-13 Steven G. Kargl <kargl@gcc.gnu.org>
* gfortran.h (gfc_code): Rename struct member expr to expr1.
* openmp.c (resolve_omp_atomic): Update expr to expr1.
* interface.c (gfc_extend_assign): Ditto.
* trans-expr.c (gfc_conv_expr_reference, gfc_trans_assignment,
gfc_trans_init_assign): Ditto.
* dump-parse-tree.c (show_code_node): Ditto.
* trans-openmp.c (gfc_trans_omp_atomic): Ditto.
* trans-stmt.c ( gfc_trans_label_assign, gfc_trans_goto, gfc_trans_call,
gfc_trans_return, gfc_trans_pause, gfc_trans_stop, gfc_trans_if_1,
gfc_trans_arithmetic_if, gfc_trans_do_while, gfc_trans_integer_select,
gfc_trans_logical_select, gfc_trans_character_select
forall_make_variable_temp, check_forall_dependencies
gfc_trans_forall_1, gfc_trans_where_2, gfc_trans_where_3
gfc_trans_where, gfc_trans_allocate, gfc_trans_deallocate): Ditto.
* io.c (match_io_element, gfc_match_inquire): Ditto.
* resolve.c (resolve_typebound_call, resolve_ppc_call,
resolve_allocate_expr, resolve_allocate_deallocate, resolve_select,
resolve_transfer, resolve_where, gfc_resolve_assign_in_forall,
gfc_resolve_blocks, resolve_code, build_init_assign): Ditto.
* st.c (gfc_free_statement): Ditto.
* match.c (gfc_match_assignment, gfc_match_pointer_assignment,
match_arithmetic_if, gfc_match_if, gfc_match_elseif
gfc_match_stopcode, gfc_match_assign, gfc_match_goto,
gfc_match_nullify, match_typebound_call, gfc_match_call
gfc_match_select, match_simple_where, gfc_match_where
gfc_match_elsewhere, match_simple_forall, gfc_match_forall): Ditto.
* trans-io.c (gfc_trans_transfer): Ditto.
* parse.c (parse_where_block, parse_if_block): Ditto.
2009-05-13 Steven G. Kargl <kargl@gcc.gnu.org>
* gfortran.h (gfc_code): Rename struct member label to label1. * gfortran.h (gfc_code): Rename struct member label to label1.
* dump-parse-tree.c (show_code_node): Update symbol. * dump-parse-tree.c (show_code_node): Update symbol.
* trans-stmt.c (gfc_trans_label_assign, gfc_trans_goto, * trans-stmt.c (gfc_trans_label_assign, gfc_trans_goto,
......
...@@ -1166,20 +1166,20 @@ show_code_node (int level, gfc_code *c) ...@@ -1166,20 +1166,20 @@ show_code_node (int level, gfc_code *c)
case EXEC_INIT_ASSIGN: case EXEC_INIT_ASSIGN:
case EXEC_ASSIGN: case EXEC_ASSIGN:
fputs ("ASSIGN ", dumpfile); fputs ("ASSIGN ", dumpfile);
show_expr (c->expr); show_expr (c->expr1);
fputc (' ', dumpfile); fputc (' ', dumpfile);
show_expr (c->expr2); show_expr (c->expr2);
break; break;
case EXEC_LABEL_ASSIGN: case EXEC_LABEL_ASSIGN:
fputs ("LABEL ASSIGN ", dumpfile); fputs ("LABEL ASSIGN ", dumpfile);
show_expr (c->expr); show_expr (c->expr1);
fprintf (dumpfile, " %d", c->label1->value); fprintf (dumpfile, " %d", c->label1->value);
break; break;
case EXEC_POINTER_ASSIGN: case EXEC_POINTER_ASSIGN:
fputs ("POINTER ASSIGN ", dumpfile); fputs ("POINTER ASSIGN ", dumpfile);
show_expr (c->expr); show_expr (c->expr1);
fputc (' ', dumpfile); fputc (' ', dumpfile);
show_expr (c->expr2); show_expr (c->expr2);
break; break;
...@@ -1190,7 +1190,7 @@ show_code_node (int level, gfc_code *c) ...@@ -1190,7 +1190,7 @@ show_code_node (int level, gfc_code *c)
fprintf (dumpfile, "%d", c->label1->value); fprintf (dumpfile, "%d", c->label1->value);
else else
{ {
show_expr (c->expr); show_expr (c->expr1);
d = c->block; d = c->block;
if (d != NULL) if (d != NULL)
{ {
...@@ -1221,26 +1221,26 @@ show_code_node (int level, gfc_code *c) ...@@ -1221,26 +1221,26 @@ show_code_node (int level, gfc_code *c)
case EXEC_COMPCALL: case EXEC_COMPCALL:
fputs ("CALL ", dumpfile); fputs ("CALL ", dumpfile);
show_compcall (c->expr); show_compcall (c->expr1);
break; break;
case EXEC_CALL_PPC: case EXEC_CALL_PPC:
fputs ("CALL ", dumpfile); fputs ("CALL ", dumpfile);
show_expr (c->expr); show_expr (c->expr1);
show_actual_arglist (c->ext.actual); show_actual_arglist (c->ext.actual);
break; break;
case EXEC_RETURN: case EXEC_RETURN:
fputs ("RETURN ", dumpfile); fputs ("RETURN ", dumpfile);
if (c->expr) if (c->expr1)
show_expr (c->expr); show_expr (c->expr1);
break; break;
case EXEC_PAUSE: case EXEC_PAUSE:
fputs ("PAUSE ", dumpfile); fputs ("PAUSE ", dumpfile);
if (c->expr != NULL) if (c->expr1 != NULL)
show_expr (c->expr); show_expr (c->expr1);
else else
fprintf (dumpfile, "%d", c->ext.stop_code); fprintf (dumpfile, "%d", c->ext.stop_code);
...@@ -1249,8 +1249,8 @@ show_code_node (int level, gfc_code *c) ...@@ -1249,8 +1249,8 @@ show_code_node (int level, gfc_code *c)
case EXEC_STOP: case EXEC_STOP:
fputs ("STOP ", dumpfile); fputs ("STOP ", dumpfile);
if (c->expr != NULL) if (c->expr1 != NULL)
show_expr (c->expr); show_expr (c->expr1);
else else
fprintf (dumpfile, "%d", c->ext.stop_code); fprintf (dumpfile, "%d", c->ext.stop_code);
...@@ -1258,7 +1258,7 @@ show_code_node (int level, gfc_code *c) ...@@ -1258,7 +1258,7 @@ show_code_node (int level, gfc_code *c)
case EXEC_ARITHMETIC_IF: case EXEC_ARITHMETIC_IF:
fputs ("IF ", dumpfile); fputs ("IF ", dumpfile);
show_expr (c->expr); show_expr (c->expr1);
fprintf (dumpfile, " %d, %d, %d", fprintf (dumpfile, " %d, %d, %d",
c->label1->value, c->label2->value, c->label3->value); c->label1->value, c->label2->value, c->label3->value);
break; break;
...@@ -1266,7 +1266,7 @@ show_code_node (int level, gfc_code *c) ...@@ -1266,7 +1266,7 @@ show_code_node (int level, gfc_code *c)
case EXEC_IF: case EXEC_IF:
d = c->block; d = c->block;
fputs ("IF ", dumpfile); fputs ("IF ", dumpfile);
show_expr (d->expr); show_expr (d->expr1);
fputc ('\n', dumpfile); fputc ('\n', dumpfile);
show_code (level + 1, d->next); show_code (level + 1, d->next);
...@@ -1275,12 +1275,12 @@ show_code_node (int level, gfc_code *c) ...@@ -1275,12 +1275,12 @@ show_code_node (int level, gfc_code *c)
{ {
code_indent (level, 0); code_indent (level, 0);
if (d->expr == NULL) if (d->expr1 == NULL)
fputs ("ELSE\n", dumpfile); fputs ("ELSE\n", dumpfile);
else else
{ {
fputs ("ELSE IF ", dumpfile); fputs ("ELSE IF ", dumpfile);
show_expr (d->expr); show_expr (d->expr1);
fputc ('\n', dumpfile); fputc ('\n', dumpfile);
} }
...@@ -1295,7 +1295,7 @@ show_code_node (int level, gfc_code *c) ...@@ -1295,7 +1295,7 @@ show_code_node (int level, gfc_code *c)
case EXEC_SELECT: case EXEC_SELECT:
d = c->block; d = c->block;
fputs ("SELECT CASE ", dumpfile); fputs ("SELECT CASE ", dumpfile);
show_expr (c->expr); show_expr (c->expr1);
fputc ('\n', dumpfile); fputc ('\n', dumpfile);
for (; d; d = d->block) for (; d; d = d->block)
...@@ -1325,7 +1325,7 @@ show_code_node (int level, gfc_code *c) ...@@ -1325,7 +1325,7 @@ show_code_node (int level, gfc_code *c)
fputs ("WHERE ", dumpfile); fputs ("WHERE ", dumpfile);
d = c->block; d = c->block;
show_expr (d->expr); show_expr (d->expr1);
fputc ('\n', dumpfile); fputc ('\n', dumpfile);
show_code (level + 1, d->next); show_code (level + 1, d->next);
...@@ -1334,7 +1334,7 @@ show_code_node (int level, gfc_code *c) ...@@ -1334,7 +1334,7 @@ show_code_node (int level, gfc_code *c)
{ {
code_indent (level, 0); code_indent (level, 0);
fputs ("ELSE WHERE ", dumpfile); fputs ("ELSE WHERE ", dumpfile);
show_expr (d->expr); show_expr (d->expr1);
fputc ('\n', dumpfile); fputc ('\n', dumpfile);
show_code (level + 1, d->next); show_code (level + 1, d->next);
} }
...@@ -1360,10 +1360,10 @@ show_code_node (int level, gfc_code *c) ...@@ -1360,10 +1360,10 @@ show_code_node (int level, gfc_code *c)
fputc (',', dumpfile); fputc (',', dumpfile);
} }
if (c->expr != NULL) if (c->expr1 != NULL)
{ {
fputc (',', dumpfile); fputc (',', dumpfile);
show_expr (c->expr); show_expr (c->expr1);
} }
fputc ('\n', dumpfile); fputc ('\n', dumpfile);
...@@ -1393,7 +1393,7 @@ show_code_node (int level, gfc_code *c) ...@@ -1393,7 +1393,7 @@ show_code_node (int level, gfc_code *c)
case EXEC_DO_WHILE: case EXEC_DO_WHILE:
fputs ("DO WHILE ", dumpfile); fputs ("DO WHILE ", dumpfile);
show_expr (c->expr); show_expr (c->expr1);
fputc ('\n', dumpfile); fputc ('\n', dumpfile);
show_code (level + 1, c->block->next); show_code (level + 1, c->block->next);
...@@ -1416,10 +1416,10 @@ show_code_node (int level, gfc_code *c) ...@@ -1416,10 +1416,10 @@ show_code_node (int level, gfc_code *c)
case EXEC_ALLOCATE: case EXEC_ALLOCATE:
fputs ("ALLOCATE ", dumpfile); fputs ("ALLOCATE ", dumpfile);
if (c->expr) if (c->expr1)
{ {
fputs (" STAT=", dumpfile); fputs (" STAT=", dumpfile);
show_expr (c->expr); show_expr (c->expr1);
} }
for (a = c->ext.alloc_list; a; a = a->next) for (a = c->ext.alloc_list; a; a = a->next)
...@@ -1432,10 +1432,10 @@ show_code_node (int level, gfc_code *c) ...@@ -1432,10 +1432,10 @@ show_code_node (int level, gfc_code *c)
case EXEC_DEALLOCATE: case EXEC_DEALLOCATE:
fputs ("DEALLOCATE ", dumpfile); fputs ("DEALLOCATE ", dumpfile);
if (c->expr) if (c->expr1)
{ {
fputs (" STAT=", dumpfile); fputs (" STAT=", dumpfile);
show_expr (c->expr); show_expr (c->expr1);
} }
for (a = c->ext.alloc_list; a; a = a->next) for (a = c->ext.alloc_list; a; a = a->next)
...@@ -1798,7 +1798,7 @@ show_code_node (int level, gfc_code *c) ...@@ -1798,7 +1798,7 @@ show_code_node (int level, gfc_code *c)
case EXEC_IOLENGTH: case EXEC_IOLENGTH:
fputs ("IOLENGTH ", dumpfile); fputs ("IOLENGTH ", dumpfile);
show_expr (c->expr); show_expr (c->expr1);
goto show_dt_code; goto show_dt_code;
break; break;
...@@ -1907,7 +1907,7 @@ show_code_node (int level, gfc_code *c) ...@@ -1907,7 +1907,7 @@ show_code_node (int level, gfc_code *c)
case EXEC_TRANSFER: case EXEC_TRANSFER:
fputs ("TRANSFER ", dumpfile); fputs ("TRANSFER ", dumpfile);
show_expr (c->expr); show_expr (c->expr1);
break; break;
case EXEC_DT_END: case EXEC_DT_END:
......
...@@ -1915,7 +1915,7 @@ typedef struct gfc_code ...@@ -1915,7 +1915,7 @@ typedef struct gfc_code
gfc_st_label *here, *label1, *label2, *label3; gfc_st_label *here, *label1, *label2, *label3;
gfc_symtree *symtree; gfc_symtree *symtree;
gfc_expr *expr, *expr2; gfc_expr *expr1, *expr2;
/* A name isn't sufficient to identify a subroutine, we need the actual /* A name isn't sufficient to identify a subroutine, we need the actual
symbol for the interface definition. symbol for the interface definition.
const char *sub_name; */ const char *sub_name; */
......
...@@ -2591,7 +2591,7 @@ gfc_extend_assign (gfc_code *c, gfc_namespace *ns) ...@@ -2591,7 +2591,7 @@ gfc_extend_assign (gfc_code *c, gfc_namespace *ns)
gfc_expr *lhs, *rhs; gfc_expr *lhs, *rhs;
gfc_symbol *sym; gfc_symbol *sym;
lhs = c->expr; lhs = c->expr1;
rhs = c->expr2; rhs = c->expr2;
/* Don't allow an intrinsic assignment to be replaced. */ /* Don't allow an intrinsic assignment to be replaced. */
...@@ -2626,7 +2626,7 @@ gfc_extend_assign (gfc_code *c, gfc_namespace *ns) ...@@ -2626,7 +2626,7 @@ gfc_extend_assign (gfc_code *c, gfc_namespace *ns)
/* Replace the assignment with the call. */ /* Replace the assignment with the call. */
c->op = EXEC_ASSIGN_CALL; c->op = EXEC_ASSIGN_CALL;
c->symtree = gfc_find_sym_in_symtree (sym); c->symtree = gfc_find_sym_in_symtree (sym);
c->expr = NULL; c->expr1 = NULL;
c->expr2 = NULL; c->expr2 = NULL;
c->ext.actual = actual; c->ext.actual = actual;
......
...@@ -2830,7 +2830,7 @@ match_io_element (io_kind k, gfc_code **cpp) ...@@ -2830,7 +2830,7 @@ match_io_element (io_kind k, gfc_code **cpp)
cp = gfc_get_code (); cp = gfc_get_code ();
cp->op = EXEC_TRANSFER; cp->op = EXEC_TRANSFER;
cp->expr = expr; cp->expr1 = expr;
*cpp = cp; *cpp = cp;
return MATCH_YES; return MATCH_YES;
...@@ -3662,7 +3662,7 @@ gfc_match_inquire (void) ...@@ -3662,7 +3662,7 @@ gfc_match_inquire (void)
goto syntax; goto syntax;
new_st.op = EXEC_IOLENGTH; new_st.op = EXEC_IOLENGTH;
new_st.expr = inquire->iolength; new_st.expr1 = inquire->iolength;
new_st.ext.inquire = inquire; new_st.ext.inquire = inquire;
if (gfc_pure (NULL)) if (gfc_pure (NULL))
......
...@@ -1306,7 +1306,7 @@ gfc_match_assignment (void) ...@@ -1306,7 +1306,7 @@ gfc_match_assignment (void)
gfc_set_sym_referenced (lvalue->symtree->n.sym); gfc_set_sym_referenced (lvalue->symtree->n.sym);
new_st.op = EXEC_ASSIGN; new_st.op = EXEC_ASSIGN;
new_st.expr = lvalue; new_st.expr1 = lvalue;
new_st.expr2 = rvalue; new_st.expr2 = rvalue;
gfc_check_do_variable (lvalue->symtree); gfc_check_do_variable (lvalue->symtree);
...@@ -1346,7 +1346,7 @@ gfc_match_pointer_assignment (void) ...@@ -1346,7 +1346,7 @@ gfc_match_pointer_assignment (void)
goto cleanup; goto cleanup;
new_st.op = EXEC_POINTER_ASSIGN; new_st.op = EXEC_POINTER_ASSIGN;
new_st.expr = lvalue; new_st.expr1 = lvalue;
new_st.expr2 = rvalue; new_st.expr2 = rvalue;
return MATCH_YES; return MATCH_YES;
...@@ -1388,7 +1388,7 @@ match_arithmetic_if (void) ...@@ -1388,7 +1388,7 @@ match_arithmetic_if (void)
return MATCH_ERROR; return MATCH_ERROR;
new_st.op = EXEC_ARITHMETIC_IF; new_st.op = EXEC_ARITHMETIC_IF;
new_st.expr = expr; new_st.expr1 = expr;
new_st.label1 = l1; new_st.label1 = l1;
new_st.label2 = l2; new_st.label2 = l2;
new_st.label3 = l3; new_st.label3 = l3;
...@@ -1469,7 +1469,7 @@ gfc_match_if (gfc_statement *if_type) ...@@ -1469,7 +1469,7 @@ gfc_match_if (gfc_statement *if_type)
return MATCH_ERROR; return MATCH_ERROR;
new_st.op = EXEC_ARITHMETIC_IF; new_st.op = EXEC_ARITHMETIC_IF;
new_st.expr = expr; new_st.expr1 = expr;
new_st.label1 = l1; new_st.label1 = l1;
new_st.label2 = l2; new_st.label2 = l2;
new_st.label3 = l3; new_st.label3 = l3;
...@@ -1481,7 +1481,7 @@ gfc_match_if (gfc_statement *if_type) ...@@ -1481,7 +1481,7 @@ gfc_match_if (gfc_statement *if_type)
if (gfc_match (" then%t") == MATCH_YES) if (gfc_match (" then%t") == MATCH_YES)
{ {
new_st.op = EXEC_IF; new_st.op = EXEC_IF;
new_st.expr = expr; new_st.expr1 = expr;
*if_type = ST_IF_BLOCK; *if_type = ST_IF_BLOCK;
return MATCH_YES; return MATCH_YES;
} }
...@@ -1601,7 +1601,7 @@ got_match: ...@@ -1601,7 +1601,7 @@ got_match:
*p->next = new_st; *p->next = new_st;
p->next->loc = gfc_current_locus; p->next->loc = gfc_current_locus;
p->expr = expr; p->expr1 = expr;
p->op = EXEC_IF; p->op = EXEC_IF;
gfc_clear_new_st (); gfc_clear_new_st ();
...@@ -1677,7 +1677,7 @@ gfc_match_elseif (void) ...@@ -1677,7 +1677,7 @@ gfc_match_elseif (void)
done: done:
new_st.op = EXEC_IF; new_st.op = EXEC_IF;
new_st.expr = expr; new_st.expr1 = expr;
return MATCH_YES; return MATCH_YES;
cleanup: cleanup:
...@@ -1792,7 +1792,7 @@ done: ...@@ -1792,7 +1792,7 @@ done:
new_st.label1 = label; new_st.label1 = label;
if (new_st.op == EXEC_DO_WHILE) if (new_st.op == EXEC_DO_WHILE)
new_st.expr = iter.end; new_st.expr1 = iter.end;
else else
{ {
new_st.ext.iterator = ip = gfc_get_iterator (); new_st.ext.iterator = ip = gfc_get_iterator ();
...@@ -1952,7 +1952,7 @@ gfc_match_stopcode (gfc_statement st) ...@@ -1952,7 +1952,7 @@ gfc_match_stopcode (gfc_statement st)
} }
new_st.op = st == ST_STOP ? EXEC_STOP : EXEC_PAUSE; new_st.op = st == ST_STOP ? EXEC_STOP : EXEC_PAUSE;
new_st.expr = e; new_st.expr1 = e;
new_st.ext.stop_code = stop_code; new_st.ext.stop_code = stop_code;
return MATCH_YES; return MATCH_YES;
...@@ -2034,7 +2034,7 @@ gfc_match_assign (void) ...@@ -2034,7 +2034,7 @@ gfc_match_assign (void)
new_st.op = EXEC_LABEL_ASSIGN; new_st.op = EXEC_LABEL_ASSIGN;
new_st.label1 = label; new_st.label1 = label;
new_st.expr = expr; new_st.expr1 = expr;
return MATCH_YES; return MATCH_YES;
} }
} }
...@@ -2077,7 +2077,7 @@ gfc_match_goto (void) ...@@ -2077,7 +2077,7 @@ gfc_match_goto (void)
return MATCH_ERROR; return MATCH_ERROR;
new_st.op = EXEC_GOTO; new_st.op = EXEC_GOTO;
new_st.expr = expr; new_st.expr1 = expr;
if (gfc_match_eos () == MATCH_YES) if (gfc_match_eos () == MATCH_YES)
return MATCH_YES; return MATCH_YES;
...@@ -2184,7 +2184,7 @@ gfc_match_goto (void) ...@@ -2184,7 +2184,7 @@ gfc_match_goto (void)
equivalent SELECT statement constructed. */ equivalent SELECT statement constructed. */
new_st.op = EXEC_SELECT; new_st.op = EXEC_SELECT;
new_st.expr = NULL; new_st.expr1 = NULL;
/* Hack: For a "real" SELECT, the expression is in expr. We put /* Hack: For a "real" SELECT, the expression is in expr. We put
it in expr2 so we can distinguish then and produce the correct it in expr2 so we can distinguish then and produce the correct
...@@ -2337,7 +2337,7 @@ alloc_opt_list: ...@@ -2337,7 +2337,7 @@ alloc_opt_list:
goto syntax; goto syntax;
new_st.op = EXEC_ALLOCATE; new_st.op = EXEC_ALLOCATE;
new_st.expr = stat; new_st.expr1 = stat;
new_st.expr2 = errmsg; new_st.expr2 = errmsg;
new_st.ext.alloc_list = head; new_st.ext.alloc_list = head;
...@@ -2402,7 +2402,7 @@ gfc_match_nullify (void) ...@@ -2402,7 +2402,7 @@ gfc_match_nullify (void)
} }
tail->op = EXEC_POINTER_ASSIGN; tail->op = EXEC_POINTER_ASSIGN;
tail->expr = p; tail->expr1 = p;
tail->expr2 = e; tail->expr2 = e;
if (gfc_match (" )%t") == MATCH_YES) if (gfc_match (" )%t") == MATCH_YES)
...@@ -2538,7 +2538,7 @@ dealloc_opt_list: ...@@ -2538,7 +2538,7 @@ dealloc_opt_list:
goto syntax; goto syntax;
new_st.op = EXEC_DEALLOCATE; new_st.op = EXEC_DEALLOCATE;
new_st.expr = stat; new_st.expr1 = stat;
new_st.expr2 = errmsg; new_st.expr2 = errmsg;
new_st.ext.alloc_list = head; new_st.ext.alloc_list = head;
...@@ -2606,7 +2606,7 @@ done: ...@@ -2606,7 +2606,7 @@ done:
return MATCH_ERROR; return MATCH_ERROR;
new_st.op = EXEC_RETURN; new_st.op = EXEC_RETURN;
new_st.expr = e; new_st.expr1 = e;
return MATCH_YES; return MATCH_YES;
} }
...@@ -2652,7 +2652,7 @@ match_typebound_call (gfc_symtree* varst) ...@@ -2652,7 +2652,7 @@ match_typebound_call (gfc_symtree* varst)
"at %C"); "at %C");
return MATCH_ERROR; return MATCH_ERROR;
} }
new_st.expr = base; new_st.expr1 = base;
return MATCH_YES; return MATCH_YES;
} }
...@@ -2755,11 +2755,11 @@ gfc_match_call (void) ...@@ -2755,11 +2755,11 @@ gfc_match_call (void)
select_sym->ts.type = BT_INTEGER; select_sym->ts.type = BT_INTEGER;
select_sym->ts.kind = gfc_default_integer_kind; select_sym->ts.kind = gfc_default_integer_kind;
gfc_set_sym_referenced (select_sym); gfc_set_sym_referenced (select_sym);
c->expr = gfc_get_expr (); c->expr1 = gfc_get_expr ();
c->expr->expr_type = EXPR_VARIABLE; c->expr1->expr_type = EXPR_VARIABLE;
c->expr->symtree = select_st; c->expr1->symtree = select_st;
c->expr->ts = select_sym->ts; c->expr1->ts = select_sym->ts;
c->expr->where = gfc_current_locus; c->expr1->where = gfc_current_locus;
i = 0; i = 0;
for (a = arglist; a; a = a->next) for (a = arglist; a; a = a->next)
...@@ -3655,7 +3655,7 @@ gfc_match_select (void) ...@@ -3655,7 +3655,7 @@ gfc_match_select (void)
return m; return m;
new_st.op = EXEC_SELECT; new_st.op = EXEC_SELECT;
new_st.expr = expr; new_st.expr1 = expr;
return MATCH_YES; return MATCH_YES;
} }
...@@ -3760,7 +3760,7 @@ match_simple_where (void) ...@@ -3760,7 +3760,7 @@ match_simple_where (void)
c = gfc_get_code (); c = gfc_get_code ();
c->op = EXEC_WHERE; c->op = EXEC_WHERE;
c->expr = expr; c->expr1 = expr;
c->next = gfc_get_code (); c->next = gfc_get_code ();
*c->next = new_st; *c->next = new_st;
...@@ -3801,7 +3801,7 @@ gfc_match_where (gfc_statement *st) ...@@ -3801,7 +3801,7 @@ gfc_match_where (gfc_statement *st)
{ {
*st = ST_WHERE_BLOCK; *st = ST_WHERE_BLOCK;
new_st.op = EXEC_WHERE; new_st.op = EXEC_WHERE;
new_st.expr = expr; new_st.expr1 = expr;
return MATCH_YES; return MATCH_YES;
} }
...@@ -3820,7 +3820,7 @@ gfc_match_where (gfc_statement *st) ...@@ -3820,7 +3820,7 @@ gfc_match_where (gfc_statement *st)
c = gfc_get_code (); c = gfc_get_code ();
c->op = EXEC_WHERE; c->op = EXEC_WHERE;
c->expr = expr; c->expr1 = expr;
c->next = gfc_get_code (); c->next = gfc_get_code ();
*c->next = new_st; *c->next = new_st;
...@@ -3890,7 +3890,7 @@ gfc_match_elsewhere (void) ...@@ -3890,7 +3890,7 @@ gfc_match_elsewhere (void)
} }
new_st.op = EXEC_WHERE; new_st.op = EXEC_WHERE;
new_st.expr = expr; new_st.expr1 = expr;
return MATCH_YES; return MATCH_YES;
syntax: syntax:
...@@ -4107,7 +4107,7 @@ match_simple_forall (void) ...@@ -4107,7 +4107,7 @@ match_simple_forall (void)
gfc_clear_new_st (); gfc_clear_new_st ();
new_st.op = EXEC_FORALL; new_st.op = EXEC_FORALL;
new_st.expr = mask; new_st.expr1 = mask;
new_st.ext.forall_iterator = head; new_st.ext.forall_iterator = head;
new_st.block = gfc_get_code (); new_st.block = gfc_get_code ();
...@@ -4159,7 +4159,7 @@ gfc_match_forall (gfc_statement *st) ...@@ -4159,7 +4159,7 @@ gfc_match_forall (gfc_statement *st)
{ {
*st = ST_FORALL_BLOCK; *st = ST_FORALL_BLOCK;
new_st.op = EXEC_FORALL; new_st.op = EXEC_FORALL;
new_st.expr = mask; new_st.expr1 = mask;
new_st.ext.forall_iterator = head; new_st.ext.forall_iterator = head;
return MATCH_YES; return MATCH_YES;
} }
...@@ -4182,7 +4182,7 @@ gfc_match_forall (gfc_statement *st) ...@@ -4182,7 +4182,7 @@ gfc_match_forall (gfc_statement *st)
gfc_clear_new_st (); gfc_clear_new_st ();
new_st.op = EXEC_FORALL; new_st.op = EXEC_FORALL;
new_st.expr = mask; new_st.expr1 = mask;
new_st.ext.forall_iterator = head; new_st.ext.forall_iterator = head;
new_st.block = gfc_get_code (); new_st.block = gfc_get_code ();
new_st.block->op = EXEC_FORALL; new_st.block->op = EXEC_FORALL;
......
...@@ -1072,20 +1072,20 @@ resolve_omp_atomic (gfc_code *code) ...@@ -1072,20 +1072,20 @@ resolve_omp_atomic (gfc_code *code)
gcc_assert (code->op == EXEC_ASSIGN); gcc_assert (code->op == EXEC_ASSIGN);
gcc_assert (code->next == NULL); gcc_assert (code->next == NULL);
if (code->expr->expr_type != EXPR_VARIABLE if (code->expr1->expr_type != EXPR_VARIABLE
|| code->expr->symtree == NULL || code->expr1->symtree == NULL
|| code->expr->rank != 0 || code->expr1->rank != 0
|| (code->expr->ts.type != BT_INTEGER || (code->expr1->ts.type != BT_INTEGER
&& code->expr->ts.type != BT_REAL && code->expr1->ts.type != BT_REAL
&& code->expr->ts.type != BT_COMPLEX && code->expr1->ts.type != BT_COMPLEX
&& code->expr->ts.type != BT_LOGICAL)) && code->expr1->ts.type != BT_LOGICAL))
{ {
gfc_error ("!$OMP ATOMIC statement must set a scalar variable of " gfc_error ("!$OMP ATOMIC statement must set a scalar variable of "
"intrinsic type at %L", &code->loc); "intrinsic type at %L", &code->loc);
return; return;
} }
var = code->expr->symtree->n.sym; var = code->expr1->symtree->n.sym;
expr2 = is_conversion (code->expr2, false); expr2 = is_conversion (code->expr2, false);
if (expr2 == NULL) if (expr2 == NULL)
expr2 = code->expr2; expr2 = code->expr2;
......
...@@ -2508,10 +2508,10 @@ parse_where_block (void) ...@@ -2508,10 +2508,10 @@ parse_where_block (void)
push_state (&s, COMP_WHERE, gfc_new_block); push_state (&s, COMP_WHERE, gfc_new_block);
d = add_statement (); d = add_statement ();
d->expr = top->expr; d->expr1 = top->expr1;
d->op = EXEC_WHERE; d->op = EXEC_WHERE;
top->expr = NULL; top->expr1 = NULL;
top->block = d; top->block = d;
seen_empty_else = 0; seen_empty_else = 0;
...@@ -2541,12 +2541,12 @@ parse_where_block (void) ...@@ -2541,12 +2541,12 @@ parse_where_block (void)
break; break;
} }
if (new_st.expr == NULL) if (new_st.expr1 == NULL)
seen_empty_else = 1; seen_empty_else = 1;
d = new_level (gfc_state_stack->head); d = new_level (gfc_state_stack->head);
d->op = EXEC_WHERE; d->op = EXEC_WHERE;
d->expr = new_st.expr; d->expr1 = new_st.expr1;
accept_statement (st); accept_statement (st);
...@@ -2651,8 +2651,8 @@ parse_if_block (void) ...@@ -2651,8 +2651,8 @@ parse_if_block (void)
new_st.op = EXEC_IF; new_st.op = EXEC_IF;
d = add_statement (); d = add_statement ();
d->expr = top->expr; d->expr1 = top->expr1;
top->expr = NULL; top->expr1 = NULL;
top->block = d; top->block = d;
do do
...@@ -2676,7 +2676,7 @@ parse_if_block (void) ...@@ -2676,7 +2676,7 @@ parse_if_block (void)
d = new_level (gfc_state_stack->head); d = new_level (gfc_state_stack->head);
d->op = EXEC_IF; d->op = EXEC_IF;
d->expr = new_st.expr; d->expr1 = new_st.expr1;
accept_statement (st); accept_statement (st);
......
...@@ -80,8 +80,8 @@ gfc_append_code (gfc_code *tail, gfc_code *new_code) ...@@ -80,8 +80,8 @@ gfc_append_code (gfc_code *tail, gfc_code *new_code)
void void
gfc_free_statement (gfc_code *p) gfc_free_statement (gfc_code *p)
{ {
if (p->expr) if (p->expr1)
gfc_free_expr (p->expr); gfc_free_expr (p->expr1);
if (p->expr2) if (p->expr2)
gfc_free_expr (p->expr2); gfc_free_expr (p->expr2);
......
...@@ -4014,7 +4014,7 @@ gfc_conv_expr_reference (gfc_se * se, gfc_expr * expr) ...@@ -4014,7 +4014,7 @@ gfc_conv_expr_reference (gfc_se * se, gfc_expr * expr)
tree tree
gfc_trans_pointer_assign (gfc_code * code) gfc_trans_pointer_assign (gfc_code * code)
{ {
return gfc_trans_pointer_assignment (code->expr, code->expr2); return gfc_trans_pointer_assignment (code->expr1, code->expr2);
} }
...@@ -4839,11 +4839,11 @@ gfc_trans_assignment (gfc_expr * expr1, gfc_expr * expr2, bool init_flag) ...@@ -4839,11 +4839,11 @@ gfc_trans_assignment (gfc_expr * expr1, gfc_expr * expr2, bool init_flag)
tree tree
gfc_trans_init_assign (gfc_code * code) gfc_trans_init_assign (gfc_code * code)
{ {
return gfc_trans_assignment (code->expr, code->expr2, true); return gfc_trans_assignment (code->expr1, code->expr2, true);
} }
tree tree
gfc_trans_assign (gfc_code * code) gfc_trans_assign (gfc_code * code)
{ {
return gfc_trans_assignment (code->expr, code->expr2, false); return gfc_trans_assignment (code->expr1, code->expr2, false);
} }
...@@ -2149,7 +2149,7 @@ gfc_trans_transfer (gfc_code * code) ...@@ -2149,7 +2149,7 @@ gfc_trans_transfer (gfc_code * code)
gfc_start_block (&block); gfc_start_block (&block);
gfc_init_block (&body); gfc_init_block (&body);
expr = code->expr; expr = code->expr1;
ss = gfc_walk_expr (expr); ss = gfc_walk_expr (expr);
ref = NULL; ref = NULL;
...@@ -2209,7 +2209,7 @@ gfc_trans_transfer (gfc_code * code) ...@@ -2209,7 +2209,7 @@ gfc_trans_transfer (gfc_code * code)
/* Initialize the loop. */ /* Initialize the loop. */
gfc_conv_ss_startstride (&loop); gfc_conv_ss_startstride (&loop);
gfc_conv_loop_setup (&loop, &code->expr->where); gfc_conv_loop_setup (&loop, &code->expr1->where);
/* The main loop body. */ /* The main loop body. */
gfc_mark_ss_chain_used (ss, 1); gfc_mark_ss_chain_used (ss, 1);
......
...@@ -952,13 +952,13 @@ gfc_trans_omp_atomic (gfc_code *code) ...@@ -952,13 +952,13 @@ gfc_trans_omp_atomic (gfc_code *code)
code = code->block->next; code = code->block->next;
gcc_assert (code->op == EXEC_ASSIGN); gcc_assert (code->op == EXEC_ASSIGN);
gcc_assert (code->next == NULL); gcc_assert (code->next == NULL);
var = code->expr->symtree->n.sym; var = code->expr1->symtree->n.sym;
gfc_init_se (&lse, NULL); gfc_init_se (&lse, NULL);
gfc_init_se (&rse, NULL); gfc_init_se (&rse, NULL);
gfc_start_block (&block); gfc_start_block (&block);
gfc_conv_expr (&lse, code->expr); gfc_conv_expr (&lse, code->expr1);
gfc_add_block_to_block (&block, &lse.pre); gfc_add_block_to_block (&block, &lse.pre);
type = TREE_TYPE (lse.expr); type = TREE_TYPE (lse.expr);
lhsaddr = gfc_build_addr_expr (NULL, lse.expr); lhsaddr = gfc_build_addr_expr (NULL, lse.expr);
......
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