]> git.ipfire.org Git - thirdparty/gcc.git/blobdiff - gcc/cp/error.c
Merge ubsan into trunk.
[thirdparty/gcc.git] / gcc / cp / error.c
index cbb86a4874dfbd942f14124cc872f32ecd40711c..4ce1387e7ceebfb75b32bf676c032ba57be5df45 100644 (file)
@@ -32,6 +32,7 @@ along with GCC; see the file COPYING3.  If not see
 #include "tree-pretty-print.h"
 #include "pointer-set.h"
 #include "c-family/c-objc.h"
+#include "ubsan.h"
 
 #include <new>                    // For placement-new.
 
@@ -2007,6 +2008,12 @@ dump_expr (cxx_pretty_printer *pp, tree t, int flags)
              }
            skipfirst = true;
          }
+       if (flag_sanitize & SANITIZE_UNDEFINED
+           && is_ubsan_builtin_p (fn))
+         {
+           pp_string (cxx_pp, M_("<ubsan routine call>"));
+           break;
+         }
        dump_expr (pp, fn, flags | TFF_EXPR_IN_PARENS);
        dump_call_expr_args (pp, t, flags, skipfirst);
       }