wp rules for most operators such as return, get, gets are named
return_wp, get_wp, etc. Then when, whenE, unless, unlessE operators had
an additional hoare_.. prefix that this commit removes for more
consistency.
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
Moving `Monad_Equations.thy` and `More_NonDetMonadVCG.thy` into Monads
session enables us to remove the Lib and CLib session dependencies in
AutoCorres.
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
Remove dependency on Lib.thy. Theory imports of AutoCorres are now
reduced to theories that can be moved out of the Lib session.
The proof context changes a bit, but impact on test cases is minimal.
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
Since most bitwise operations are now available by default for nat,
only word abstraction in AutoCorres depends on NatBitwise.
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
Fix missing quotes. It looks like this ROOT file worked with `isabelle
build` before, but it did not work interactively.
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
This target was used in the regression test setup before this repo
switched to `run_tests` and has been unused for some time.
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
Conv.params_conv changes the context, and the inner conversion that
it runs needs to work on that inner context, otherwise information
is lost about which of the Free variables are former Bound.
Isabelle2021-1 has more thorough checking and fails when the wrong
context is provided.
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
After these changes AutoCorres type checks and compiles, and the proofs
work, but for most test cases we still get runtime exceptions.
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
Apparently, we still did releases with python2 in the past. This commit
updates the script to work cleanly with python3 and with both of Linux
and Darwin.
For the latter, untarring and executing a downloaded tarball is not
easily supported on MacOS, so instead of the tarball, we take a path to
the already unpacked Isabelle release.
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
The AutoCorres quickstart document includes code from `*.c` files from a
given line number, to avoid including license headers and other details
that aren't useful in the document. This updates the line numbers for
the current license headers.
Signed-off-by: Matthew Brecknell <Matthew.Brecknell@data61.csiro.au>
Isabelle2020 requires each session to declare it own set of directories that
may not overlap with other session's directories. This commit reorganises
files to comply with that requirement.
Signed-off-by: Gerwin Klein <gerwin.klein@data61.csiro.au>
Turns out the reuse tool will get confused by the addition SPDX tag
in the file, even though it is not in a comment. This commit pulls
out the tag such that string matching will not trigger on it.
Signed-off-by: Gerwin Klein <gerwin.klein@data61.csiro.au>
A rule to generate `%.thy` from `%.c` was previously too general, such
that it could fire for `%.thy` files that were not intended to be
generated, overwriting existing `%.thy` files.
This recently became an intermittent problem, when several `%.c` files
were updated to comply with style checks. Depending on how an `l4v`
checkout was updated, this sometimes made those `%.c` files newer than
the corresponding `%.thy` files.
This commit converts the implicit pattern rule into a static pattern
rule that applies to exactly those `%.thy` files that are intended to be
generated.
Signed-off-by: Matthew Brecknell <Matthew.Brecknell@data61.csiro.au>
Python 2 has passed its sunset date, and many distributions are
withdrawing support for Python 2.
PEP 394 recommends distributions always install versioned interpreter
commands (e.g. `python3`), but does not make a recommendation about
whether or not an unversioned command (`python`) should exist, or what
version it should run.
It therefore seems advisable to explicitly run scripts using the
`python3` command, for scripts that are compatible with Python 3.
Here, we do this for Python scripts used by `run_tests`. For this to
work, some scripts have been updated in ways that will break Python 2
compatibility. But for some other scripts which were already compatible
with both Python 2 and 3, we have not yet removed Python 2
compatibility. There are also miscellaneous scripts that are not used by
`run_tests`, and these have not yet been updated to Python 3.
Signed-off-by: Matthew Brecknell <Matthew.Brecknell@data61.csiro.au>