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

Keep a repository of ANTLR4 grammars converted to flex/bison #4148

Open
coderextreme opened this issue Jun 28, 2024 · 1 comment
Open

Keep a repository of ANTLR4 grammars converted to flex/bison #4148

coderextreme opened this issue Jun 28, 2024 · 1 comment

Comments

@coderextreme
Copy link

I tried converting my ANLTR4 grammar to flex/bison with ChatGPT, and it just did it. I haven’t tested it yet. It would seem to be handy to keep grammars in other meta-grammars, to save on many people doing the same thing. I’d like to see what my generated grammar does in Pyacc/Plex (pascal). Convert to those didn’t really work, last I tried.

@kaby76
Copy link
Contributor

kaby76 commented Jun 28, 2024

The main problem retaining converted grammars to other parser generators is that there will be grammars that will need to be kept in synch with each other. If we provide an automated means of converting from Antlr4 syntax to Bison, for example on a PR merge, change tracking becomes a problem because the author of the automated change is not tied to the user. If we don't provide an automated means of doing the conversion, this will lead to a version skew between the Antlr4 grammar. People only do the minimal amount of work: (a) they don't port to all the targets; (b) they only make changes for one target, and punt on changes for the other targets by narrowing the list of supported targets in the desc.xml.

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

No branches or pull requests

2 participants