Open ghost opened 4 years ago
Antlr issue: https://github.com/antlr/antlr4/issues/2016
Work around is a small patch to the grammar:
binaryLtlExpr: ltlExpr | op1=binaryLtlExpr type=binaryLtlOp op2=binaryLtlExpr;
from the original one:
binaryLtlExpr: ltlExpr | ops+=binaryLtlExpr type=binaryLtlOp ops+=binaryLtlExpr;
The visitor must be patched too: ctx.ops.get(0) will become ctx.op1 in ToStringVisitor.java. Same goes for ctx.ops.get(1).
ctx.ops.get(0)
ctx.op1
ctx.ops.get(1)
Antlr issue: https://github.com/antlr/antlr4/issues/2016
Work around is a small patch to the grammar:
from the original one:
The visitor must be patched too:
ctx.ops.get(0)
will becomectx.op1
in ToStringVisitor.java. Same goes forctx.ops.get(1)
.