]> granicus.if.org Git - clang/commitdiff
Kill off PreDeclaratorDC.
authorJohn McCall <rjmccall@apple.com>
Sat, 19 Dec 2009 10:53:49 +0000 (10:53 +0000)
committerJohn McCall <rjmccall@apple.com>
Sat, 19 Dec 2009 10:53:49 +0000 (10:53 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91772 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Sema/Sema.cpp
lib/Sema/Sema.h

index ef6147420bed88230de2b8735b6bf65e227d59d0..6119b13b73d22d20cee4271ebd884db916a30409 100644 (file)
@@ -350,7 +350,7 @@ Sema::Sema(Preprocessor &pp, ASTContext &ctxt, ASTConsumer &consumer,
   : LangOpts(pp.getLangOptions()), PP(pp), Context(ctxt), Consumer(consumer),
     Diags(PP.getDiagnostics()), SourceMgr(PP.getSourceManager()),
     ExternalSource(0), CodeCompleter(CodeCompleter), CurContext(0), 
-    PreDeclaratorDC(0), CurBlock(0), PackContext(0), ParsingDeclDepth(0),
+    CurBlock(0), PackContext(0), ParsingDeclDepth(0),
     IdResolver(pp.getLangOptions()), StdNamespace(0), StdBadAlloc(0),
     GlobalNewDeleteDeclared(false), 
     CompleteTranslationUnit(CompleteTranslationUnit),
@@ -815,7 +815,7 @@ void Sema::ActOnEndOfTranslationUnit() {
 //===----------------------------------------------------------------------===//
 
 DeclContext *Sema::getFunctionLevelDeclContext() {
-  DeclContext *DC = PreDeclaratorDC ? PreDeclaratorDC : CurContext;
+  DeclContext *DC = CurContext;
 
   while (isa<BlockDecl>(DC))
     DC = DC->getParent();
index 28993c7c5a6537c42ba5c4daecf9d97d9c66cc00..41081f2f13b7e3d94f48af8af1b0a2364a88bec8 100644 (file)
@@ -192,10 +192,6 @@ public:
   /// CurContext - This is the current declaration context of parsing.
   DeclContext *CurContext;
 
-  /// PreDeclaratorDC - Keeps the declaration context before switching to the
-  /// context of a declarator's nested-name-specifier.
-  DeclContext *PreDeclaratorDC;
-
   /// CurBlock - If inside of a block definition, this contains a pointer to
   /// the active block object that represents it.
   BlockSemaInfo *CurBlock;