https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87095

--- Comment #7 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Author: jakub
Date: Wed Sep  5 07:22:07 2018
New Revision: 264107

URL: https://gcc.gnu.org/viewcvs?rev=264107&root=gcc&view=rev
Log:
        Backported from mainline
        2018-08-29  Jakub Jelinek  <ja...@redhat.com>

        PR c++/87095
        * decl.c (begin_destructor_body): If current_class_type has
        virtual bases and the primary base is nearly empty virtual base,
        voidify clearing of vptr and make it conditional on in-charge
        argument.

        * g++.dg/ubsan/vptr-13.C: New test.

Added:
    branches/gcc-8-branch/gcc/testsuite/g++.dg/ubsan/vptr-13.C
Modified:
    branches/gcc-8-branch/gcc/cp/ChangeLog
    branches/gcc-8-branch/gcc/cp/decl.c
    branches/gcc-8-branch/gcc/testsuite/ChangeLog

Reply via email to