new-transitions ( nfa dfa new-states visited-states -- nfa dfa )


Vocabulary
regexp.dfa

Inputs
nfaan object
dfaan object
new-statesan object
visited-statesan object


Outputs
nfaan object
dfaan object


Definition


:: new-transitions
( nfa dfa new-states visited-states -- nfa dfa )
new-states
[ nfa dfa ] [
pop :> state state dfa transitions>> ensure-state
state nfa find-transitions [| trans |
state trans nfa find-closure
:> new-state new-state visited-states new-states
add-todo-states
state new-state trans dfa set-transition
] each nfa dfa new-states visited-states new-transitions
] if-empty ;