diff --git a/regex/compile.go b/regex/compile.go index a28d114..82a35d9 100644 --- a/regex/compile.go +++ b/regex/compile.go @@ -989,7 +989,7 @@ func thompson(re []postfixNode) (Reg, error) { return &s }) // Reduce the list of states down to a single state by alternating them - toAdd := Reduce(states, func(s1 *State, s2 *State) *State { + toAdd := funcReduce(states, func(s1 *State, s2 *State) *State { return alternate(s1, s2) }) nfa = append(nfa, toAdd)