Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Rodolphe Lepigre
Iris
Commits
cb27aa7f
Commit
cb27aa7f
authored
Jul 01, 2019
by
Ralf Jung
Browse files
use decide instead of bool_decide where possible
parent
1889960b
Changes
2
Hide whitespace changes
Inline
Side-by-side
theories/heap_lang/lang.v
View file @
cb27aa7f
...
...
@@ -520,7 +520,7 @@ Definition bin_op_eval_bool (op : bin_op) (b1 b2 : bool) : option base_lit :=
Definition
bin_op_eval
(
op
:
bin_op
)
(
v1
v2
:
val
)
:
option
val
:
=
if
decide
(
op
=
EqOp
)
then
(* Crucially, this compares the same way as [CmpXchg]! *)
if
bool_
decide
(
vals_compare_safe
v1
v2
)
then
if
decide
(
vals_compare_safe
v1
v2
)
then
Some
$
LitV
$
LitBool
$
bool_decide
(
v1
=
v2
)
else
None
...
...
theories/heap_lang/lifting.v
View file @
cb27aa7f
...
...
@@ -172,7 +172,7 @@ Proof.
intros
Hcompare
.
cut
(
bin_op_eval
EqOp
v1
v2
=
Some
$
LitV
$
LitBool
$
bool_decide
(
v1
=
v2
)).
{
intros
.
revert
Hcompare
.
solve_pure_exec
.
}
rewrite
/
bin_op_eval
/=
bool_
decide_
t
rue
//.
rewrite
/
bin_op_eval
/=
decide_
T
rue
//.
Qed
.
Instance
pure_if_true
e1
e2
:
PureExec
True
1
(
If
(
Val
$
LitV
$
LitBool
true
)
e1
e2
)
e1
.
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment