TheoremstatProgram_of_endToEnd
A run of the pipeline gives the static premise of r:p-program, under D11 for the program and its further restrictions.
Statement
theorem statProgram_of_endToEnd {B : SBasis} {s : SProgram} {r : Mod.Reduced}
(hI : InferPrincipalFor B (bareOf s)) (hF : FurtherFor B (bareOf s)) (h : endToEnd B s = .ok r) :
∃ τ PE, StatProgram B (bareOf s) τ PEProof
by
obtain ⟨a, rs, hi, hr, he, hc, -⟩ := endToEnd_ok h
obtain ⟨-, Bs, hBs, hpr⟩ := hI a hi (checkProgram_of_progResults hr)
have hne : a ≠ [] := by
rintro rfl
simp [progResults] at hr; subst hr
simp [checksAll, mainScheme] at hc
obtain ⟨τ, PE, hel⟩ := elProgram_of_results B a Bs rs hr hBs hpr (hF a hi Bs hBs) hc hne
refine ⟨τ, PE, ?_⟩
show ElProgram B (bareOf s).modules τ PE
rw [← he]; exact helProved with tactics, which Lean expands into a proof term that its kernel checks.
Rules of the book it uses
Theorems it uses
In StandardElmMech/Stat/Pipeline.lean: SpecOf, DynOf (in Lib.Btest for a view, Mod.Btest [] for a worker: dynBasis), ProgramSem (r:p-program), D11For; copy names, payload types and main (copyName_inj, toPTy_isSome_iff, mainKind_worker_iff, mainKind_view_iff); the pipeline theorems (specOf_of_endToEnd, programSem_of_legal).
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.