[LLVMbugs] [Bug 10722] clang doesn't report missing @required properties declared in adopted system protocols
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Sat Aug 27 15:00:22 PDT 2011
http://llvm.org/bugs/show_bug.cgi?id=10722
Fariborz Jahanian <fjahanian at apple.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|REOPENED |RESOLVED
Resolution| |FIXED
--- Comment #6 from Fariborz Jahanian <fjahanian at apple.com> 2011-08-27 17:00:22 CDT ---
All right. It is done in trunk as r 138714
> (In reply to comment #4)
> > (In reply to comment #3)
> > > I'm marking this reopened since this rationalization doesn't make sense to me.
> > >
> > > -Wsystem-headers should control warnings that would be emitted when compiling
> > > system headers themselves, not whether user code that adopts them should warn.
> > >
> > > By this argument, no warning would be generated by a class adopting a protocol
> > > with required methods and failing to implement those methods. A @required
> > > property in a protocol is just shorthand for -foo and -setFoo: (with
> > > appropriate atomicity and reference counting semantics), and it should emit
> > > warnings when the property is missing just like a missing method would.
> >
> > I agree with this assessment. Classes in user code should not have their
> > warnings suppressed because the parent class is in a system header.
>
> I agree too. It is trivial to fix by pointing the warning to the class's
> implementation instead of the protocol.
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the llvm-bugs
mailing list