This is an archive of the discontinued LLVM Phabricator instance.

[indexer] Add references for ObjC getter=/setter= property attributes and related property getter/setter role fixes
ClosedPublic

Authored by nathawes on Mar 13 2017, 12:30 PM.

Details

Reviewers
akyrtzi
Summary
@interface Example

@property (readwrite) id prop;
// ^^ getter/setter reported here have the Decl + Implicit roles as before

-(id)declaredGet;
@property (readwrite, getter=declaredGet) id otherProp;
// ^^ getter occurrence with the Ref role now reported here (previously missing)

@property (readwrite, getter=customGet, setter=customSet:) id unrelated;
// ^^ getter/setter occurrences reported here have the Decl role and are no longer considered Implicit

- (void)method;
@end

@implementation Example
- (void)method {
  self.prop;
  // ^^ the call to the getter reported here now has the Implicit role
  self.prop = self.otherProp;
  // ^^ the reference to property 'prop' reported here now has the Write role.
}
@end

This patch resolves:
rdar://problem/30103709
rdar://problem/30147280
rdar://problem/30103669

Diff Detail

Repository
rL LLVM

Event Timeline

nathawes created this revision.Mar 13 2017, 12:30 PM
nathawes edited the summary of this revision. (Show Details)Mar 13 2017, 12:49 PM
akyrtzi accepted this revision.Mar 16 2017, 11:38 AM

Committed in r297972.

This revision is now accepted and ready to land.Mar 16 2017, 11:38 AM
akyrtzi closed this revision.Mar 16 2017, 11:39 AM