Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
George Pirlea
Iris
Commits
46151cd2
Commit
46151cd2
authored
May 01, 2019
by
Dan Frumin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Allow multiple arguments in `iEval .. in` and `iSimpl in`.
parent
cdc564bf
Changes
4
Hide whitespace changes
Inline
Sidebyside
Showing
4 changed files
with
29 additions
and
5 deletions
+29
5
ProofMode.md
ProofMode.md
+1
0
tests/proofmode.ref
tests/proofmode.ref
+10
0
tests/proofmode.v
tests/proofmode.v
+5
0
theories/proofmode/ltac_tactics.v
theories/proofmode/ltac_tactics.v
+13
5
No files found.
ProofMode.md
View file @
46151cd2
...
...
@@ 160,6 +160,7 @@ Rewriting / simplification
with the resulting
`P`
, which in turn becomes the new proof mode goal /
hypothesis
`H`
.
Note that parentheses around
`tac`
are needed.
If
`H`
is a list of hypothesis, then
`iEval`
will perform
`tac`
on each of them.

`iSimpl`
/
`iSimpl in H`
: performs
`simpl`
on the proof mode goal /
hypothesis
`H`
. This is a shorthand for
`iEval (simpl)`
.
...
...
tests/proofmode.ref
View file @
46151cd2
...
...
@@ 101,6 +101,16 @@ Tactic failure: iSpecialize: cannot instantiate (⌜φ⌝ → P ∗ False)%I wi
∗
⌜S (S (S x)) = y⌝
1 subgoal
PROP : sbi
x, y, z : nat
============================
"H1" : ⌜S (S (S x)) = y⌝
"H2" : ⌜S y = z⌝
∗
⌜S (S (S x)) = y⌝
"test_iFrame_later_1"
: string
1 subgoal
...
...
tests/proofmode.v
View file @
46151cd2
...
...
@@ 473,6 +473,11 @@ Check "test_iSimpl_in".
Lemma
test_iSimpl_in
x
y
:
⌜
(
3
+
x
)%
nat
=
y
⌝

∗
⌜
S
(
S
(
S
x
))
=
y
⌝
:
PROP
.
Proof
.
iIntros
"H"
.
iSimpl
in
"H"
.
Show
.
done
.
Qed
.
Lemma
test_iSimpl_in_2
x
y
z
:
⌜
(
3
+
x
)%
nat
=
y
⌝

∗
⌜
(
1
+
y
)%
nat
=
z
⌝

∗
⌜
S
(
S
(
S
x
))
=
y
⌝
:
PROP
.
Proof
.
iIntros
"H1 H2"
.
iSimpl
in
"H1 H2"
.
Show
.
done
.
Qed
.
Lemma
test_iIntros_pure_neg
:
(
⌜
¬
False
⌝
:
PROP
)%
I
.
Proof
.
by
iIntros
(?).
Qed
.
...
...
theories/proofmode/ltac_tactics.v
View file @
46151cd2
...
...
@@ 114,13 +114,21 @@ Tactic Notation "iEval" tactic(t) :=
[
let
x
:
=
fresh
in
intros
x
;
t
;
unfold
x
;
reflexivity
].
Ltac
iEval_go
t
Hs
:
=
match
Hs
with

[]
=>
idtac

?H
::
?Hs
=>
let
H
:
=
pretty_ident
H
in
eapply
tac_eval_in
with
_
H
_
_
_;
[
pm_reflexivity

fail
"iEval:"
H
"not found"

let
x
:
=
fresh
in
intros
x
;
t
;
unfold
x
;
reflexivity

pm_reflexivity

iEval_go
t
Hs
]
end
.
Tactic
Notation
"iEval"
tactic
(
t
)
"in"
constr
(
H
)
:
=
iStartProof
;
eapply
tac_eval_in
with
_
H
_
_
_;
[
pm_reflexivity

fail
"iEval:"
H
"not found"

let
x
:
=
fresh
in
intros
x
;
t
;
unfold
x
;
reflexivity

pm_reflexivity
].
let
Hs
:
=
words
H
in
iEval_go
t
Hs
.
Tactic
Notation
"iSimpl"
:
=
iEval
(
simpl
).
Tactic
Notation
"iSimpl"
"in"
constr
(
H
)
:
=
iEval
(
simpl
)
in
H
.
...
...
Write
Preview
Markdown
is supported
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