Commit 02f06e64 by Greg McGary Committed by Greg McGary

top.h (ffe_is_subscript_check_): Remove extern decl.

* top.h (ffe_is_subscript_check_): Remove extern decl.
(ffe_is_subscript_check, ffe_set_is_subscript_check): Remove macros.
* top.c (ffe_is_subscript_check_): Remove global variable.
(ffe_decode_option): Remove "(no-)bounds-check" flag handling.
Set flag_bounds_check for "(no-)fortran-bounds-check".
* com.c
(ffecom_arrayref_): s/ffe_is_subscript_check ()/flag_bounds_check/
(ffecom_char_args_x_): Ditto.

From-SVN: r30037
parent 13f9ac51
Fri Oct 15 15:18:12 1999 Greg McGary <gkm@gnu.org>
* top.h (ffe_is_subscript_check_): Remove extern decl.
(ffe_is_subscript_check, ffe_set_is_subscript_check): Remove macros.
* top.c (ffe_is_subscript_check_): Remove global variable.
(ffe_decode_option): Remove "(no-)bounds-check" flag handling.
Set flag_bounds_check for "(no-)fortran-bounds-check".
* com.c
(ffecom_arrayref_): s/ffe_is_subscript_check ()/flag_bounds_check/
(ffecom_char_args_x_): Ditto.
Sun Oct 10 08:40:18 1999 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* proj.h: Use HAVE_GCC_VERSION instead of explicitly testing
......@@ -60,7 +71,7 @@ Sat Sep 4 13:46:27 1999 Mark Mitchell <mark@codesourcery.com>
* Make-lang.in (f771): Depend on ggc-callbacks.o.
* Makefile.in (OBJS): Add ggc-callbacks.o.
(OBJDEPS): Likewise.
Mon Aug 30 22:05:53 1999 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* com.c (language_string): Constify.
......
/* com.c -- Implementation File (module.c template V1.0)
Copyright (C) 1995-1998 Free Software Foundation, Inc.
Copyright (C) 1995-1999 Free Software Foundation, Inc.
Contributed by James Craig Burley.
This file is part of GNU Fortran.
......@@ -952,7 +952,7 @@ ffecom_arrayref_ (tree item, ffebld expr, int want_ptr)
{
min = TYPE_MIN_VALUE (TYPE_DOMAIN (array));
element = ffecom_expr_ (dims[i], NULL, NULL, NULL, FALSE, TRUE);
if (ffe_is_subscript_check ())
if (flag_bounds_check)
element = ffecom_subscript_check_ (array, element, i, total_dims,
array_name);
if (element == error_mark_node)
......@@ -998,7 +998,7 @@ ffecom_arrayref_ (tree item, ffebld expr, int want_ptr)
array = TYPE_MAIN_VARIANT (TREE_TYPE (item));
element = ffecom_expr_ (dims[i], NULL, NULL, NULL, FALSE, TRUE);
if (ffe_is_subscript_check ())
if (flag_bounds_check)
element = ffecom_subscript_check_ (array, element, i, total_dims,
array_name);
if (element == error_mark_node)
......@@ -2126,7 +2126,7 @@ ffecom_char_args_x_ (tree *xitem, tree *length, ffebld expr, bool with_null)
else
{
end_tree = ffecom_expr (end);
if (ffe_is_subscript_check ())
if (flag_bounds_check)
end_tree = ffecom_subscript_check_ (array, end_tree, 1, 0,
char_name);
end_tree = convert (ffecom_f2c_ftnlen_type_node,
......@@ -2144,7 +2144,7 @@ ffecom_char_args_x_ (tree *xitem, tree *length, ffebld expr, bool with_null)
else
{
start_tree = ffecom_expr (start);
if (ffe_is_subscript_check ())
if (flag_bounds_check)
start_tree = ffecom_subscript_check_ (array, start_tree, 0, 0,
char_name);
start_tree = convert (ffecom_f2c_ftnlen_type_node,
......@@ -2177,7 +2177,7 @@ ffecom_char_args_x_ (tree *xitem, tree *length, ffebld expr, bool with_null)
else
{
end_tree = ffecom_expr (end);
if (ffe_is_subscript_check ())
if (flag_bounds_check)
end_tree = ffecom_subscript_check_ (array, end_tree, 1, 0,
char_name);
end_tree = convert (ffecom_f2c_ftnlen_type_node,
......
/* top.c -- Implementation File (module.c template V1.0)
Copyright (C) 1995-1997 Free Software Foundation, Inc.
Copyright (C) 1995-1997, 1999 Free Software Foundation, Inc.
Contributed by James Craig Burley.
This file is part of GNU Fortran.
......@@ -83,7 +83,6 @@ bool ffe_is_mainprog_; /* TRUE if current prog unit known to be
bool ffe_is_null_version_ = FALSE;
bool ffe_is_onetrip_ = FALSE;
bool ffe_is_silent_ = TRUE;
bool ffe_is_subscript_check_ = FALSE;
bool ffe_is_typeless_boz_ = FALSE;
bool ffe_is_pedantic_ = FFETARGET_defaultIS_PEDANTIC;
bool ffe_is_saveall_; /* TRUE if mainprog or SAVE (no args) seen. */
......@@ -323,14 +322,10 @@ ffe_decode_option (argc, argv)
ffe_set_is_globals (TRUE);
else if (strcmp (&opt[2], "no-globals") == 0)
ffe_set_is_globals (FALSE);
else if (strcmp (&opt[2], "bounds-check") == 0)
ffe_set_is_subscript_check (TRUE);
else if (strcmp (&opt[2], "no-bounds-check") == 0)
ffe_set_is_subscript_check (FALSE);
else if (strcmp (&opt[2], "fortran-bounds-check") == 0)
ffe_set_is_subscript_check (TRUE);
flag_bounds_check = TRUE;
else if (strcmp (&opt[2], "no-fortran-bounds-check") == 0)
ffe_set_is_subscript_check (FALSE);
flag_bounds_check = FALSE;
else if (strcmp (&opt[2], "typeless-boz") == 0)
ffe_set_is_typeless_boz (TRUE);
else if (strcmp (&opt[2], "no-typeless-boz") == 0)
......
/* top.h -- Public #include File (module.h template V1.0)
Copyright (C) 1995-1997 Free Software Foundation, Inc.
Copyright (C) 1995-1997, 1999 Free Software Foundation, Inc.
Contributed by James Craig Burley.
This file is part of GNU Fortran.
......@@ -98,7 +98,6 @@ extern bool ffe_is_mainprog_;
extern bool ffe_is_null_version_;
extern bool ffe_is_onetrip_;
extern bool ffe_is_silent_;
extern bool ffe_is_subscript_check_;
extern bool ffe_is_typeless_boz_;
extern bool ffe_is_pedantic_;
extern bool ffe_is_saveall_;
......@@ -191,7 +190,6 @@ void ffe_terminate_4 (void);
#define ffe_is_saveall() ffe_is_saveall_
#define ffe_is_second_underscore() ffe_is_second_underscore_
#define ffe_is_silent() ffe_is_silent_
#define ffe_is_subscript_check() ffe_is_subscript_check_
#define ffe_is_typeless_boz() ffe_is_typeless_boz_
#define ffe_is_ugly_args() ffe_is_ugly_args_
#define ffe_is_ugly_assign() ffe_is_ugly_assign_
......@@ -243,7 +241,6 @@ void ffe_terminate_4 (void);
#define ffe_set_is_saveall(f) (ffe_is_saveall_ = (f))
#define ffe_set_is_second_underscore(f) (ffe_is_second_underscore_ = (f))
#define ffe_set_is_silent(f) (ffe_is_silent_ = (f))
#define ffe_set_is_subscript_check(f) (ffe_is_subscript_check_ = (f))
#define ffe_set_is_typeless_boz(f) (ffe_is_typeless_boz_ = (f))
#define ffe_set_is_ugly_args(f) (ffe_is_ugly_args_ = (f))
#define ffe_set_is_ugly_assign(f) (ffe_is_ugly_assign_ = (f))
......
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