-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Add quick fix to add .nn #23598
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
Add quick fix to add .nn #23598
Conversation
cc @noti0na1 |
…es for in-line match and if, improve formatting, and add more test Signed-off-by: Seyon Sivatharan <[email protected]>
All the issues should be resolved now. |
I was on vocation in last few weeks. I will review it soon. |
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
Tried backposting the PR, but got:
Most likely due to some other changes that were not backported. With experimental stuff like this we should be fine. |
That's quite weird. We had that issue before pushing 6c2147d, but it shouldn't be an issue anymore because we only |
ach, that might be it. I didn't realize it was a temporary issue. Ideally we would squash in those situations. I will try and backport it again next week. |
Backports #23598 to the 3.7.4. PR submitted by the release tooling. [skip ci]
An extension to #23461 that adds a quick fix to add a .nn. For example, if the code were
the quick fix would transform the code to
The code is WIP (I've put some ugly workarounds to get it to work). Right now, it adds brackets whenever the root node is an Apply. This is needed for infix functions (both those with ApplyKind InfixTuple and those that are written as such in the source code, such as + which is desugared to an ApplyKind Regular I think), but there may be other edge cases where brackets are needed. I've discussed these edges cases a bit with @olhotak and @HarrisL2, but it's possible that we've missed some (or I've forgotten to add them).