lh-l4v/lib/Monads
Michael McInerney 27d838af86 lib+proof: rename bind_assoc_reverse to bind_assoc_return_reverse
This also improves the style of this lemma

Signed-off-by: Michael McInerney <michael.mcinerney@proofcraft.systems>
2023-03-27 10:34:03 +10:30
..
wp lib/monads: add sum type to Datatype_Schematic 2023-02-09 11:46:49 +11:00
Det.thy lib/monads: split up NonDetMonadVCG 2023-02-09 11:46:46 +11:00
Empty_Fail.thy lib: add empty_fail_ifME and empty_fail_notM 2023-03-21 10:45:28 +10:30
Fun_Pred_Syntax.thy lib: move more monad thys into Monads directory 2023-01-24 11:30:05 +11:00
In_Monad.thy lib/monads: style cleanup in In_Monad 2023-02-09 11:46:49 +11:00
Less_Monad_Syntax.thy lib+READMEs: rename Monad_WP to Monads 2023-01-24 11:30:05 +11:00
MonadEq.thy lib/monads: style cleanup in MonadEq+MonadEq_Lemmas 2023-02-09 11:46:50 +11:00
MonadEq_Lemmas.thy lib/monads: style cleanup in MonadEq+MonadEq_Lemmas 2023-02-09 11:46:50 +11:00
Monad_Equations.thy lib+proof: rename bind_assoc_reverse to bind_assoc_return_reverse 2023-03-27 10:34:03 +10:30
Monad_Lib.thy lib/monads: refactor + cleanup in NonDetMonadVCG 2023-02-09 11:46:49 +11:00
More_NonDetMonadVCG.thy lib: add ifME_liftE 2023-03-21 10:45:28 +10:30
No_Fail.thy lib/monads: refactor + cleanup in No_Fail 2023-02-09 11:46:49 +11:00
No_Throw.thy lib/monads: style cleanup in No_Throw 2023-02-09 11:46:48 +11:00
NonDetMonad.thy lib: add ifME 2023-03-21 10:45:28 +10:30
NonDetMonadLemmas.thy lib/monads: style cleanup in NonDetMonadLemmas 2023-02-09 11:46:50 +11:00
NonDetMonadVCG.thy lib: add notM and notM_wp 2023-03-21 10:45:28 +10:30
NonDetMonad_Sat.thy lib: several lemmas involving exs_valid and the reader monad 2023-03-20 18:55:49 +10:30
NonDetMonad_Total.thy lib/monads: refactor + cleanup in No_Fail 2023-02-09 11:46:49 +11:00
OptionMonad.thy lib: add some definitions and rules from rt branch 2023-02-07 11:30:30 +10:30
OptionMonadND.thy lib: several lemmas involving exs_valid and the reader monad 2023-03-20 18:55:49 +10:30
OptionMonadWP.thy lib: several lemmas involving exs_valid and the reader monad 2023-03-20 18:55:49 +10:30
README.md lib: fix link in Monads README (#576) 2023-02-10 09:12:34 +11:00
ROOT lib/monads: refactor + cleanup in NonDetMonadVCG 2023-02-09 11:46:49 +11:00
Strengthen.thy lib+READMEs: rename Monad_WP to Monads 2023-01-24 11:30:05 +11:00
Strengthen_Demo.thy lib+READMEs: rename Monad_WP to Monads 2023-01-24 11:30:05 +11:00
Strengthen_Setup.thy lib/monads: split up NonDetMonadVCG 2023-02-09 11:46:46 +11:00
TraceMonad.thy lib+READMEs: rename Monad_WP to Monads 2023-01-24 11:30:05 +11:00
TraceMonadLemmas.thy lib+READMEs: rename Monad_WP to Monads 2023-01-24 11:30:05 +11:00
TraceMonadVCG.thy lib/monads: remove alternative_valid in TraceMonad 2023-02-09 11:46:50 +11:00
WhileLoopRules.thy lib+ainvs: pull up more empty_fail lemmas 2023-02-09 11:46:50 +11:00
WhileLoopRulesCompleteness.thy lib+READMEs: rename Monad_WP to Monads 2023-01-24 11:30:05 +11:00
tests.xml lib: introduce Monads session 2023-01-24 11:30:05 +11:00

README.md

Monad Definitions and Tactics

This session contains definitions of various monads useful in AutoCorres and the seL4 verification for the verification of C programs.

In particular, this session defines:

  • a nondeterministic state monad with failure to express stateful computation. There is a variation of this monad that also allows computation with exceptions (throw/catch).

  • a reader option monad to express computation that can depend on state and can fail, but does not change state. It can also be used to express projections from the state in preconditions and other state assertions.

  • a trace monad that stores a set of traces for expressing concurrent computation.

  • for each of these monads, weakest-precondition lemmas and corresponding tool setup.

  • for the nondeterministic state monad, additional concepts such as wellformedness with respect to failure (empty_fail), absence of failure (no_fail), absence of exceptions (no_throw). See the respective theories for more details.

The directory wp/ contains proof methods to reason about these monads in weakest-precondition style.