[cfe-commits] r117271 - in /cfe/trunk: lib/Sema/SemaDeclObjC.cpp test/SemaObjC/class-conforming-protocol-2.m test/SemaObjC/method-conflict-1.m test/SemaObjC/method-typecheck-3.m

John McCall rjmccall at apple.com
Mon Oct 25 10:54:47 PDT 2010

On Oct 25, 2010, at 10:23 AM, David Chisnall wrote:
> Author: theraven
> Date: Mon Oct 25 12:23:52 2010
> New Revision: 117271
> URL: http://llvm.org/viewvc/llvm-project?rev=117271&view=rev
> Log:
> Only warn for mismatched types in Objective-C methods when they are incompatible, not when they are simply different.  Now we test whether the difference in types breaks the principle of substitutability, rather than whether they are different.

I know there isn't a spec for Objective-C or anything, but I think changes which change basic language behaviors should probably be discussed before committing them.  I know this is something that we at Apple aren't always good about, but we've tried not to change default behavior on non-Darwin platforms.  Maybe we should form a language committee. :)

That said, I really like this change, and I don't see any serious problems as long as the idea is only applied to Objective-C pointers and Objective-C methods.  My only worry is how it affects (1) sends to id and (2) possible future directions.

Anyway, we'll talk it over with the Apple runtime people;  I think we can make a pretty compelling case.


More information about the cfe-commits mailing list