gnustep-dev
[Top][All Lists]
Advanced

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

Re: [RFA]: BOOL coding standards (Was: Problem with +numberWithBool: ?)


From: Richard Frith-Macdonald
Subject: Re: [RFA]: BOOL coding standards (Was: Problem with +numberWithBool: ?)
Date: Mon, 2 Feb 2004 14:17:44 +0000


On 2 Feb 2004, at 12:08, David Ayers wrote:

I'm not talking about a coding convention within GNUstep to avoid this, I'm asking whether we are entitled to require this of third party code (even if this third party code is writing categories on our classes).

Until someone (you?) found a reference in apple documentation warning that boolValue might return a non-YES/NO value from an NSNumber, I'd have said that yes, we are entitled to insist on correct usage of BOOL. However, we have to maintain MacOS-X compatibility ... so I think the most we can do is warn about instances where the YES/NO rule has not been adhered to ... unless we wanted to raise exceptions if the user defaults said we are not running in MacOS-X compatibility mode. IMO bothering with a runtime switch on the compatibility default is excessive, and we would do better to simply generate warnings.





reply via email to

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