gnustep-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Release check


From: David Ayers
Subject: Re: Release check
Date: Thu, 02 Jun 2005 17:52:09 +0200
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.8) Gecko/20050511

Adrian Robert wrote:

> 
> On Jun 2, 2005, at 3:29 AM, David Ayers wrote:
> 
>>
[snip]
>>
>> - (int)compare:anotherObject;
>> - shallowCopy;
>> - (const char *)name;
>>
[snip]
> 
> 
> Under what circumstances would it be necessary to include Protocol.h? 
> Does this affect just the libraries or also user code?

Please excuse me, I missed the second question.  It currently affects
"user code" that does something like:

@interface FooBar : NSObject
- (NSString *)name;
@end

void
someCode(void)
{
   [[[someArray objectAtIndex:0] name] length];
}
as this will warn that const char * is an invalid receiver for messages
(like length in this case).  Since both are pointers, everything is fine
at runtime.

But of course we use these methods in libraries also.

Yet changing this could also affect user code that currently may be
using Protocol.h/Object.h declarations without explicitly including the
headers.  So this change may cause "source compatibility" issues.  But
these issues are latent bugs in user code IMHO.

Cheers,
David





reply via email to

[Prev in Thread] Current Thread [Next in Thread]