You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In Elm 0.19.1, it seems that the special case of x == 0 is compiled to !x in the generated JavaScript, but this means that if x is NaN then x == 0 will return True. Given
Note that comparisons work properly when using the variable zero instead of the literal 0, and wrapped literals compare as expected in debug builds but not in optimized builds where the wrapper is optimized away.
The text was updated successfully, but these errors were encountered:
In Elm 0.19.1, it seems that the special case of
x == 0
is compiled to!x
in the generated JavaScript, but this means that ifx
is NaN thenx == 0
will returnTrue
. GivenI would expect all the checks to return
False
, but in a debug build I getand in an optimized build I get
Note that comparisons work properly when using the variable
zero
instead of the literal 0, and wrapped literals compare as expected in debug builds but not in optimized builds where the wrapper is optimized away.The text was updated successfully, but these errors were encountered: