diff options
Diffstat (limited to 'lib/Sema/SemaCodeComplete.cpp')
-rw-r--r-- | lib/Sema/SemaCodeComplete.cpp | 34 |
1 files changed, 2 insertions, 32 deletions
diff --git a/lib/Sema/SemaCodeComplete.cpp b/lib/Sema/SemaCodeComplete.cpp index 76452a4516..b33f3fcb7c 100644 --- a/lib/Sema/SemaCodeComplete.cpp +++ b/lib/Sema/SemaCodeComplete.cpp @@ -4171,9 +4171,7 @@ static void AddObjCMethods(ObjCContainerDecl *Container, } -void Sema::CodeCompleteObjCPropertyGetter(Scope *S, Decl *ClassDecl, - Decl **Methods, - unsigned NumMethods) { +void Sema::CodeCompleteObjCPropertyGetter(Scope *S, Decl *ClassDecl) { typedef CodeCompletionResult Result; // Try to find the interface where getters might live. @@ -4191,19 +4189,6 @@ void Sema::CodeCompleteObjCPropertyGetter(Scope *S, Decl *ClassDecl, ResultBuilder Results(*this, CodeCompletionContext::CCC_Other); Results.EnterNewScope(); - // FIXME: We need to do this because Objective-C methods don't get - // pushed into DeclContexts early enough. Argh! - for (unsigned I = 0; I != NumMethods; ++I) { - if (ObjCMethodDecl *Method - = dyn_cast_or_null<ObjCMethodDecl>(Methods[I])) - if (Method->isInstanceMethod() && - isAcceptableObjCMethod(Method, MK_ZeroArgSelector, 0, 0)) { - Result R = Result(Method, 0); - R.AllParametersAreInformative = true; - Results.MaybeAddResult(R, CurContext); - } - } - VisitedSelectorSet Selectors; AddObjCMethods(Class, true, MK_ZeroArgSelector, 0, 0, CurContext, Selectors, /*AllowSameLength=*/true, Results); @@ -4213,9 +4198,7 @@ void Sema::CodeCompleteObjCPropertyGetter(Scope *S, Decl *ClassDecl, Results.data(),Results.size()); } -void Sema::CodeCompleteObjCPropertySetter(Scope *S, Decl *ObjCImplDecl, - Decl **Methods, - unsigned NumMethods) { +void Sema::CodeCompleteObjCPropertySetter(Scope *S, Decl *ObjCImplDecl) { typedef CodeCompletionResult Result; // Try to find the interface where setters might live. @@ -4234,19 +4217,6 @@ void Sema::CodeCompleteObjCPropertySetter(Scope *S, Decl *ObjCImplDecl, ResultBuilder Results(*this, CodeCompletionContext::CCC_Other); Results.EnterNewScope(); - // FIXME: We need to do this because Objective-C methods don't get - // pushed into DeclContexts early enough. Argh! - for (unsigned I = 0; I != NumMethods; ++I) { - if (ObjCMethodDecl *Method - = dyn_cast_or_null<ObjCMethodDecl>(Methods[I])) - if (Method->isInstanceMethod() && - isAcceptableObjCMethod(Method, MK_OneArgSelector, 0, 0)) { - Result R = Result(Method, 0); - R.AllParametersAreInformative = true; - Results.MaybeAddResult(R, CurContext); - } - } - VisitedSelectorSet Selectors; AddObjCMethods(Class, true, MK_OneArgSelector, 0, 0, CurContext, Selectors, /*AllowSameLength=*/true, Results); |