Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

json.% raises Defect for uint64 #17383

Closed
arnetheduck opened this issue Mar 15, 2021 · 1 comment · Fixed by #17389
Closed

json.% raises Defect for uint64 #17383

arnetheduck opened this issue Mar 15, 2021 · 1 comment · Fixed by #17389

Comments

@arnetheduck
Copy link
Contributor

result = JsonNode(kind: JInt, num: BiggestInt(n))

converting a uint64 to a JsonNode raises a Defect on values outside the BiggestInt range, defeating the purpose of using this overload to begin with - to resolve, one would either deprecate / remove the overload or output a string instead - the latter would require parsing strings as well in the opposite direction.

@timotheecour
Copy link
Member

see #17389

timotheecour added a commit to timotheecour/Nim that referenced this issue Mar 16, 2021
Araq pushed a commit that referenced this issue Mar 16, 2021
…nt|uint64 (#17389) [backport:1.2]

* fix #17383: json.%,to and jsonutils.formJson,toJson now works with uint|uint64
* fixup
* fix for js
narimiran pushed a commit that referenced this issue Mar 18, 2021
…nt|uint64 (#17389) [backport:1.2]

* fix #17383: json.%,to and jsonutils.formJson,toJson now works with uint|uint64
* fixup
* fix for js

(cherry picked from commit 895a40d)
narimiran pushed a commit that referenced this issue Mar 18, 2021
…nt|uint64 (#17389) [backport:1.2]

* fix #17383: json.%,to and jsonutils.formJson,toJson now works with uint|uint64
* fixup
* fix for js

(cherry picked from commit 895a40d)
narimiran pushed a commit that referenced this issue Mar 19, 2021
…nt|uint64 (#17389) [backport:1.2]

* fix #17383: json.%,to and jsonutils.formJson,toJson now works with uint|uint64
* fixup
* fix for js

(cherry picked from commit 895a40d)
ringabout pushed a commit to ringabout/Nim that referenced this issue Mar 22, 2021
… with uint|uint64 (nim-lang#17389) [backport:1.2]

* fix nim-lang#17383: json.%,to and jsonutils.formJson,toJson now works with uint|uint64
* fixup
* fix for js
ardek66 pushed a commit to ardek66/Nim that referenced this issue Mar 26, 2021
… with uint|uint64 (nim-lang#17389) [backport:1.2]

* fix nim-lang#17383: json.%,to and jsonutils.formJson,toJson now works with uint|uint64
* fixup
* fix for js
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants