Packages

package parser

Type Members

  1. class ANTLRParseTreeToPSIConverter extends ParseTreeListener

    This is how we build an intellij PSI tree from an ANTLR parse tree.

    This is how we build an intellij PSI tree from an ANTLR parse tree. We let the ANTLR parser build its kind of ParseTree and then we convert to a PSI tree in one go using a standard ANTLR ParseTreeListener.

    The list of SyntaxError objects are pulled from the parser and used for error message highlighting (error nodes don't have the info).

  2. abstract class ANTLRParserAdaptor extends PsiParser

    An adaptor that makes an ANTLR parser look like a PsiParser.

  3. class ErrorStrategyAdaptor extends DefaultErrorStrategy

    Adapt ANTLR's DefaultErrorStrategy so that we add error nodes for EOF if reached at start of resync's consumeUntil().

    Adapt ANTLR's DefaultErrorStrategy so that we add error nodes for EOF if reached at start of resync's consumeUntil(). Also set start/stop of missing token to always be the current token, even if that's EOF.

  4. class SyntaxError extends AnyRef

    A syntax error from parsing language of plugin.

    A syntax error from parsing language of plugin. These are created by SyntaxErrorListener.

  5. class SyntaxErrorListener extends BaseErrorListener

    Traps errors from parsing language of plugin.

    Traps errors from parsing language of plugin. E.g., for a Java plugin, this would catch errors when people type invalid Java code into .java file. This swallows the errors as the PSI tree has error nodes.

Ungrouped