Backwards wp steps, for every registered judgment #
Judgment.wpStep k processes the last k statements of a judgment's statement one at a time,
from the end:
- deterministic code (
Judgment.detOf?: assignments, resets,skip, sequences and conditionals of those) by the judgment'sdetLemma— the postcondition after the state update, the same shape in every judgment; - a sampling by the judgment's
sampleLemma, a call by itscallLemma, a conditional with calls or samplings in its branches by itsifLemma— where judgments genuinely differ;
simplifying the postcondition after each step with the judgment's postSimp. hoare_wp,
phoare_wp and the dispatching stmt_wp are this one step.
Apply the rule lem to the goal g (of type ty): its conclusion unified with the goal, the
argument of type Stmt.Det … (if any) set to det?, and the judgment about the remaining
statement — the last argument — returned as the new goal.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Simplify argument i of the goal with simpWithNames decls procs.
Equations
- One or more equations did not get rendered due to their size.
Instances For
One backwards step over the last statement of the goal's judgment (of side side? of a
relational one). With detOnly, only over deterministic code: anything else is an error.
Equations
- One or more equations did not get rendered due to their size.
Instances For
k backwards steps (wpOne), the last statement first; on a relational judgment, k on
side side?, or on each side for none.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Backwards steps over the deterministic code at the end of the statement, as many as there
are (EasyCrypt's wp): until the statement is skip or ends in a sampling, a call or a loop.
On a relational judgment, on side side?, or on each side for none.
Equations
- One or more equations did not get rendered due to their size.
Instances For
stmt_wp k: the last k statements of any registered judgment's statement, by wp
(Judgment.wpStep); stmt_wp alone: all the deterministic code at the end (Judgment.wpDet).
On a relational judgment, on both sides, or with stmt_wp{i} on side i.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
An EC code position (n or -n), as in wp n m/sp n m.
Equations
Instances For
Equations
- GaudisCrypt.Judgment.ecPos_ = Lean.ParserDescr.node `GaudisCrypt.Judgment.ecPos_ 1022 (Lean.ParserDescr.const `num)
Instances For
Equations
- GaudisCrypt.Judgment.«ecPos-_» = Lean.ParserDescr.node `GaudisCrypt.Judgment.«ecPos-_» 1022 (Lean.ParserDescr.binary `andthen (Lean.ParserDescr.symbol "-") (Lean.ParserDescr.const `num))
Instances For
The integer an ecPos denotes.
Equations
- One or more equations did not get rendered due to their size.
Instances For
EC's code gap (s_codegap1_0before): in a statement of len statements, n ≥ 0 is the
gap after the first n (before the statement at 0-based index n), -k the gap after the
k-th statement from the end (-1: after the last). The number of statements before it.
Equations
- One or more equations did not get rendered due to their size.
Instances For
EC's wp n: the statements after EC's code gap pos (TacticMisc.ecGapIn: EC's
statements, the resets inlining leaves not counted) by wp (wpStep), the ones before kept; on
side side? of a relational judgment.
Equations
- One or more equations did not get rendered due to their size.
Instances For
EC's wp n m on a relational judgment, with EC's code positions (ecGap): on the left
the statements after the first n by wp, on the right those after the first m (-k: up to
the k-th from the end). (The one-number stmt_wp k counts from the end: the last k.)
Equations
- One or more equations did not get rendered due to their size.