How do I use the AST generated by SSLR?

Hi everyone,

I started developing a plugin for a new language, I have a half-complete grammar and I generated a basic AST that I can see through the SSLR Toolkit.

Now I’m wondering how I can use that AST to detect coding rules violations.

My questions are :

  • How do I link SSLR and my plugin, i.e. how does my plugin use SSLR to be able to generate an AST on a file from my language ?
  • Where do I write the Java custom rules for the different parts of that AST ?

Sorry if this doesn’t seem clear enough.

1 Like