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

Terminal Names Documentation #1484

Open
EmperorArthur opened this issue Nov 7, 2024 · 1 comment
Open

Terminal Names Documentation #1484

EmperorArthur opened this issue Nov 7, 2024 · 1 comment

Comments

@EmperorArthur
Copy link

EmperorArthur commented Nov 7, 2024

Suggestion
Better document pre-defined terminal names.

That way we know what already exists.

Additional context
Finding pre-defined terminal names involved searching the source code for one which I knew.

Edit:
Found the names in https://github.com/lark-parser/lark/blob/24f19a35f376b9320d53f4d987793fb8b1765f37/lark/load_grammar.py

@erezsh
Copy link
Member

erezsh commented Jan 1, 2025

I'm not sure it's a good idea for users to rely on the automatic names.

If you need to refer to a terminal later, it's probably better to just define it in your grammar, in whatever name you choose.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants