On Mon, Jul 6, 2009 at 8:14 PM, Eric Hermanson<zmons...@mac.com> wrote: > First of all, this has absolutely nothing to do with NSNumberFormatter. > > Second of all, the NSDecimalNumber is losing information it had when I > constructed it, which I do not want it to lose. Instead of storing an > exponent of -2 and a mantissa of 2200, it instead chooses to normalize the > values to 0 and 22, respectively. While this does provide equal numbers as > far as isEqual is concerned, I am forced to store my own context separately > if I want the number to remember the scale it had when I constructed it. > This is unfortunate.
Does the documentation guarantee that scale is preserved, or only value? If it does not guarantee that scale is preserved, then you shouldn't expect it to be. Classes are built for a purpose, and using them outside that purpose can mean they behave as designed instead of the way you want them to. Mike _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com