Documentation

Regex.NFA.Compile.Basic

def Regex.NFA.pushNode (nfa : NFA) (node : Node) :
Equations
Instances For
    @[simp]
    theorem Regex.NFA.pushNode_size {nfa : NFA} {node : Node} :
    (nfa.pushNode node).size = nfa.size + 1
    theorem Regex.NFA.pushNode_get_lt {nfa : NFA} {node : Node} (i : Nat) (h : i < nfa.size) :
    (nfa.pushNode node)[i] = nfa[i]
    @[simp]
    theorem Regex.NFA.pushNode_get_eq {nfa : NFA} {node : Node} :
    (nfa.pushNode node)[nfa.size] = node
    theorem Regex.NFA.pushNode_get {nfa : NFA} {node : Node} (i : Nat) (h : i < (nfa.pushNode node).size) :
    (nfa.pushNode node)[i] = if h' : i < nfa.size then nfa[i] else node
    @[simp]
    theorem Regex.NFA.pushNode_start {nfa : NFA} {node : Node} :
    (nfa.pushNode node).start = nfa.size
    theorem Regex.NFA.pushNode_wf {nfa : NFA} {node : Node} (wf : nfa.WellFormed) (inBounds : node.inBounds (nfa.size + 1)) :
    (nfa.pushNode node).WellFormed
    def Regex.NFA.pushRegex (nfa : NFA) (next : Nat) :

    Compile a Regex and append the resulting nodes to the NFA. The nodes will transition to next on match.

    Equations
    Instances For