summaryrefslogtreecommitdiff
path: root/include/clang/Sema/Sema.h
diff options
context:
space:
mode:
authorArgyrios Kyrtzidis <akyrtzi@gmail.com>2013-03-14 22:56:43 +0000
committerArgyrios Kyrtzidis <akyrtzi@gmail.com>2013-03-14 22:56:43 +0000
commit57f8da506a0db208a936e26a8cb77267f638b26b (patch)
treeaad09d1013d6f2f69af87e0bef0c48c058496d73 /include/clang/Sema/Sema.h
parent503836ae835fd27a4c1f1c1b6cbe72dfc5613976 (diff)
downloadclang-57f8da506a0db208a936e26a8cb77267f638b26b.tar.gz
clang-57f8da506a0db208a936e26a8cb77267f638b26b.tar.bz2
clang-57f8da506a0db208a936e26a8cb77267f638b26b.tar.xz
Don't try to typo-correct 'super' in an objc method.
This created 2 issues: 1) Performance issue, since typo-correction with PCH/modules is rather expensive. 2) Correctness issue, since if it managed to "correct" 'super' then bogus compiler errors would be emitted, like this: 3.m:8:3: error: unknown type name 'super'; did you mean 'super1'? super.x = 0; ^~~~~ super1 t3.m:5:13: note: 'super1' declared here typedef int super1; ^ t3.m:8:8: error: expected identifier or '(' super.x = 0; ^ git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@177126 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Sema/Sema.h')
-rw-r--r--include/clang/Sema/Sema.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/clang/Sema/Sema.h b/include/clang/Sema/Sema.h
index 5f4bb1d840..0f519398b7 100644
--- a/include/clang/Sema/Sema.h
+++ b/include/clang/Sema/Sema.h
@@ -7430,6 +7430,8 @@ private:
/// The parser maintains this state here.
Scope *CurScope;
+ mutable IdentifierInfo *Ident_super;
+
protected:
friend class Parser;
friend class InitializationSequence;
@@ -7447,6 +7449,8 @@ public:
/// template substitution or instantiation.
Scope *getCurScope() const { return CurScope; }
+ IdentifierInfo *getSuperIdentifier() const;
+
Decl *getObjCDeclContext() const;
DeclContext *getCurLexicalContext() const {