forked from OSchip/llvm-project
objective-c: fixes a regression in looking up names
in class extensions and categories by recent refactoring of objc class ASTs. // rdar://1066654 llvm-svn: 147982
This commit is contained in:
parent
f88480363e
commit
4f8cb1e83a
|
@ -1255,8 +1255,11 @@ ObjCInterfaceDecl *Sema::getObjCInterfaceDecl(IdentifierInfo *&Id,
|
|||
Id = IDecl->getIdentifier();
|
||||
}
|
||||
}
|
||||
|
||||
return dyn_cast_or_null<ObjCInterfaceDecl>(IDecl);
|
||||
ObjCInterfaceDecl *Def = dyn_cast_or_null<ObjCInterfaceDecl>(IDecl);
|
||||
// This routine must always return a class definition, if any.
|
||||
if (Def && Def->getDefinition())
|
||||
Def = Def->getDefinition();
|
||||
return Def;
|
||||
}
|
||||
|
||||
/// getNonFieldDeclScope - Retrieves the innermost scope, starting
|
||||
|
|
|
@ -16,3 +16,23 @@
|
|||
@implementation MyObject
|
||||
@synthesize foo = _foo;
|
||||
@end
|
||||
|
||||
// rdar://10666594
|
||||
@interface MPMediaItem
|
||||
@end
|
||||
|
||||
@class MPMediaItem;
|
||||
|
||||
@interface MPMediaItem ()
|
||||
@property (nonatomic, readonly) id title;
|
||||
@end
|
||||
|
||||
@interface PodcastEpisodesViewController
|
||||
@end
|
||||
|
||||
@implementation PodcastEpisodesViewController
|
||||
- (id) Meth {
|
||||
MPMediaItem *episode;
|
||||
return episode.title;
|
||||
}
|
||||
@end
|
||||
|
|
Loading…
Reference in New Issue