Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Dan Frumin
iris-coq
Commits
58d1d6c9
Commit
58d1d6c9
authored
Feb 16, 2016
by
Robbert Krebbers
Browse files
Use some wp tactics in heap example.
parent
8f710abf
Changes
1
Show whitespace changes
Inline
Side-by-side
heap_lang/tests.v
View file @
58d1d6c9
...
...
@@ -31,18 +31,17 @@ Section LiftingTests.
Goal
∀
γ
h
N
,
heap_ctx
HeapI
γ
h
N
⊑
wp
N
e
(
λ
v
,
v
=
'
2
).
Proof
.
move
=>
γ
h
N
.
rewrite
/
e
.
rewrite
-
(
wp_bindi
(
LetCtx
_
_
))
.
eapply
wp_alloc
;
eauto
;
[].
wp_focus
(
ref
'1
)
%
L
.
eapply
wp_alloc
;
eauto
;
[].
rewrite
-
later_intro
;
apply
forall_intro
=>
l
;
apply
wand_intro_l
.
rewrite
-
wp_let
//= -later_intro.
rewrite
-
(
wp_bindi
(
SeqCtx
(
Load
(
Loc
_
))))
/=
.
rewrite
-
(
wp_bindi
(
StoreRCtx
(
LocV
_
)))
/=
.
rewrite
-
(
wp_bindi
(
BinOpLCtx
PlusOp
_
))
/=
.
eapply
wp_load
;
eauto
with
I
;
[].
apply
sep_mono
;
first
done
.
wp_rec
.
wp_focus
(
!
LocV
l
)
%
L
.
eapply
wp_load
;
eauto
with
I
;
[].
apply
sep_mono_r
.
rewrite
-
later_intro
;
apply
wand_intro_l
.
rewrite
-
wp_bin_op
// -later_intro.
eapply
wp_store
;
eauto
with
I
;
[].
apply
sep_mono
;
first
done
.
wp_bin_op
.
wp_focus
(
_
<-
_
)
%
L
.
eapply
wp_store
;
eauto
with
I
;
[].
apply
sep_mono_r
.
rewrite
-
later_intro
.
apply
wand_intro_l
.
rewrite
-
wp_seq
-
wp_value
'
-
later_intro
.
wp_rec
.
eapply
wp_load
;
eauto
with
I
;
[].
apply
sep_mono
;
first
done
.
rewrite
-
later_intro
.
apply
wand_intro_l
.
by
apply
const_intro
.
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a 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