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

How to add a new language? #212

Open
850tomato opened this issue Jul 10, 2022 · 1 comment
Open

How to add a new language? #212

850tomato opened this issue Jul 10, 2022 · 1 comment

Comments

@850tomato
Copy link

Great Project!
I have a question about how to add a new language. I see the step 3 "Implement a small wrapper around the generated parser.". But how I make it work after I wrote the wrapper. Should I use some command?
Looking forward your replay. Thanks.

@vovak
Copy link
Member

vovak commented Jul 11, 2022

Hi @850tomato, thanks for reaching out.

The corresponding doc entry was a bit out of date — thanks for helping us spot it. I've just updated it.

I suggest you use JavaParser as an example and trace up its usages — this way you can make sense of the control flow down to the parser.

Basically, you will have to add a new entry to ParserConfig, add the corresponding option to factory.kt, and implement a new ParsingFactory — then you will be able to configure astminer to use your new parser.

Please let me know if I can help you further.

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