]> granicus.if.org Git - clang/commit
[ms-cxxabi] Elide dtor access checks for pass-by-val objects in callees
authorHans Wennborg <hans@hanshq.net>
Mon, 13 Jan 2014 17:23:24 +0000 (17:23 +0000)
committerHans Wennborg <hans@hanshq.net>
Mon, 13 Jan 2014 17:23:24 +0000 (17:23 +0000)
commit110038065b525ebadb0b1c7a757baf74cb7d0b84
tree034517f2cde46e143a68c8caf1981b2aa41d6306
parentad005369790fd8f53ff01c53625c3d4f5f2631ed
[ms-cxxabi] Elide dtor access checks for pass-by-val objects in callees

The ABI requires the destructor to be invoked in the callee, but the
standard does not require access checks here so we avoid doing direct
access checks on the destructor.

If we end up needing to define an implicit destructor, we don't skip
access checks for the base class, etc. Those checks are effectively part
of generating the destructor definition, and aren't affected by which TU
the check is performed in.

Differential Revision: http://llvm-reviews.chandlerc.com/D2409

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@199120 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Sema/SemaChecking.cpp
test/SemaCXX/microsoft-dtor-lookup.cpp
test/SemaObjCXX/microsoft-abi-byval.mm