summaryrefslogtreecommitdiff
path: root/lib/Sema/TreeTransform.h
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2019-05-28 23:09:46 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2019-05-28 23:09:46 +0000
commit120851d42c6bb4abd5c8b13de6e498216478610d (patch)
treedfc098b41acf5edb3b911349a5d16a655c9e71a2 /lib/Sema/TreeTransform.h
parenta2b584af8864e3cb3bbce11cd50d682559cda7ff (diff)
downloadclang-120851d42c6bb4abd5c8b13de6e498216478610d.tar.gz
Defer creating fields for captures until we finish building the
capturing expression or statement. No functionality change yet. The intent is that we will also delay building the initialization expression until the enclosing context, so that: a) we build the initialization expression in the right context, and b) we can elide captures that are not odr-used, as suggested by P0588R1. This also consolidates some duplicated code building capture fields into a single place. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@361893 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/TreeTransform.h')
-rw-r--r--lib/Sema/TreeTransform.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Sema/TreeTransform.h b/lib/Sema/TreeTransform.h
index b5114eeef3..6620885f23 100644
--- a/lib/Sema/TreeTransform.h
+++ b/lib/Sema/TreeTransform.h
@@ -11382,7 +11382,7 @@ TreeTransform<Derived>::TransformLambdaExpr(LambdaExpr *E) {
break;
}
NewVDs.push_back(NewVD);
- getSema().buildInitCaptureField(LSI, NewVD);
+ getSema().addInitCapture(LSI, NewVD);
}
if (Invalid)