Leah Neukirchen on Nostr: How do popular languages encode special IEEE 754 float values in JSON? Ruby, Python, ...
How do popular languages encode special IEEE 754 float values in JSON?
Ruby, Python, Perl JSON::XS: generate invalid JSON
Clojure cheshire.core: emit a string "NaN" or "Infinity"
Node.js, Deno: emit null
jq: emit NaN as null, Infinity/-Infinity as biggest/smallest float
😩
Ruby, Python, Perl JSON::XS: generate invalid JSON
Clojure cheshire.core: emit a string "NaN" or "Infinity"
Node.js, Deno: emit null
jq: emit NaN as null, Infinity/-Infinity as biggest/smallest float
😩