(strVal string)
| 44 | ) |
| 45 | |
| 46 | func makeConst(strVal string) *Decimal { |
| 47 | d := &Decimal{} |
| 48 | _, _, err := d.SetString(strVal) |
| 49 | if err != nil { |
| 50 | panic(err) |
| 51 | } |
| 52 | return d |
| 53 | } |
| 54 | |
| 55 | // constWithPrecision implements a look-up table for a constant, rounded-down to |
| 56 | // various precisions. The point is to avoid doing calculations with all the |