Building PSI tree without Grammarkit

已回答

Is there documentation somewhere on how to build a PSI tree *without* using GrammarKit? I am trying to build a plugin for a language based on the tokenizing/AST information I get from an external tool. That is, I would like to build the PSI tree with information I already have instead of having Grammar-Kit generate a parser.

0

You can totally implement Lexer and Parser without GrammarKit, but there is no general documentation on how to implement this “manually”.

There are some hand-written parsers in IntelliJ Community sources, e.g. in Java plugin see com.intellij.lang.java.parser package.

0

请先登录再写评论。