@Override
public String formatMessage(SyntaxError error) {
RecognitionException exception = error.getException();
if (exception instanceof InputMismatchException) {
InputMismatchException mismatchException = (InputMismatchException) exception;
RuleContext ctx = mismatchException.getCtx();
int ruleIndex = ctx.getRuleIndex();
switch (ruleIndex) {
case ProtoParser.RULE_ident:
return ProtostuffBundle.message("error.expected.identifier");
default:
break;
}
}
return super.formatMessage(error);
}
ProtoParserDefinition.java 文件源码
java
阅读 25
收藏 0
点赞 0
评论 0
项目:protobuf-jetbrains-plugin
作者:
评论列表
文章目录