aperkins
aperkins

Reputation: 13124

Is there a fixed-point decimal object in Objective-C?

In other languages, there is often a fixed decimal object that can be used in place of IEEE float/doubles, to help guarantee precision. Does Objective-C have something similar? When I was looking, all I found was NSNumber, which seems to only deal with the standard primitive types. Is there another object I am missing?

Upvotes: 0

Views: 971

Answers (1)

Bala R
Bala R

Reputation: 108957

NSDecimalNumber maybe?

According to this post there is a Decimal type that does not use IEEE floating point representation.

Upvotes: 3

Related Questions