forked from jasder/antlr
Don't create action functions for lexer rules with no specified actions
This commit is contained in:
parent
90f4452dc4
commit
fa5332926b
|
@ -305,6 +305,10 @@ public class OutputModelController {
|
||||||
}
|
}
|
||||||
|
|
||||||
public void buildLexerRuleActions(Lexer lexer, final Rule r) {
|
public void buildLexerRuleActions(Lexer lexer, final Rule r) {
|
||||||
|
if (r.actions.isEmpty()) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
CodeGenerator gen = delegate.getGenerator();
|
CodeGenerator gen = delegate.getGenerator();
|
||||||
Grammar g = delegate.getGrammar();
|
Grammar g = delegate.getGrammar();
|
||||||
String ctxType = gen.target.getRuleFunctionContextStructName(r);
|
String ctxType = gen.target.getRuleFunctionContextStructName(r);
|
||||||
|
|
Loading…
Reference in New Issue