Skip to content

Commit

Permalink
Ensure x%Infinity===x (fix #2542)
Browse files Browse the repository at this point in the history
  • Loading branch information
gfwilliams committed Sep 23, 2024
1 parent 7212abf commit 7a340e8
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
Ensure that 1%0.0===NaN (fix #2556)
Ensure Number("1A")==NaN, previously we just parsed the digits we could (fix #2555)
First argument of operators is now dereferenced before parsing second argument (fix #2547)
Ensure x%Infinity===x (fix #2542)

2v24 : Bangle.js2: Add 'Bangle.touchRd()', 'Bangle.touchWr()'
Bangle.js2: After Bangle.showTestScreen, put Bangle.js into a hard off state (not soft off)
Expand Down
1 change: 1 addition & 0 deletions src/jswrap_math.c
Original file line number Diff line number Diff line change
Expand Up @@ -267,6 +267,7 @@ double jswrap_math_mod(double x, double y) {

if (!isfinite(x) || isnan(y) || y==0)
return NAN;
if (y==INFINITY) return x;

if (0 > c) {
x = -x;
Expand Down

0 comments on commit 7a340e8

Please sign in to comment.