Documentation

RegexCorrectness.VM.Path.CharStep

def Regex.NFA.CharStep (nfa : NFA) (it : String.Iterator) (i j : Fin nfa.nodes.size) :
Equations
Instances For
    @[simp]
    theorem Regex.NFA.CharStep.done {nfa : NFA} {it : String.Iterator} {i j : Fin nfa.nodes.size} (hn : nfa[i] = Node.done) :
    nfa.CharStep it i j False
    @[simp]
    theorem Regex.NFA.CharStep.fail {nfa : NFA} {it : String.Iterator} {i j : Fin nfa.nodes.size} (hn : nfa[i] = Node.fail) :
    nfa.CharStep it i j False
    @[simp]
    theorem Regex.NFA.CharStep.epsilon {nfa : NFA} {it : String.Iterator} {i j : Fin nfa.nodes.size} {next : } (hn : nfa[i] = Node.epsilon next) :
    nfa.CharStep it i j False
    @[simp]
    theorem Regex.NFA.CharStep.anchor {nfa : NFA} {it : String.Iterator} {i j : Fin nfa.nodes.size} {anchor : Data.Anchor} {next : } (hn : nfa[i] = Node.anchor anchor next) :
    nfa.CharStep it i j False
    @[simp]
    theorem Regex.NFA.CharStep.split {nfa : NFA} {it : String.Iterator} {i j : Fin nfa.nodes.size} {next₁ next₂ : } (hn : nfa[i] = Node.split next₁ next₂) :
    nfa.CharStep it i j False
    @[simp]
    theorem Regex.NFA.CharStep.save {nfa : NFA} {it : String.Iterator} {i j : Fin nfa.nodes.size} {offset next : } (hn : nfa[i] = Node.save offset next) :
    nfa.CharStep it i j False
    @[simp]
    theorem Regex.NFA.CharStep.char {nfa : NFA} {it : String.Iterator} {i j : Fin nfa.nodes.size} {c : Char} {next : } (hn : nfa[i] = Node.char c next) :
    nfa.CharStep it i j ∃ (l : List Char) (r : List Char), j = next String.Iterator.ValidFor l (c :: r) it
    @[simp]
    theorem Regex.NFA.CharStep.sparse {nfa : NFA} {it : String.Iterator} {i j : Fin nfa.nodes.size} {cs : Data.Classes} {next : } (hn : nfa[i] = Node.sparse cs next) :
    nfa.CharStep it i j ∃ (l : List Char) (c : Char) (r : List Char), j = next String.Iterator.ValidFor l (c :: r) it c cs
    theorem Regex.NFA.CharStep.char_or_sparse {nfa : NFA} {it : String.Iterator} {i j : Fin nfa.nodes.size} (step : nfa.CharStep it i j) :
    (∃ (c : Char) (next : ), nfa[i] = Node.char c next) ∃ (cs : Data.Classes) (next : ), nfa[i] = Node.sparse cs next