Re: [SOLVED...but] Re: Storing NaN in NSMutableArray ?
Re: [SOLVED...but] Re: Storing NaN in NSMutableArray ?
- Subject: Re: [SOLVED...but] Re: Storing NaN in NSMutableArray ?
- From: Clark Cox <email@hidden>
- Date: Wed, 10 Mar 2004 17:37:23 -0500
On 2004/03/10, at 17:21, Marco Scheurer wrote:
>
>
On Mar 10, 2004, at 11:08 PM, Clark Cox wrote:
>
>>
>
>> x = nan
>
>> x != x
>
>
>
> That's true for the C concept of NaN, but not for the NSDecimalNumber
>
> concept of NaN. I filed a bug on this over a year ago (Feb 19, 2003),
>
> and it's currently in "Open/Analyze".
>
>
>
> rdar://3176846
>
>
I wouldn't consider that [[NSDecimalNumber notANumber]
>
isEqual:[NSDecimalNumber notANumber]] returns YES is a bug because in
>
C NaN != NaN ... There's no reason that the C hack should break the
>
semantic of isEqual: in objects.
I agree (I guess I wasn't clear)
>
However if the bug report is that [[NSDecimalNumber notANumber]
>
doubleValue] does not return NaN, then OK.
Yes, that's what's actually in the bug report: That [[NSDecimalNumber
notANumber] doubleValue] doesn't return NaN, and that [NSDecimalNumber
numberWithDouble: NaN] doesn't return [NSDecimalNumber notANumber].
--
Clark S. Cox III
email@hidden
http://homepage.mac.com/clarkcox3/
http://homepage.mac.com/clarkcox3/blog/B1196589870/index.html
[demime 0.98b removed an attachment of type application/pkcs7-signature which had a name of smime.p7s]
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.