encoding/json: decoder won't unmarshal scientific notation into integer #6657
What steps will reproduce the problem? If possible, include a link to a program on play.golang.org. JSON decoding from scientific notation into an integer is not allowed by the JSON decoder. Here is an example: http://play.golang.org/p/yS3YNvt8BB What is the expected output? When decoding the JSON value 1e+06 into an int64, I'd expect decoding to succeed. What do you see instead? JSON Unmarshal() returns an error: "json: cannot unmarshal number 1e+06 into Go value of type int64" Which compiler are you using (5g, 6g, 8g, gccgo)? 6g (I think), this is amd64, not gccgo, using vanilla binaries from the tarball from golang.org. Which operating system are you using? Ubuntu 13.04 Which version are you using? (run 'go version') 1.1.2 Please provide any additional information below.
The text was updated successfully, but these errors were encountered:
This issue was closed.