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

Lookahead and lookback #54

Open
Veykril opened this issue Feb 8, 2022 · 1 comment
Open

Lookahead and lookback #54

Veykril opened this issue Feb 8, 2022 · 1 comment
Labels
enhancement New feature or request

Comments

@Veykril
Copy link
Owner

Veykril commented Feb 8, 2022

I haven't looked into this too much yet, but if I am not mistaken the quote crate uses a neat trick to allow lookahead and lookback-ish matching on tokens, see:
https://github.com/dtolnay/quote/blob/278057d0d2e59c7de95d79d42e4934783d013e83/src/lib.rs#L672-L702

it might be nice to add this to the pattern section(or do a case study on the macro even?)

@Veykril Veykril added the enhancement New feature or request label Feb 8, 2022
@Veykril
Copy link
Owner Author

Veykril commented Apr 8, 2022

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant