Elm Exactly

TheoremrecvNone_sound

StandardElmMech/Eff/Messages.lean:130 · tactic proof

Statement

theorem recvNone_sound : ∀ {c : Val} {x : Input}, recvNone c x = true → ¬ ∃ v, Recv c x v

Proof

by
  intro c x h ⟨v, d⟩
  induction d with
  | r_e_msg_task => simp [recvNone] at h
  | r_e_msg_port p τ f j v' v'' hd _ =>
    simp only [recvNone, bne_self_eq_false, Bool.false_or] at h
    rw [(dec_iff τ j v').mp hd] at h
    simp at h
  | r_e_msg_map f c x v' v'' _ _ ih => exact ih (by simpa [recvNone] using h)

Proved with tactics, which Lean expands into a proof term that its kernel checks.

Rules of the book it uses

Theorems it uses

Used by

In StandardElmMech/Eff/Messages.lean: Messages (Recv, 3 rules, r_e_msg_*) and its logged twin, and the executable recvL, sound, complete and unique.

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.