-
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
Normative: Add Logical Assignment Operators #2030
Conversation
That is indeed the reason! That's the linter doing its job. I'm glad the error message was clear enough for you to figure it out. (We're all going to be beta-testing it for a bit.) Apologies for not catching this during the review.
In this instance I think it will be clearest to just do away with |
With the existing production, you could do something like:
(I started it before @bakkot's comment and didn't want to just throw it away.) |
If you do keep ShortCircuitAssignmentOperator, you'll need to reference it from Annex A. And in any event, HasCallInTailPosition will need to be defined for the new right-hand-side(s). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated.
It's removed now, so I think this is done.
Whoops, not sure how I missed that. Updated. |
This is going for Stage 4 at the July meeting, and still requires Spec Editor approvals. |
f0e23c2
to
4879950
Compare
We plan to review it during next week's editor call, if not before. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm with step linking added back
4886f4c
to
740ecd6
Compare
https://github.com/tc39/proposal-logical-assignment
This includes a few new changes:
NamedEvaluation
is used, given today's tentative consensusLogicalAssignmentOperator
has been removed, and instead each@@=
operator is defined individuallyOutdated discussion
I need help getting it to compile correctly, though. When I run
build
, I get:This is likely from defining the grammar as
LeftHandSideExpression ShortCircuitAssignmentOperator AssignmentExpression
, but defining individual algorithms asAssignmentExpression : LeftHandSideExpression `||=` AssignmentExpression
. We could define each grammar individually, or do a bit of metaprogramming for the algorithms, likeAssignmentOperator
did. I just don't know how to metaprogram in spec-ese.