TheoremfmLookup_append
Statement
theorem fmLookup_append {β : Type} (l1 l2 : List (String × β)) (a : String) :
fmLookup (l1 ++ l2) a = match fmLookup l1 a with
| some x => some x
| none => fmLookup l2 aProof
by
induction l1 with
| nil => simp [fmLookup]
| cons p l1 ih =>
obtain ⟨k, x⟩ := p
simp only [List.cons_append, fmLookup]
split <;> simp_allProved with tactics, which Lean expands into a proof term that its kernel checks.
Used by
In StandardElmMech/Mod/Properties.lean: The frame lemmas (a module's derivation reads the basis only at the modules it imports) and Btest_agrees.
A Standard Definition of Elm? (Draft version 0.4) © Rupert Smith. The text is licensed under CC BY 4.0: share and adapt it freely, with credit and a link to the licence.