Search in sources :

Example 1 with RuleClosureTransition

use of org.antlr.analysis.RuleClosureTransition in project antlrworks by antlr.

the class FAFactory method targetStateOfTransition.

public NFAState targetStateOfTransition(Transition transition) {
    NFAState target;
    if (transition instanceof RuleClosureTransition) {
        RuleClosureTransition rct = (RuleClosureTransition) transition;
        target = rct.followState;
    } else {
        target = (NFAState) transition.target;
    }
    return target;
}
Also used : RuleClosureTransition(org.antlr.analysis.RuleClosureTransition) NFAState(org.antlr.analysis.NFAState)

Aggregations

NFAState (org.antlr.analysis.NFAState)1 RuleClosureTransition (org.antlr.analysis.RuleClosureTransition)1