Original OCaml project: https://github.com/yallop/ocaml-re-nfa.
ReasonML port + WebUI: https://github.com/joelonsql/reason-re-nfa.

Convert Regexp to NFA to DFA to minimal DFA

input .repeat()
regexp
[+] Intermediate steps
[+] Parse tree

[+] Glushkov's construction algorithm (Regex to NFA)
r' annotated(r)
Λ(r') {ε} ∩ L(r')
P(r') {c | ∃s.cs ∈ L(r') }
D(r') {c | ∃s.sc ∈ L(r') }
F(r') {c₁c₂ | ∃s₁s₂.s₁c₁c₂s₂ ∈ L(r')}
Nondeterministic finite automaton (NFA):

[+] Rabin–Scott powerset construction (NFA to DFA)

[+]Brzozowski's algorithm (DFA minimization):
[+]nfa2 = dfa_to_nfa(dfa)

[+]nfa3 = reverse(nfa2)

[+]dfa2 = determinize(nfa3)

[+]nfa4 = dfa_to_nfa(dfa2)

[+]nfa5 = reverse(nfa4)

[+]dfa3 = determinize(nfa5)

[+]RangeSet minimization:
[+]dfa4 = merge_ranges(dfa3)

[+]dfa5 = merge_linear(dfa4)

[+]dfa6 = merge_branches(dfa5)

nfa6 = dfa_to_nfa(dfa6)

LLVMIR JavaScript WebAssembly