Lemmas for Init.Data.String.Modify #
This file contains lemmas for the operations defined in Init.Data.String.Modify.
Note that Init.Data.String.Modify already proves a few lemmas which are needed immediately.
theorem
String.ValidPos.Splits.pastModify
{f : Char → Char}
{s : String}
{p : s.ValidPos}
{t₁ t₂ : String}
{c : Char}
(h : p.Splits t₁ (singleton c ++ t₂))
:
(p.pastModify f ⋯).Splits (t₁ ++ singleton (f (p.get ⋯))) t₂
You might want to invoke ValidPos.Splits.exists_eq_singleton_append to be able to apply this.