-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Editorial: Using non-negative integral Number instead of integral Number in ToLength #3377
Conversation
2c1d4d3
to
e0849c6
Compare
Not an integer, but an integral Number. That's an important distinction: in the ES spec's terminology, an integer is a "mathematical value", but a Number is a "language value". Those are completely disjoint value spaces, though they are related via conversion operations.
If you change "integer" back to "integral Number" there, I think that narrowing would be valid. |
I'm sorry for incorrectly editing the specification. |
1c9228b
to
efc849b
Compare
efc849b
to
de897f5
Compare
cc @jhnaldo for the esmeta failure; what do you recommend here? ignoring |
@ljharb see the linked esmeta issue I created |
As I explained in es-meta/esmeta#260, the error message says that remove the line |
Thanks, the “add/remove” confused me :-) |
9277af8
to
6b68dea
Compare
6b68dea
to
cbd470f
Compare
In current ECMA262 specification, the abstract operation
ToLength
returns a integer or throw completion.However, I think that type of the return value of
ToLength
can be narrowed to a non-negative integer or throw completion.