]> granicus.if.org Git - clang/commit
[Sema] Mark array element destructors referenced during initialization
authorErik Pilkington <erik.pilkington@gmail.com>
Fri, 10 May 2019 17:52:26 +0000 (17:52 +0000)
committerErik Pilkington <erik.pilkington@gmail.com>
Fri, 10 May 2019 17:52:26 +0000 (17:52 +0000)
commit66c0b31d40bdd797eef8184ec0626f3f212612b9
treec5e6795aef90b563d1ca4be7b7224383996a9b8d
parentc06fed002f4859ab3eaab5401d7d48a75ffecd89
[Sema] Mark array element destructors referenced during initialization

This fixes a crash where we would neglect to mark a destructor referenced for an
__attribute__((no_destory)) array. The destructor is needed though, since if an
exception is thrown we need to cleanup the elements.

rdar://48462498

Differential revision: https://reviews.llvm.org/D61165

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@360446 91177308-0d34-0410-b5e6-96231b3b80d8
include/clang/Basic/AttrDocs.td
lib/Sema/SemaDeclCXX.cpp
lib/Sema/SemaExprCXX.cpp
lib/Sema/SemaInit.cpp
test/CXX/expr/expr.unary/expr.new/p17.cpp
test/CodeGenCXX/no_destroy.cpp
test/SemaCXX/no_destroy.cpp