v4: check for null

[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9487]
This commit is contained in:
sharwell 2011-11-29 19:01:35 -08:00
parent a71a9f04ea
commit 99cf07cc3c
1 changed files with 5 additions and 3 deletions

View File

@ -129,10 +129,12 @@ public class LL1Analyzer {
else {
// System.out.println("adding "+ t);
IntervalSet set = t.label();
if (t instanceof NotSetTransition) {
set = set.complement(IntervalSet.of(Token.MIN_USER_TOKEN_TYPE, atn.maxTokenType));
if (set != null) {
if (t instanceof NotSetTransition) {
set = set.complement(IntervalSet.of(Token.MIN_USER_TOKEN_TYPE, atn.maxTokenType));
}
look.addAll(set);
}
look.addAll(set);
}
}
}