summaryrefslogtreecommitdiff
path: root/gcc/cp/cp-tree.h
diff options
context:
space:
mode:
authorjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>2015-11-26 09:52:48 +0000
committerjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>2015-11-26 09:52:48 +0000
commite2225bd419ce30e32adc080be8cfe407d649fc95 (patch)
treea5817c2d93ec5378d7f944232b39f405296aa94f /gcc/cp/cp-tree.h
parent2c05794c14d393ab5085b99a6c712203e43b2014 (diff)
downloadgcc-e2225bd419ce30e32adc080be8cfe407d649fc95.tar.gz
PR c++/68508
* cp-tree.h (cp_ubsan_maybe_instrument_downcast): Add INTYPE argument. * cp-ubsan.c (cp_ubsan_maybe_instrument_downcast): Likewise. Use it instead of or in addition to TREE_TYPE (op). Use is_properly_derived_from, return NULL_TREE if TREE_TYPE (intype) and TREE_TYPE (type) are the same type minus qualifiers. * typeck.c (build_static_cast_1): Adjust callers. * g++.dg/ubsan/pr68508.C: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@230928 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cp/cp-tree.h')
-rw-r--r--gcc/cp/cp-tree.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/cp/cp-tree.h b/gcc/cp/cp-tree.h
index 1672291f9b6..caa601d1c98 100644
--- a/gcc/cp/cp-tree.h
+++ b/gcc/cp/cp-tree.h
@@ -6854,7 +6854,7 @@ extern bool cilk_valid_spawn (tree);
/* In cp-ubsan.c */
extern void cp_ubsan_maybe_instrument_member_call (tree);
extern void cp_ubsan_instrument_member_accesses (tree *);
-extern tree cp_ubsan_maybe_instrument_downcast (location_t, tree, tree);
+extern tree cp_ubsan_maybe_instrument_downcast (location_t, tree, tree, tree);
extern tree cp_ubsan_maybe_instrument_cast_to_vbase (location_t, tree, tree);
/* -- end of C++ */