-
-
Notifications
You must be signed in to change notification settings - Fork 116
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
feat(compiler): Arbitrary-position spreads #1665
base: main
Are you sure you want to change the base?
Conversation
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.
Overall, the approach looks good here. Just a few things to clean up :)
// We have to compose this list by hand because of the complexity of if a list item | ||
// is followed by a comment, the comma must come before the comment. | ||
// It also impacts how we force a new line for a line ending comment at the end of a list | ||
// without introducing an extra blank line when bringing the indentation back in again |
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.
On my list of things to do is create a new parsetree node for lists, now that it's a part of the compiler. Seems like I should hurry up and do that so we can rebase this on top to prevent this from getting even more complex?
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.
Sure, if you'd like; I don't think it should be too much work to rebase this off of such a feature
I addressed the majority of the feedback, will wait until list ADT nodes gets merged to un-bork the formatter :P |
What should the fate of this PR be? Should it be tabled until further notice or is it still planned for 0.6? There was some discussion in a community meeting a little while ago to completely change list syntax (using arrows to connect elements or something of the sort), but that would cause the current syntax to be breaking regardless |
8af0f18
to
732027f
Compare
Support for putting the spread syntax at any position in a list (also spread support for arrays).
Example:
Closes #288