summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/Sema.cpp
diff options
context:
space:
mode:
authorManuel Klimek <klimek@google.com>2013-08-22 12:12:24 +0000
committerManuel Klimek <klimek@google.com>2013-08-22 12:12:24 +0000
commit2fdbea2819448ecb07ba69c5a70eb49691007880 (patch)
treeab24c9e98fe9246a5220986c29e031105ad9323c /clang/lib/Sema/Sema.cpp
parent1559dd8a1cd7cb372046148165a5d0409aff4d82 (diff)
downloadbcm5719-llvm-2fdbea2819448ecb07ba69c5a70eb49691007880.tar.gz
bcm5719-llvm-2fdbea2819448ecb07ba69c5a70eb49691007880.zip
Revert "Implement a rudimentary form of generic lambdas."
This reverts commit 606f5d7a99b11957e057e4cd1f55f931f66a42c7. llvm-svn: 189004
Diffstat (limited to 'clang/lib/Sema/Sema.cpp')
-rw-r--r--clang/lib/Sema/Sema.cpp25
1 files changed, 4 insertions, 21 deletions
diff --git a/clang/lib/Sema/Sema.cpp b/clang/lib/Sema/Sema.cpp
index aab03897963..6cc596cec1b 100644
--- a/clang/lib/Sema/Sema.cpp
+++ b/clang/lib/Sema/Sema.cpp
@@ -1007,17 +1007,10 @@ void Sema::PushBlockScope(Scope *BlockScope, BlockDecl *Block) {
BlockScope, Block));
}
-void Sema::PushLambdaScope() {
- FunctionScopes.push_back(new LambdaScopeInfo(getDiagnostics()));
-}
-
-void Sema::RecordParsingTemplateParameterDepth(unsigned Depth) {
- if (LambdaScopeInfo *const LSI = getCurLambda()) {
- LSI->AutoTemplateParameterDepth = Depth;
- return;
- }
- assert(false &&
- "Remove assertion if intentionally called in a non-lambda context.");
+void Sema::PushLambdaScope(CXXRecordDecl *Lambda,
+ CXXMethodDecl *CallOperator) {
+ FunctionScopes.push_back(new LambdaScopeInfo(getDiagnostics(), Lambda,
+ CallOperator));
}
void Sema::PopFunctionScopeInfo(const AnalysisBasedWarnings::Policy *WP,
@@ -1073,16 +1066,6 @@ LambdaScopeInfo *Sema::getCurLambda() {
return dyn_cast<LambdaScopeInfo>(FunctionScopes.back());
}
-// We have a generic lambda if we parsed auto parameters, or we have
-// an associated template parameter list.
-LambdaScopeInfo *Sema::getCurGenericLambda() {
- if (LambdaScopeInfo *LSI = getCurLambda()) {
- return (LSI->AutoTemplateParams.size() ||
- LSI->GLTemplateParameterList) ? LSI : 0;
- }
- return 0;
-}
-
void Sema::ActOnComment(SourceRange Comment) {
if (!LangOpts.RetainCommentsFromSystemHeaders &&
OpenPOWER on IntegriCloud