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

Add string interpolation [incomplete] #2

Merged
merged 2 commits into from
Jun 23, 2022
Merged

Add string interpolation [incomplete] #2

merged 2 commits into from
Jun 23, 2022

Conversation

Bellisario
Copy link
Contributor

Closes #1.

This is not actually working due problems passing the AST to the parser.

@Bellisario
Copy link
Contributor Author

@coderaiser, I'm unable to pass baked AST to the parser, the rest of the code is working correctly with only a limitation:

  • there isn't a way to "prevent" sting interpolation parsing yet (ex. by adding "\" before string interpolation itself)

@coderaiser
Copy link
Owner

coderaiser commented Jun 23, 2022

This is very good!

The thing that is missing is creating the node with this.startNode(), and finishing the node with this.finishNode(), this is how acorn works, it needs it to append the node correctly.

@coderaiser coderaiser marked this pull request as ready for review June 23, 2022 08:43
@coderaiser coderaiser merged commit a4b61b7 into coderaiser:master Jun 23, 2022
@coderaiser
Copy link
Owner

We need more tests to make sure that other literals works good, we can proceed in next PR's :).

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

Successfully merging this pull request may close these issues.

[Feature request] String interpolation (like Swift)
2 participants