Document JavaScript engine-specific handling of NaN values#989
Open
tryone144 wants to merge 1 commit intokonsoletyper:masterfrom
Open
Document JavaScript engine-specific handling of NaN values#989tryone144 wants to merge 1 commit intokonsoletyper:masterfrom
tryone144 wants to merge 1 commit intokonsoletyper:masterfrom
Conversation
Most JavaScript engines perform NaN-canonicalization. This results in information loss when converting a long to a double and back, iff the bits encode a non-canonical NaN value. V8 in chrome seems to be an exception that keeps the bits intact. See: konsoletyper#895 Related: 8277671
8afca65 to
dcb4b78
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
As mentioned in #895, I've finally gotten around to add comments to the tests and user-facing functions in the classlib that document potential issues with the JS backend. Since there isn't much we can do about that (other than using a non-JS backend or V8) having it documented should be enough.
The behaviour of Chrome is most likely the reason this inconsistency hasn't been noticed earlier.
This is a follow up to the changes introduced in #749, that surfaced the interface to observe this inconsistency.