summaryrefslogtreecommitdiffstats
path: root/lldb/scripts/Python/prepare_binding_Python.py
diff options
context:
space:
mode:
authorNico Weber <nicolasweber@gmx.de>2016-01-15 21:45:31 +0000
committerNico Weber <nicolasweber@gmx.de>2016-01-15 21:45:31 +0000
commit5a9259caa9b78d098ace55703db69beadacdfcce (patch)
tree55224854401d1238e30fba380483c43ed9a63ee5 /lldb/scripts/Python/prepare_binding_Python.py
parent851da71c8fec4ab7d5a3461d486ddbf83fcc91ec (diff)
downloadbcm5719-llvm-5a9259caa9b78d098ace55703db69beadacdfcce.tar.gz
bcm5719-llvm-5a9259caa9b78d098ace55703db69beadacdfcce.zip
Make -Wdelete-non-virtual-dtor warn on explicit `a->~A()` dtor calls too.
-Wdelete-non-virtual-dtor warns if A is a type with virtual functions but without virtual dtor has its constructor called via `delete a`. This makes the warning also fire if the dtor is called via `a->~A()`. This would've found a security bug in Chromium at compile time. Fixes PR26137. To fix the warning, add a virtual destructor, make the class final, or remove its other virtual methods. If you want to silence the warning, there's also a fixit that shows how: test.cc:12:3: warning: destructor called on 'B' ... [-Wdelete-non-virtual-dtor] b->~B(); ^ test.cc:12:6: note: qualify call to silence this warning b->~B(); ^ B:: http://reviews.llvm.org/D16206 llvm-svn: 257939
Diffstat (limited to 'lldb/scripts/Python/prepare_binding_Python.py')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud