Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Indeterminate forms #110

Open
waldemarhorwat opened this issue Apr 4, 2024 · 3 comments
Open

Indeterminate forms #110

waldemarhorwat opened this issue Apr 4, 2024 · 3 comments

Comments

@waldemarhorwat
Copy link

Editorial bugs: In a number of places the proposal mentions converting Decimal ±∞ to Mathematical Values. That's forbidden by the current ECMAScript spec. Those can be converted to Extended Mathematical Values, but then the proposal mentions performing operations that can produce indeterminate forms such as equality, which are also not allowed.

@jessealama
Copy link
Collaborator

Right, Extended Mathematical Values is what was intended. Good spot.

Do I understand the point about indeterminate forms correctly that comparing a NaN value with any value might produce undefined instead of a boolean value? In an earlier version of the spec, we had a cmp operation, à la IEEE 754's compare operation (which might produce an indeterminate value, which I had modeled by returning undefined), but in the current spec, cmp has been replaced with lessThan and equals. The current spec text may contain traces of that compare.

@waldemarhorwat
Copy link
Author

One can ask whether a real number is less than the Extended Mathematical Value +∞, but the question of whether an Extended Mathematical Value +∞ is equal, less than, or greater than an Extended Mathematical Value +∞ is an indeterminate form and has no well-defined answer. There are mathematical systems, for example ordinal numbers, that allow one to rank and compare mathematical infinities, but the ECMAScript spec does not use them. The spec does not say which kind of mathematical infinity +∞ is, and anything that relies on an answer to that question is considered a spec error.

@jessealama
Copy link
Collaborator

related to #116

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants