|
|
@ -205,11 +205,6 @@ func (s State) matchesFor(str []rune, idx int) ([]*State, int) {
|
|
|
|
return listTransitions, numTransitions
|
|
|
|
return listTransitions, numTransitions
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
type NFA struct {
|
|
|
|
|
|
|
|
start State
|
|
|
|
|
|
|
|
outputs []State
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// verifyLastStatesHelper performs the depth-first recursion needed for verifyLastStates
|
|
|
|
// verifyLastStatesHelper performs the depth-first recursion needed for verifyLastStates
|
|
|
|
func verifyLastStatesHelper(state *State, visited map[*State]bool) {
|
|
|
|
func verifyLastStatesHelper(state *State, visited map[*State]bool) {
|
|
|
|
if len(state.transitions) == 0 {
|
|
|
|
if len(state.transitions) == 0 {
|
|
|
|