diff options
author | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2012-02-07 16:50:53 +0000 |
---|---|---|
committer | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2012-02-07 16:50:53 +0000 |
commit | 849639d8b548519cc5a00c0c9253f0c0d525060d (patch) | |
tree | a812a80ebb5de2431d3c647299a43dd9efec26cf /lib/Sema/Sema.cpp | |
parent | b534a9ed04b343534e5f277b81d1170de3204164 (diff) |
Make parsing of objc @implementations more robust.
Parsing of @implementations was based on modifying global state from
the parser; the logic for late parsing of methods was spread in multiple places
making it difficult to have a robust error recovery.
-it was difficult to ensure that we don't neglect parsing the lexed methods.
-it was difficult to setup the original objc container context for parsing the lexed methods
after completing ParseObjCAtImplementationDeclaration and returning to top level context.
Enhance parsing of @implementations by centralizing it in Parser::ParseObjCAtImplementationDeclaration().
ParseObjCAtImplementationDeclaration now returns only after an @implementation is fully parsed;
all the data and logic for late parsing of methods is now in one place.
This allows us to provide code-completion for late parsed methods with mis-matched braces.
rdar://10775381
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149987 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/Sema.cpp')
-rw-r--r-- | lib/Sema/Sema.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/Sema/Sema.cpp b/lib/Sema/Sema.cpp index 42c7897743..9c5bdbea6a 100644 --- a/lib/Sema/Sema.cpp +++ b/lib/Sema/Sema.cpp @@ -418,6 +418,8 @@ void Sema::ActOnEndOfTranslationUnit() { // Only complete translation units define vtables and perform implicit // instantiations. if (TUKind == TU_Complete) { + DiagnoseUseOfUnimplementedSelectors(); + // If any dynamic classes have their key function defined within // this translation unit, then those vtables are considered "used" and must // be emitted. |