diff options
author | Marc Glisse <marc.glisse@inria.fr> | 2013-10-03 18:13:54 +0200 |
---|---|---|
committer | Marc Glisse <glisse@gcc.gnu.org> | 2013-10-03 16:13:54 +0000 |
commit | 2284b03444d6845ce6402db37f4ec43f6c755f77 (patch) | |
tree | 626a1783dbadedeb04e9dc7b74807b9ad23cc8c7 /gcc/c-family | |
parent | 0609bdf2114919b570e7a3c4ab273fdf16262a4b (diff) | |
download | gcc-2284b03444d6845ce6402db37f4ec43f6c755f77.zip gcc-2284b03444d6845ce6402db37f4ec43f6c755f77.tar.gz gcc-2284b03444d6845ce6402db37f4ec43f6c755f77.tar.bz2 |
re PR c++/19476 (Missed null checking elimination with new)
2013-10-03 Marc Glisse <marc.glisse@inria.fr>
PR c++/19476
gcc/c-family/
* c.opt (fcheck-new): Move to common.opt.
gcc/
* common.opt (fcheck-new): Moved from c.opt. Make it 'Common'.
* calls.c (alloca_call_p): Use get_callee_fndecl.
* fold-const.c (tree_expr_nonzero_warnv_p): Handle operator new.
* tree-vrp.c (gimple_stmt_nonzero_warnv_p, stmt_interesting_for_vrp):
Likewise.
(vrp_visit_stmt): Remove duplicated code.
gcc/testsuite/
* g++.dg/tree-ssa/pr19476-1.C: New file.
* g++.dg/tree-ssa/pr19476-2.C: Likewise.
* g++.dg/tree-ssa/pr19476-3.C: Likewise.
* g++.dg/tree-ssa/pr19476-4.C: Likewise.
From-SVN: r203163
Diffstat (limited to 'gcc/c-family')
-rw-r--r-- | gcc/c-family/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/c-family/c.opt | 4 |
2 files changed, 5 insertions, 4 deletions
diff --git a/gcc/c-family/ChangeLog b/gcc/c-family/ChangeLog index c7a8c787..d468344 100644 --- a/gcc/c-family/ChangeLog +++ b/gcc/c-family/ChangeLog @@ -1,3 +1,8 @@ +2013-10-03 Marc Glisse <marc.glisse@inria.fr> + + PR c++/19476 + * c.opt (fcheck-new): Move to common.opt. + 2013-09-25 Marek Polacek <polacek@redhat.com> Jakub Jelinek <jakub@redhat.com> diff --git a/gcc/c-family/c.opt b/gcc/c-family/c.opt index 24d1b87..e8dde93 100644 --- a/gcc/c-family/c.opt +++ b/gcc/c-family/c.opt @@ -855,10 +855,6 @@ fcilkplus C ObjC C++ ObjC++ LTO Report Var(flag_enable_cilkplus) Init(0) Enable Cilk Plus -fcheck-new -C++ ObjC++ Var(flag_check_new) -Check the return value of new - fcond-mismatch C ObjC C++ ObjC++ Allow the arguments of the '?' operator to have different types |