Some properties that crunch can be used for have different legacy naming
schemes. This commit makes it possible for different instances of crunch
to be configured for either prefix or suffix naming.
Signed-off-by: Corey Lewis <corey.lewis@proofcraft.systems>
This means that spurious warnings are no longer produced by crunch when adding
attributes like simp or intro.
Signed-off-by: Corey Lewis <corey.lewis@proofcraft.systems>
These warn when attempting to add a constant to crunch_ignore that is
already being ignored, or when removing a constant that is not being ignored.
Signed-off-by: Corey Lewis <corey.lewis@proofcraft.systems>
Add support to crunch_ignore so that multiple instances can be added to
and removed from simultaneously.
Signed-off-by: Corey Lewis <corey.lewis@proofcraft.systems>
- opt_pred takes a predicate P and an option value x and
returns P y if x = Some y and False if x = None
- infix notation (|<), which lets us write in the style of
P |< projections
Signed-off-by: Miki Tanaka <miki.tanaka@data61.csiro.au>
- ogets and asks are equivalent
- make ogets a full abrreviation of asks
- provide the original definition of ogets as ogets_def
Signed-off-by: Miki Tanaka <miki.tanaka@data61.csiro.au>
Add a bundle for global word simp set changes -- unfortunately we
can't actually do this globally, because they are mostly simp rule
removals which will be overwritten by theory merges. So this new
l4v_word_lib bundle will have to be activated/unbundled multiple times.
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
Isabelle2021-1 simplifies `a << Suc 0` too eagerly, so we add simp
rules to compensate for new forms of goals. Removing the too-eager simp
rules would be less stable against theory merge.
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
More controlled simpset setup, so we don't get warnings if we have
bit_simps in the simpset already.
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
The benefit of the wpx method is not worth the maintenance effort.
There are still a few instances of wpx left in AInvs, which will have
to be fixed later.
We are keeping the wps method from the same file (WPEx.thy), because
that is used more widely and does not break with Isabelle2021-1
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
The repeat_unless method allows one to repeatedly apply some method
until some other method can be applied. This should be particularly
useful in Hoare triple proofs that use the forward-reasoning style
This commit was cherry-picked from the rt branch.
Signed-off-by: Michael McInerney <Michael.McInerney@data61.csiro.au>
The `value_type` top-level command allows evaluating a term down to a
natural number, and using that number to define an enumerated type, as
well as (optionally) a constant definition.
Co-authored-by: Rafal Kolanski <rafal.kolanski@proofcraft.systems>
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
The theory import order is important for name shadowing, including
default rules for induction and cases. This commit makes sure we
get the Word_Lib version by default, not the HOL.Word version.
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
The syntax OR for nondeterministic choice between two executions now
conflicts with the OR bit operation from the Isabelle distribution.
Since it was almost unused anyway, we remove it entirely and use only
the \<sqinter> symbol instead.
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>