diff options
author | Janus Weil <janus@gcc.gnu.org> | 2013-08-09 21:26:07 +0200 |
---|---|---|
committer | Janus Weil <janus@gcc.gnu.org> | 2013-08-09 21:26:07 +0200 |
commit | 11e5274a4bb2ae1338c8b447c9880ace43aac129 (patch) | |
tree | 0ac9c4560a8ad95d76c1854f90668bda6feda0ad /gcc/fortran/io.c | |
parent | 2fa3d31bd6bb9274abaa3a7d59cc88e9a6112194 (diff) | |
download | gcc-11e5274a4bb2ae1338c8b447c9880ace43aac129.zip gcc-11e5274a4bb2ae1338c8b447c9880ace43aac129.tar.gz gcc-11e5274a4bb2ae1338c8b447c9880ace43aac129.tar.bz2 |
gfortran.h (gfc_get_code): Modified prototype.
2013-08-09 Janus Weil <janus@gcc.gnu.org>
* gfortran.h (gfc_get_code): Modified prototype.
* class.c (finalize_component, finalization_scalarizer,
finalization_get_offset, finalizer_insert_packed_call,
generate_finalization_wrapper, gfc_find_derived_vtab,
gfc_find_intrinsic_vtab): Use 'gfc_get_code'.
* io.c (match_io_iterator, match_io_element, terminate_io, get_io_list,
gfc_match_inquire): Call 'gfc_get_code' with argument.
* match.c (match_simple_forall, gfc_match_forall, gfc_match_goto,
gfc_match_nullify, gfc_match_call, match_simple_where, gfc_match_where):
Ditto.
* parse.c (new_level): Ditto.
(add_statement): Use XCNEW.
* resolve.c (resolve_entries, resolve_allocate_expr,
resolve_select_type, build_assignment, build_init_assign): Call
'gfc_get_code' with argument.
* st.c (gfc_get_code): Add argument 'op'.
* trans-expr.c (gfc_trans_class_array_init_assign): Call 'gfc_get_code'
with argument.
* trans-stmt.c (gfc_trans_allocate): Ditto.
From-SVN: r201635
Diffstat (limited to 'gcc/fortran/io.c')
-rw-r--r-- | gcc/fortran/io.c | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/gcc/fortran/io.c b/gcc/fortran/io.c index 678bc5d..cc5ce12 100644 --- a/gcc/fortran/io.c +++ b/gcc/fortran/io.c @@ -3055,12 +3055,10 @@ match_io_iterator (io_kind k, gfc_code **result) if (gfc_match_char (')') != MATCH_YES) goto syntax; - new_code = gfc_get_code (); - new_code->op = EXEC_DO; + new_code = gfc_get_code (EXEC_DO); new_code->ext.iterator = iter; - new_code->block = gfc_get_code (); - new_code->block->op = EXEC_DO; + new_code->block = gfc_get_code (EXEC_DO); new_code->block->next = head; *result = new_code; @@ -3117,8 +3115,7 @@ match_io_element (io_kind k, gfc_code **cpp) return MATCH_ERROR; } - cp = gfc_get_code (); - cp->op = EXEC_TRANSFER; + cp = gfc_get_code (EXEC_TRANSFER); cp->expr1 = expr; if (k != M_INQUIRE) cp->ext.dt = current_dt; @@ -3180,8 +3177,7 @@ terminate_io (gfc_code *io_code) if (io_code == NULL) io_code = new_st.block; - c = gfc_get_code (); - c->op = EXEC_DT_END; + c = gfc_get_code (EXEC_DT_END); /* Point to structure that is already there */ c->ext.dt = new_st.ext.dt; @@ -3751,8 +3747,7 @@ get_io_list: new_st.op = (k == M_READ) ? EXEC_READ : EXEC_WRITE; new_st.ext.dt = dt; - new_st.block = gfc_get_code (); - new_st.block->op = new_st.op; + new_st.block = gfc_get_code (new_st.op); new_st.block->next = io_code; terminate_io (io_code); @@ -3961,8 +3956,7 @@ gfc_match_inquire (void) if (gfc_implicit_pure (NULL)) gfc_current_ns->proc_name->attr.implicit_pure = 0; - new_st.block = gfc_get_code (); - new_st.block->op = EXEC_IOLENGTH; + new_st.block = gfc_get_code (EXEC_IOLENGTH); terminate_io (code); new_st.block->next = code; return MATCH_YES; |