diff options
author | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2015-01-29 20:40:07 +0000 |
---|---|---|
committer | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2015-01-29 20:40:07 +0000 |
commit | 72d590fcb895b5bec3c61dc6a437f69f24a78467 (patch) | |
tree | c120f358a21ea86209079717ef7ab2ac726a35b2 /gcc/cp/cp-ubsan.c | |
parent | 95a494fd8b1f52c8a7ae24dfd84b1f1b55f7f2cc (diff) | |
download | gcc-72d590fcb895b5bec3c61dc6a437f69f24a78467.tar.gz |
PR c++/64717
* cp-ubsan.c (cp_ubsan_instrument_vptr): Don't wrap vptr
into SAVE_EXPR.
* g++.dg/ubsan/pr64717-1.C: New test.
* g++.dg/ubsan/pr64717-2.C: New test.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@220262 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cp/cp-ubsan.c')
-rw-r--r-- | gcc/cp/cp-ubsan.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/gcc/cp/cp-ubsan.c b/gcc/cp/cp-ubsan.c index 69e486442fe..ce122631770 100644 --- a/gcc/cp/cp-ubsan.c +++ b/gcc/cp/cp-ubsan.c @@ -107,7 +107,6 @@ cp_ubsan_instrument_vptr (location_t loc, tree op, tree type, bool is_addr, fold_build2 (NE_EXPR, boolean_type_node, op, build_zero_cst (TREE_TYPE (op))), vptr, build_int_cst (uint64_type_node, 0)); - vptr = build1_loc (loc, SAVE_EXPR, uint64_type_node, vptr); tree ti_decl = get_tinfo_decl (type); mark_used (ti_decl); tree ptype = build_pointer_type (type); |