https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89869
--- Comment #10 from Jakub Jelinek <jakub at gcc dot gnu.org> --- Author: jakub Date: Fri Aug 30 12:34:19 2019 New Revision: 275145 URL: https://gcc.gnu.org/viewcvs?rev=275145&root=gcc&view=rev Log: Backported from mainline 2019-03-29 Jakub Jelinek <ja...@redhat.com> PR sanitizer/89869 * typeck.c: Include gimplify.h. (cp_build_modify_expr) <case COND_EXPR>: Unshare rhs before using it for second time. Formatting fixes. * g++.dg/ubsan/vptr-14.C: New test. Added: branches/gcc-7-branch/gcc/testsuite/g++.dg/ubsan/vptr-14.C Modified: branches/gcc-7-branch/gcc/cp/ChangeLog branches/gcc-7-branch/gcc/cp/typeck.c branches/gcc-7-branch/gcc/testsuite/ChangeLog