@[simp]
theorem Compiler.Lemmas.isAppend_trans {s1 s2 s3 : Array NFA.Unchecked.State} (h1 : isAppend s1 s2) (h2 : isAppend s2 s3) :
isAppend s1 s3
Instances For
def Compiler.Lemmas.stateIdNextOfLt (prevs : Array NFA.Unchecked.State) (sid : NFA.Unchecked.StateID) (s : Array NFA.Unchecked.State) :
Instances For
def Compiler.Lemmas.stateIdNextOfLeLt (prevs : Array NFA.Unchecked.State) (sid : NFA.Unchecked.StateID) (s : Array NFA.Unchecked.State) :
Instances For
def Compiler.Lemmas.stateIdNextOfEqLt (prevs : Array NFA.Unchecked.State) (sid : NFA.Unchecked.StateID) (s : Array NFA.Unchecked.State) :
Instances For
def Compiler.Lemmas.tRefNextOfLt (prevs : Array NFA.Unchecked.State) (t : ThompsonRef) (s : Array NFA.Unchecked.State) :
Instances For
def Compiler.Lemmas.tRefNextOfLeLt (prevs : Array NFA.Unchecked.State) (t : ThompsonRef) (s : Array NFA.Unchecked.State) :
Instances For
Instances For
Instances For
theorem Compiler.Lemmas.cap_exists_of_cap_role_end_of_cValid (caps : Array NFA.Capture) (h : cValid caps) (a : NFA.Capture) (h1 : a ∈ caps) (h2 : a.role = NFA.Capture.Role.End) :
theorem Compiler.Lemmas.cValid_of_empty (captures : Array NFA.Capture) (h : captures.size = 0) :
cValid captures
theorem Compiler.Lemmas.cValid_of_cMemAndValid (prevs caps : Array NFA.Capture) (h : cMemAndValid prevs caps) :
cValid caps
@[simp]
theorem Compiler.Lemmas.cMemAndValid_of_cValid_of_eq (captures s : Array NFA.Capture) :
s = captures ∧ cValid captures → cMemAndValid captures s
@[simp]
theorem Compiler.Lemmas.valid_of_push_of_role_start (captures : Array NFA.Capture) (capture : NFA.Capture) (hr : capture.role = NFA.Capture.Role.Start) (hc : NFA.Capture.Valid captures) :
NFA.Capture.Valid (captures.push capture)
@[simp]
theorem Compiler.Lemmas.cMemAndValid_of_push_of_role_start (captures : Array NFA.Capture) (capture : NFA.Capture) (hr : capture.role = NFA.Capture.Role.Start) (hc : cValid captures) :
cMemAndValid captures (captures.push capture)
theorem Compiler.Lemmas.cMemAndValid_of_push_of_role_end (captures : Array NFA.Capture) (capture : NFA.Capture) (hc : cValid captures) (h : ∃ (c : NFA.Capture), c ∈ captures ∧ c.role = NFA.Capture.Role.Start ∧ c.group = capture.group) :
cMemAndValid captures (captures.push capture)
@[simp]
theorem Compiler.Lemmas.cMemAndValidFunc_of_cValidFunc (captures s : Array NFA.Capture) :
cValidFunc captures s → cMemAndValidFunc captures s
theorem Compiler.Lemmas.lift_spec_PatchM_to_CompilerM {α : Type} {captures : Array NFA.Capture} {v : Code.PatchM α} {P : Array NFA.Unchecked.State → Prop} {Q : α → Array NFA.Unchecked.State → Prop} (h : ⦃ P ⦄ v ⦃ Q; fun (x : String) (x_1 : Array NFA.Unchecked.State) => False ⦄) :
⦃ fun (s : Array NFA.Unchecked.State × Array NFA.Capture × Array Nat) =>
P s.fst ∧ s.snd.fst = captures ∧ cValid captures ⦄ liftM v ⦃ fun (r : α) (s : Array NFA.Unchecked.State × Array NFA.Capture × Array Nat) =>
Q r s.fst ∧ s.snd.fst = captures ∧ cMemAndValid captures s.snd.fst; fun (x : String) (x_1 : Array NFA.Unchecked.State × Array NFA.Capture × Array Nat) => False ⦄
theorem Compiler.Lemmas.lift_spec_StateT_to_CompilerM {α : Type} {captures : Array NFA.Capture} {v : StateT (Array NFA.Unchecked.State) Id α} {P : Array NFA.Unchecked.State → Prop} {Q : α → Array NFA.Unchecked.State → Prop} (h : ⦃ P ⦄ v ⦃ Q ⦄) :
⦃ fun (s : Array NFA.Unchecked.State × Array NFA.Capture × Array Nat) =>
P s.fst ∧ s.snd.fst = captures ∧ cValid captures ⦄ liftM v ⦃ fun (r : α) (s : Array NFA.Unchecked.State × Array NFA.Capture × Array Nat) =>
Q r s.fst ∧ s.snd.fst = captures ∧ cMemAndValid captures s.snd.fst; fun (x : String) (x_1 : Array NFA.Unchecked.State × Array NFA.Capture × Array Nat) => False ⦄
theorem Compiler.Lemmas.nextOf_transition_le_of_le (states : Array NFA.Unchecked.State) (trans : Array NFA.Unchecked.Transition) (h : ∀ (i : Nat) (x : i < trans.size), trans[i].next ≤ states.size) :