Closed s-hadinger closed 5 months ago
Berry anticipation of https://github.com/berry-lang/berry/pull/421
Add support for math.inf representing the normalized Infinity:
math.inf
-math.inf
math.isinf()
For json.dump, values inf, -inf and nan now convert to null which is the best match since inf and nan are not valid json values.
json.dump
inf
-inf
nan
null
Related issue (if applicable): fixes #21296
NOTE: The code change must pass CI tests. Your PR cannot be merged unless tests pass
Description:
Berry anticipation of https://github.com/berry-lang/berry/pull/421
Add support for
math.inf
representing the normalized Infinity:math.inf
is infinity (positive), can be set as negative with-math.inf
math.isinf()
to test if a value is infinityFor
json.dump
, valuesinf
,-inf
andnan
now convert tonull
which is the best match sinceinf
andnan
are not valid json values.Related issue (if applicable): fixes #21296
Checklist:
NOTE: The code change must pass CI tests. Your PR cannot be merged unless tests pass