diff options
author | mueller <mueller@138bc75d-0d04-0410-961f-82ee72b054a4> | 2007-01-18 13:00:33 +0000 |
---|---|---|
committer | mueller <mueller@138bc75d-0d04-0410-961f-82ee72b054a4> | 2007-01-18 13:00:33 +0000 |
commit | 5bc9639859eb6ad2ec09d09aa2cb28fd029edcc1 (patch) | |
tree | 2d86bde5e9f2aefe4b2d4556eac1f4327318abb4 /gcc/common.opt | |
parent | b7fcd3f95fa452127c1b12fdc0d702784bccff60 (diff) | |
download | gcc-5bc9639859eb6ad2ec09d09aa2cb28fd029edcc1.tar.gz |
2007-01-18 Dirk Mueller <dmueller@suse.de>
· Richard Guenther <rguenther@suse.de>
· PR diagnostic/8268
· * doc/invoke.texi (Warray-bounds): Document -Warray-bounds.
· * common.opt (Warray-bounds): Add new warning option.
· * c-opts.c (c_common_handle_option): Define -Warray-bounds
· if -Wall is given.
* Makefile.in: make tree-vrp.o depend on toplev.h
· * tree-vrp.c (vrp_finalize): Call check_array_refs if -Warray-bounds
· is enabled.
· (check_array_refs, check_array_bounds, check_array_ref): New.
· * gcc.dg/Warray-bounds.c: New testcase.
* gcc.dg/Warray-bounds-2.c: New testcase.
* g++.dg/warn/Warray-bounds.C: New testcase.
* g++.dg/warn/Warray-bounds-2.C: New testcase.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@120898 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/common.opt')
-rw-r--r-- | gcc/common.opt | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/gcc/common.opt b/gcc/common.opt index e237fc1fd28..109de7bf3d4 100644 --- a/gcc/common.opt +++ b/gcc/common.opt @@ -61,6 +61,10 @@ Walways-true Common Var(warn_always_true) Warn about comparisons that always evaluate to true +Warray-bounds +Common Var(warn_array_bounds) +Warn if an array is accessed out of bounds + Wattributes Common Var(warn_attributes) Init(1) Warn about inappropriate attribute usage |