aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran/trans-const.c
diff options
context:
space:
mode:
authorFrancois-Xavier Coudert <coudert@clipper.ens.fr>2006-06-03 17:28:33 +0000
committerFrancois-Xavier Coudert <coudert@clipper.ens.fr>2006-06-03 17:28:33 +0000
commit1a915414a33a0b7971bdfa6ae1d69f7675c5525c (patch)
tree2bd078734b2fda2d0a8face0efc809fc5f9589ef /gcc/fortran/trans-const.c
parent319dba87347c1e7a55d1f380c509d859be52b6f9 (diff)
* trans.c (gfc_msg_bounds, gfc_msg_fault, gfc_msg_wrong_return):
Add strings for common runtime error messages. (gfc_trans_runtime_check): Add a locus argument, use a string and not a string tree for the message. * trans.h (gfc_trans_runtime_check): Change prototype accordingly. (gfc_msg_bounds, gfc_msg_fault, gfc_msg_wrong_return): Add proto. * trans-const.c (gfc_strconst_bounds, gfc_strconst_fault, gfc_strconst_wrong_return, gfc_strconst_current_filename): Remove. (gfc_init_constants): Likewise. * trans-const.h: Likewise. * trans-decl.c (gfc_build_builtin_function_decls): Call to _gfortran_runtime_error has only one argument, the message string. * trans-array.h (gfc_conv_array_ref): Add a symbol argument and a locus. * trans-array.c (gfc_trans_array_bound_check): Build precise error messages. (gfc_conv_array_ref): Use the new symbol argument and the locus to build more precise error messages. (gfc_conv_ss_startstride): More precise error messages. * trans-expr.c (gfc_conv_variable): Give symbol reference and locus to gfc_conv_array_ref. (gfc_conv_function_call): Use the new prototype for gfc_trans_runtime_check. * trans-stmt.c (gfc_trans_goto): Build more precise error message. * trans-io.c (set_string): Likewise. * trans-intrinsic.c (gfc_conv_intrinsic_bound): Use new prototype for gfc_trans_runtime_check. git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@114346 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/fortran/trans-const.c')
-rw-r--r--gcc/fortran/trans-const.c17
1 files changed, 0 insertions, 17 deletions
diff --git a/gcc/fortran/trans-const.c b/gcc/fortran/trans-const.c
index 4a23a56854f..936dd6459af 100644
--- a/gcc/fortran/trans-const.c
+++ b/gcc/fortran/trans-const.c
@@ -33,12 +33,6 @@ Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA
#include "trans-const.h"
#include "trans-types.h"
-/* String constants. */
-tree gfc_strconst_bounds;
-tree gfc_strconst_fault;
-tree gfc_strconst_wrong_return;
-tree gfc_strconst_current_filename;
-
tree gfc_rank_cst[GFC_MAX_DIMENSIONS + 1];
/* Build a constant with given type from an int_cst. */
@@ -154,17 +148,6 @@ gfc_init_constants (void)
for (n = 0; n <= GFC_MAX_DIMENSIONS; n++)
gfc_rank_cst[n] = build_int_cst (gfc_array_index_type, n);
-
- gfc_strconst_bounds = gfc_build_cstring_const ("Array bound mismatch");
-
- gfc_strconst_fault =
- gfc_build_cstring_const ("Array reference out of bounds");
-
- gfc_strconst_wrong_return =
- gfc_build_cstring_const ("Incorrect function return value");
-
- gfc_strconst_current_filename =
- gfc_build_cstring_const (gfc_source_file);
}
/* Converts a GMP integer into a backend tree node. */