The GitHub Actions job "Java CI" on commons-math.git/dfp-string-exponent-trap 
has failed.
Run started by GitHub user insaf021 (triggered by aherbert).

Head commit for run:
5567ce95e05ae2a29815cb874d6182aaf60d3cb3 / Mahammad Insaf <[email protected]>
trap out-of-range exponents in the Dfp string constructor

Dfp(DfpField, String) discarded the flag returned by round(), so an
exponent above MAX_EXP or below the gradual underflow range produced a
finite value that every arithmetic operation would have trapped to
infinity or zero. The exponent digits were also accumulated in an int
without a bound, so "1e2147483648" wrapped negative and toString() on
the result looped forever in dfp2sci.

Stop accumulating exponent digits once they are past any representable
magnitude, store a zero mantissa with a zero exponent, and route the
round() flag through dotrap as the arithmetic operations do.

The "Next After #14" literal 9.99e131078 in DfpTest and DfpDecTest is
beyond the largest finite value and only parsed as finite because of
this bug; it is corrected to e131071.

Report URL: https://github.com/apache/commons-math/actions/runs/40535776483

With regards,
GitHub Actions via GitBox

Reply via email to