summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/ScopeInfo.cpp
diff options
context:
space:
mode:
authorBrian Gesiak <modocache@gmail.com>2018-01-24 22:15:42 +0000
committerBrian Gesiak <modocache@gmail.com>2018-01-24 22:15:42 +0000
commit61f4ac98e019e0e7ce5adbc58474fdcf7f49c300 (patch)
treeb0027f41c94b5e5b1aba481557ef6fdb42c8fc8b /clang/lib/Sema/ScopeInfo.cpp
parent292617e7003efdbc4dd84bc49423dc662f856fb6 (diff)
downloadbcm5719-llvm-61f4ac98e019e0e7ce5adbc58474fdcf7f49c300.tar.gz
bcm5719-llvm-61f4ac98e019e0e7ce5adbc58474fdcf7f49c300.zip
[coroutines] Pass coro func args to promise ctor
Summary: Use corutine function arguments to initialize a promise type, but only if the promise type defines a constructor that takes those arguments. Otherwise, fall back to the default constructor. Test Plan: check-clang Reviewers: rsmith, GorNishanov, eric_niebler Reviewed By: GorNishanov Subscribers: toby-allsopp, lewissbaker, EricWF, cfe-commits Differential Revision: https://reviews.llvm.org/D41820 llvm-svn: 323381
Diffstat (limited to 'clang/lib/Sema/ScopeInfo.cpp')
-rw-r--r--clang/lib/Sema/ScopeInfo.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/clang/lib/Sema/ScopeInfo.cpp b/clang/lib/Sema/ScopeInfo.cpp
index b309a36a30a..62a83ccb70a 100644
--- a/clang/lib/Sema/ScopeInfo.cpp
+++ b/clang/lib/Sema/ScopeInfo.cpp
@@ -43,6 +43,7 @@ void FunctionScopeInfo::Clear() {
// Coroutine state
FirstCoroutineStmtLoc = SourceLocation();
CoroutinePromise = nullptr;
+ CoroutineParameterMoves.clear();
NeedsCoroutineSuspends = true;
CoroutineSuspends.first = nullptr;
CoroutineSuspends.second = nullptr;
OpenPOWER on IntegriCloud