New creates a new decimal with the given coefficient and exponent.
(coeff int64, exponent int32)
| 78 | |
| 79 | // New creates a new decimal with the given coefficient and exponent. |
| 80 | func New(coeff int64, exponent int32) *Decimal { |
| 81 | d := new(Decimal) |
| 82 | d.SetFinite(coeff, exponent) |
| 83 | return d |
| 84 | } |
| 85 | |
| 86 | // NewWithBigInt creates a new decimal with the given coefficient and exponent. |
| 87 | func NewWithBigInt(coeff *BigInt, exponent int32) *Decimal { |