]> granicus.if.org Git - clang/commit
Don't emit -Wnon-virtual-dtor on final classes, since it's not a problem there.
authorDavid Blaikie <dblaikie@gmail.com>
Fri, 9 May 2014 22:02:28 +0000 (22:02 +0000)
committerDavid Blaikie <dblaikie@gmail.com>
Fri, 9 May 2014 22:02:28 +0000 (22:02 +0000)
commitb8e405f9f3e00d9385239b0399b90b84d969e1e3
tree59c3054892fc0751fc8a93836c5a01cf1fe015a2
parentf6df606f3178a656f4f2886304474acd51cdf61c
Don't emit -Wnon-virtual-dtor on final classes, since it's not a problem there.

The base class is the culprit/risk here - a sealed/final derived class
with virtual functions and a non-virtual dtor can't accidentally be
polymorphically destroyed (if the base class's dtor is protected - which
also suppresses this warning).

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208449 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Sema/SemaDeclCXX.cpp
test/SemaCXX/destructor.cpp