Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Iris
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Pierre Roux
Iris
Commits
46151cd2
Commit
46151cd2
authored
5 years ago
by
Dan Frumin
Browse files
Options
Downloads
Patches
Plain Diff
Allow multiple arguments in `iEval .. in` and `iSimpl in`.
parent
cdc564bf
No related branches found
No related tags found
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
ProofMode.md
+1
-0
1 addition, 0 deletions
ProofMode.md
tests/proofmode.ref
+10
-0
10 additions, 0 deletions
tests/proofmode.ref
tests/proofmode.v
+5
-0
5 additions, 0 deletions
tests/proofmode.v
theories/proofmode/ltac_tactics.v
+13
-5
13 additions, 5 deletions
theories/proofmode/ltac_tactics.v
with
29 additions
and
5 deletions
ProofMode.md
+
1
−
0
View file @
46151cd2
...
@@ -160,6 +160,7 @@ Rewriting / simplification
...
@@ -160,6 +160,7 @@ Rewriting / simplification
with the resulting
`P`
, which in turn becomes the new proof mode goal /
with the resulting
`P`
, which in turn becomes the new proof mode goal /
hypothesis
`H`
.
hypothesis
`H`
.
Note that parentheses around
`tac`
are needed.
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 /
-
`iSimpl`
/
`iSimpl in H`
: performs
`simpl`
on the proof mode goal /
hypothesis
`H`
. This is a shorthand for
`iEval (simpl)`
.
hypothesis
`H`
. This is a shorthand for
`iEval (simpl)`
.
...
...
This diff is collapsed.
Click to expand it.
tests/proofmode.ref
+
10
−
0
View file @
46151cd2
...
@@ -101,6 +101,16 @@ Tactic failure: iSpecialize: cannot instantiate (⌜φ⌝ → P -∗ False)%I wi
...
@@ -101,6 +101,16 @@ Tactic failure: iSpecialize: cannot instantiate (⌜φ⌝ → P -∗ False)%I wi
--------------------------------------∗
--------------------------------------∗
⌜S (S (S x)) = y⌝
⌜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"
"test_iFrame_later_1"
: string
: string
1 subgoal
1 subgoal
...
...
This diff is collapsed.
Click to expand it.
tests/proofmode.v
+
5
−
0
View file @
46151cd2
...
@@ -473,6 +473,11 @@ Check "test_iSimpl_in".
...
@@ -473,6 +473,11 @@ Check "test_iSimpl_in".
Lemma
test_iSimpl_in
x
y
:
⌜
(
3
+
x
)
%
nat
=
y
⌝
-∗
⌜
S
(
S
(
S
x
))
=
y
⌝
:
PROP
.
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
.
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
.
Lemma
test_iIntros_pure_neg
:
(
⌜
¬
False
⌝
:
PROP
)
%
I
.
Proof
.
by
iIntros
(?)
.
Qed
.
Proof
.
by
iIntros
(?)
.
Qed
.
...
...
This diff is collapsed.
Click to expand it.
theories/proofmode/ltac_tactics.v
+
13
−
5
View file @
46151cd2
...
@@ -114,13 +114,21 @@ Tactic Notation "iEval" tactic(t) :=
...
@@ -114,13 +114,21 @@ Tactic Notation "iEval" tactic(t) :=
[
let
x
:=
fresh
in
intros
x
;
t
;
unfold
x
;
reflexivity
[
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
)
:=
Tactic
Notation
"iEval"
tactic
(
t
)
"in"
constr
(
H
)
:=
iStartProof
;
iStartProof
;
eapply
tac_eval_in
with
_
H
_
_
_;
let
Hs
:=
words
H
in
iEval_go
t
Hs
.
[
pm_reflexivity
||
fail
"iEval:"
H
"not found"
|
let
x
:=
fresh
in
intros
x
;
t
;
unfold
x
;
reflexivity
|
pm_reflexivity
|]
.
Tactic
Notation
"iSimpl"
:=
iEval
(
simpl
)
.
Tactic
Notation
"iSimpl"
:=
iEval
(
simpl
)
.
Tactic
Notation
"iSimpl"
"in"
constr
(
H
)
:=
iEval
(
simpl
)
in
H
.
Tactic
Notation
"iSimpl"
"in"
constr
(
H
)
:=
iEval
(
simpl
)
in
H
.
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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!
Save comment
Cancel
Please
register
or
sign in
to comment