aboutsummaryrefslogtreecommitdiff
path: root/lib/Sema/SemaExpr.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2012-02-09 02:12:34 +0000
committerDouglas Gregor <dgregor@apple.com>2012-02-09 02:12:34 +0000
commit20f87a4cd91b8d76571dc96aece916ac0bdf8b9f (patch)
treedadaed109f3f25aef109fafdac5948e25a6e23b1 /lib/Sema/SemaExpr.cpp
parent1f9a5db047c00f66f4a1ebfc6ae2bf78433036e3 (diff)
When we create a non-static data member in the closure object for a
capture, make sure we actually add the field. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@150135 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaExpr.cpp')
-rw-r--r--lib/Sema/SemaExpr.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/Sema/SemaExpr.cpp b/lib/Sema/SemaExpr.cpp
index 11468e8676..4db266b2ed 100644
--- a/lib/Sema/SemaExpr.cpp
+++ b/lib/Sema/SemaExpr.cpp
@@ -9576,6 +9576,7 @@ static ExprResult captureInLambda(Sema &S, LambdaScopeInfo *LSI,
0, false, false);
Field->setImplicit(true);
Field->setAccess(AS_private);
+ Lambda->addDecl(Field);
// C++11 [expr.prim.lambda]p21:
// When the lambda-expression is evaluated, the entities that