/**
* Get an existing target state for an edge in the DFA. If the target state
* for the edge has not yet been computed or is otherwise not available,
* this method returns {@code null}.
*
* @param previousD The current DFA state
* @param t The next input symbol
* @return The existing target DFA state for the given input symbol
* {@code t}, or {@code null} if the target state for this edge is not
* already cached
*/
@Nullable
protected DFAState getExistingTargetState(@NotNull DFAState previousD, int t) {
DFAState[] edges = previousD.edges;
if (edges == null || t + 1 < 0 || t + 1 >= edges.length) {
return null;
}
return edges[t + 1];
}
ParserATNSimulator.java 文件源码
java
阅读 29
收藏 0
点赞 0
评论 0
项目:Scratch-ApuC
作者:
评论列表
文章目录