NoQ added inline comments.
================ Comment at: lib/StaticAnalyzer/Checkers/ObjCPropertyChecker.cpp:68 + return; + + BR.EmitBasicReport( ---------------- dcoughlin wrote: > You'll also want to make sure to not warn on the following idiom, in which > programmers use @synthesize to generate the storage but still provide their > own accessors: > > ``` > @interface Foo > @property(copy) NSMutableString *foo; > @end > > @implementation Foo > @synthesize foo; > -(NSMutableString *)foo { > return foo; > } > - (void)setFoo:(NSMutableString *)newValue { > foo = [newValue mutableCopy]; > } > @end > ``` > I *think* a call to `ObjCContainerDecl::HasUserDeclaredSetterMethod()` should > be sufficient to detect and early exit in this case. > ObjCContainerDecl::HasUserDeclaredSetterMethod() Didn't notice this one, that's much easier! https://reviews.llvm.org/D27535 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits