TheoremfmLookup_some_mem
Statement
theorem fmLookup_some_mem {β : Type} : ∀ (f : List (String × β)) (a : String) (x : β),
fmLookup f a = some x → (a, x) ∈ f
| [], _, _, h => by simp [fmLookup] at h
| (k, y) :: f, a, x, h => by
simp only [fmLookup] at h
split at h
· rename_i hk; simp only [beq_iff_eq] at hk; subst hk; cases h; simp
· exact List.mem_cons_of_mem _ (fmLookup_some_mem f a x h)Proof
Proved by a term, which Lean's kernel checks directly.
Used by
In StandardElmMech/Mod/Good.lean: The property of interfaces (Interface.Good): ME0 and the harness have it (ME0_good), a top-level declaration with distinct bound names infers an interface with it (EvalTopDec.good), a header's exposing list keeps it (EvalHeader.good), and so does every interface a module puts in the basis (EvalModule.good).
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.