summaryrefslogtreecommitdiff
path: root/lib/CodeGen/CGExprCXX.cpp
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2018-10-19 19:01:34 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2018-10-19 19:01:34 +0000
commit3c43b80122fc629f0d3bc4b723dbab8a66c9857b (patch)
tree9e8a0595b8267936ec8b9a076f1bf1964c293541 /lib/CodeGen/CGExprCXX.cpp
parent396dc1658c22d495834ce71a9c975770ed3fca40 (diff)
downloadclang-3c43b80122fc629f0d3bc4b723dbab8a66c9857b.tar.gz
PR24164, PR39336: init-captures are not distinct full-expressions.
Rather, they are subexpressions of the enclosing lambda-expression, and any temporaries in them are destroyed at the end of that full-expression, or when the corresponding lambda-expression is destroyed if they are lifetime-extended. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@344801 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGExprCXX.cpp')
-rw-r--r--lib/CodeGen/CGExprCXX.cpp1
1 files changed, 0 insertions, 1 deletions
diff --git a/lib/CodeGen/CGExprCXX.cpp b/lib/CodeGen/CGExprCXX.cpp
index 393a4aa787..ae6653ec48 100644
--- a/lib/CodeGen/CGExprCXX.cpp
+++ b/lib/CodeGen/CGExprCXX.cpp
@@ -2252,7 +2252,6 @@ llvm::Value *CodeGenFunction::EmitDynamicCast(Address ThisAddr,
}
void CodeGenFunction::EmitLambdaExpr(const LambdaExpr *E, AggValueSlot Slot) {
- RunCleanupsScope Scope(*this);
LValue SlotLV = MakeAddrLValue(Slot.getAddress(), E->getType());
CXXRecordDecl::field_iterator CurField = E->getLambdaClass()->field_begin();