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

[enhancement] DSLX should introduce turbofish qualifier to avoid need to backtrack #1691

Open
cdleary opened this issue Nov 3, 2024 · 0 comments
Labels
dslx DSLX (domain specific language) implementation / front-end enhancement New feature or request

Comments

@cdleary
Copy link
Collaborator

cdleary commented Nov 3, 2024

What's hard to do? (limit 100 words)

We still have backtracking in the parser on account of the fact we don't know if identifier oangle (in an expression grammatical context) is going to be a less-than symbol or a parametric instantiation. To disambiguate this and avoid the need for backtracking Rust has the turbofish qualifier which I'd like to propose we adopt to fully eliminate the backtracking (good explainer blog post with more links here: https://matematikaadit.github.io/posts/rust-turbofish.html )

Code is here:

Current best alternative workaround (limit 100 words)

Keep backtracking -- this had led to bugs historically, and I was able to eliminate almost all backtracking in the past, but this one remains.

Your view of the "best case XLS enhancement" (limit 100 words)

Introduce turbofish to make the parse unambiguous.

@cdleary cdleary added dslx DSLX (domain specific language) implementation / front-end enhancement New feature or request labels Nov 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dslx DSLX (domain specific language) implementation / front-end enhancement New feature or request
Projects
Status: No status
Development

No branches or pull requests

1 participant