Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Issue #148: Check for overflow when reading floating point exponent.
GCC with -O2 optimizes away the if(exp<-maxExponent) branch completely, so we don't end up with the expected '512' value for overflowing exponents. Limit the exponent parsing to MAX_INT instead to prevent signed overflow from tripping up over-eager optimizing compilers.
- Loading branch information
Wouldn't this still overflow for any digit other than
0
?