forked from OSchip/llvm-project
Fix ObjCInterfaceDecl::getCategoryMethod() and give it a caller. No behavior change.
llvm-svn: 230928
This commit is contained in:
parent
43e7f96f64
commit
f609839244
|
@ -820,8 +820,8 @@ public:
|
|||
ObjCMethodDecl *getCategoryInstanceMethod(Selector Sel) const;
|
||||
ObjCMethodDecl *getCategoryClassMethod(Selector Sel) const;
|
||||
ObjCMethodDecl *getCategoryMethod(Selector Sel, bool isInstance) const {
|
||||
return isInstance ? getInstanceMethod(Sel)
|
||||
: getClassMethod(Sel);
|
||||
return isInstance ? getCategoryInstanceMethod(Sel)
|
||||
: getCategoryClassMethod(Sel);
|
||||
}
|
||||
|
||||
typedef ObjCProtocolList::iterator protocol_iterator;
|
||||
|
|
|
@ -616,8 +616,7 @@ ObjCMethodDecl *ObjCInterfaceDecl::lookupPrivateMethod(
|
|||
|
||||
// Look through local category implementations associated with the class.
|
||||
if (!Method)
|
||||
Method = Instance ? getCategoryInstanceMethod(Sel)
|
||||
: getCategoryClassMethod(Sel);
|
||||
Method = getCategoryMethod(Sel, Instance);
|
||||
|
||||
// Before we give up, check if the selector is an instance method.
|
||||
// But only in the root. This matches gcc's behavior and what the
|
||||
|
|
Loading…
Reference in New Issue