From 0458fa607c4dd8d0c879b2e3a0b4f95f72bbdb5b Mon Sep 17 00:00:00 2001 From: horpto <__singleton__@hackerdom.ru> Date: Sat, 22 Jul 2023 05:45:23 +0300 Subject: [PATCH] fix wrong exponent --- numeric.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/numeric.go b/numeric.go index f67a9b2..0b7ded7 100644 --- a/numeric.go +++ b/numeric.go @@ -497,7 +497,7 @@ func parseNumericString(str string) (n *big.Int, exp int32, err error) { if idx == -1 { for len(str) > 1 && str[len(str)-1] == '0' && str[len(str)-2] != '-' { str = str[:len(str)-1] - exp = 1 + exp++ } } else { exp = int32(-(len(str) - idx - 1))