Currently it appears that too big (overflow) and too small (underflow) values can produce "Not a Number" (NaN) values from JsonParser, in addition to optionally supported tokens -- only allowed if enabled -- like +INF / -INF / NaN).
But doing this causes problem with BigDecimal handling since such "too big"/"too small" values CAN be represented as BigDecimal, whereas "true" Not-a-Numbers cannot.
So we should improve handling of JsonParser.isNaN() method so that it ONLY indicates explicit Not-a-Number cases, and not overflows.
Currently it appears that too big (overflow) and too small (underflow) values can produce "Not a Number" (NaN) values from
JsonParser, in addition to optionally supported tokens -- only allowed if enabled -- like+INF/-INF/NaN).But doing this causes problem with
BigDecimalhandling since such "too big"/"too small" values CAN be represented asBigDecimal, whereas "true" Not-a-Numbers cannot.So we should improve handling of
JsonParser.isNaN()method so that it ONLY indicates explicit Not-a-Number cases, and not overflows.