Theoremsc_valBind
Statement
theorem sc_valBind : (vb : AValBind) → (C : Ctx) → (Γ : Shape) → Abs C Γ → checkValBind C vb = true →
scVB Γ vb.erase = true
| .var _ ann _ e rest, C, Γ, hA, h => by
simp only [checkValBind, Bool.and_eq_true] at h
simp only [AValBind.erase, scVB, Bool.and_eq_true]
exact ⟨sc_exp e _ Γ (abs_plusU _ hA) h.1.1.2, sc_valBindOpt rest C Γ hA h.2⟩
| .pat p e, C, Γ, hA, h => by
simp only [checkValBind, Bool.and_eq_true] at h
simp only [AValBind.erase, scVB, Bool.and_eq_true]
exact ⟨sc_atPat C Γ hA p h.1.1, sc_exp e C Γ hA h.1.2⟩Proof
Proved by a term, which Lean's kernel checks directly.
Used by
In StandardElmMech/Stat/RefuseScope.lean: Refusals by scope, constructor arity and imports, for one module and for a module after a helper (scopeFailB).
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.