diff options
author | Emanuele Torre <torreemanuele6@gmail.com> | 2023-12-13 20:14:31 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-12-13 20:14:31 +0100 |
commit | c5fd64ba975ee35df17bb0c335efb00bffce4d91 (patch) | |
tree | afb0dda1f014d876319007e5d1e8603e0c77464f /tests | |
parent | dcf9a8e580e3607e70737fad8bc0987d30be871b (diff) |
jv_parse: let decNumberFromString/strtod parse complex nans as a NaN
Before this patch (when using decNumber), "Nan123" was parsed as a NaN,
only if the first n was uppercase.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/jq.test | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/jq.test b/tests/jq.test index 4c8416dc..7036df2c 100644 --- a/tests/jq.test +++ b/tests/jq.test @@ -1938,6 +1938,11 @@ tojson | fromjson {"a":nan} {"a":null} +# also "nan with payload" #2985 +fromjson | isnan +"nan1234" +true + # calling input/0, or debug/0 in a test doesn't crash jq |