rm dead code (Coverity)
This commit is contained in:
parent
d0b9e7388c
commit
a7a2050fd2
|
@ -259,7 +259,7 @@ public class LexerATNSimulator extends ATNSimulator {
|
|||
if (s.edges == null || t < MIN_DFA_EDGE || t > MAX_DFA_EDGE) {
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
DFAState target = s.edges[t - MIN_DFA_EDGE];
|
||||
if (debug && target != null) {
|
||||
System.out.println("reuse state "+s.stateNumber+
|
||||
|
@ -619,7 +619,6 @@ public class LexerATNSimulator extends ATNSimulator {
|
|||
System.out.println("EDGE "+p+" -> "+q+" upon "+((char)t));
|
||||
}
|
||||
|
||||
DFA dfa = decisionToDFA[mode];
|
||||
synchronized (p) {
|
||||
if ( p.edges==null ) {
|
||||
// make room for tokens 1..n and -1 masquerading as index 0
|
||||
|
|
|
@ -707,20 +707,6 @@ public abstract class PredictionContext {
|
|||
// return toString(recog, ParserRuleContext.EMPTY);
|
||||
}
|
||||
|
||||
// recog null unless ParserRuleContext, in which case we use subclass toString(...)
|
||||
public String toString(@Nullable Recognizer<?,?> recog, RuleContext stop) {
|
||||
StringBuilder buf = new StringBuilder();
|
||||
PredictionContext p = this;
|
||||
buf.append("[");
|
||||
// while ( p != null && p != stop ) {
|
||||
// if ( !p.isEmpty() ) buf.append(p.returnState);
|
||||
// if ( p.parent != null && !p.parent.isEmpty() ) buf.append(" ");
|
||||
// p = p.parent;
|
||||
// }
|
||||
buf.append("]");
|
||||
return buf.toString();
|
||||
}
|
||||
|
||||
public String[] toStrings(Recognizer<?, ?> recognizer, int currentState) {
|
||||
return toStrings(recognizer, EMPTY, currentState);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue