mirror of https://github.com/lua/lua.git
Browse Source
The multiplication (m*b) used to test whether 'm' is non-zero and 'm' and 'b' have different signs can underflow for very small numbers, giving a wrong result. The use of explicit comparisons solves this problem. This commit also adds several new tests for '%' (both for floats and for integers) to exercise more corner cases, such as very large and very small values.pull/21/head
Roberto Ierusalimschy
6 years ago
5 changed files with 87 additions and 18 deletions
Loading…
Reference in new issue