Language plugin: external parser integration

Hello! I'm developing a plugin for custom language. I have a parser generated by jcup and so I want integrate it to the plugin. But I have no idea how to do it, because PsiBuilder uses marks that I can't create correctly in the semantic actions of the parser. Official docs contains too little information about this process. For example, expression 1 + 2 + 3 parser can splits by marks correctly (docs contains similar example), but I have no idea how to do this for expression 1 + 2 * 3, because initially parser gives all literals and after gives the subexpressions and expression. How to create the marks in this situation? Thanks.

Please sign in to leave a comment.