]> Cypherpunks repositories - gostls13.git/commit
math/big: support new octal prefixes 0o and 0O
authorRobert Griesemer <gri@golang.org>
Thu, 7 Mar 2019 01:14:27 +0000 (17:14 -0800)
committerRobert Griesemer <gri@golang.org>
Thu, 7 Mar 2019 21:13:57 +0000 (21:13 +0000)
commit129c6e449694f14fd27dfed03f7a0c95847ec366
tree3d66b21aef9a3abb32b248f8ca223b268bf16bcc
parent2dd066d4a7ab6eb7828cbba8cb29158dcaedcc78
math/big: support new octal prefixes 0o and 0O

This CL extends the various SetString and Parse methods for
Ints, Rats, and Floats to accept the new octal prefixes.

The main change is in natconv.go, all other changes are
documentation and test updates.

Finally, this CL also fixes TestRatSetString which silently
dropped certain failures.

Updates #12711.

Change-Id: I5ee5879e25013ba1e6eda93ff280915f25ab5d55
Reviewed-on: https://go-review.googlesource.com/c/go/+/165898
Reviewed-by: Emmanuel Odeke <emm.odeke@gmail.com>
src/math/big/floatconv.go
src/math/big/floatconv_test.go
src/math/big/intconv.go
src/math/big/intconv_test.go
src/math/big/natconv.go
src/math/big/natconv_test.go
src/math/big/ratconv_test.go