| 1 |
// Copyright 2017 The Go Authors. All rights reserved. |
| 2 |
// Use of this source code is governed by a BSD-style |
| 3 |
// license that can be found in the LICENSE file. |
| 4 |
|
| 5 |
package strconv |
| 6 |
|
| 7 |
type Uint128 = uint128 |
| 8 |
|
| 9 |
const ( |
| 10 |
Pow10Min = pow10Min |
| 11 |
Pow10Max = pow10Max |
| 12 |
) |
| 13 |
|
| 14 |
var ( |
| 15 |
MulLog10_2 = mulLog10_2 |
| 16 |
MulLog2_10 = mulLog2_10 |
| 17 |
ParseFloatPrefix = parseFloatPrefix |
| 18 |
Pow10 = pow10 |
| 19 |
Umul128 = umul128 |
| 20 |
Umul192 = umul192 |
| 21 |
Div5Tab = div5Tab |
| 22 |
DivisiblePow5 = divisiblePow5 |
| 23 |
TrimZeros = trimZeros |
| 24 |
) |
| 25 |
|
| 26 |
func NewDecimal(i uint64) *decimal { |
| 27 |
d := new(decimal) |
| 28 |
d.Assign(i) |
| 29 |
return d |
| 30 |
} |
| 31 |
|
| 32 |
func SetOptimize(b bool) bool { |
| 33 |
old := optimize |
| 34 |
optimize = b |
| 35 |
return old |
| 36 |
} |