Fix the examples / solution files for latest Iris.
We fix the tutorial so that it works with the development version of Iris.
Before merging, there is a small issue that should be looked into (see the FIXMEs): a previously working instance of wp_apply
has been replaced (there are several occurrences of that) by a wp_bind (_ ||| _)%E
followed by an iApply
. Is that an Iris bug?
Fixes #2 (closed)
Merge request reports
Activity
mentioned in issue #2 (closed)
- Resolved by Ralf Jung
Isn't that par_spec?Edited by Robbert KrebbersI'm not sure what's the use of that. It will look pretty ugly since we do not have a notation for ||| with value lambdas (and I'm not at all convinced we would want such a notation).
For all practical matters, wouldn't it be better to just use
par_spec
?Edited by Robbert KrebbersThere is a thunk implicitly, so I don't mind if the user has to be aware of that.
Anyway, what are the alternatives:
- Have a lemma for
par (LamV <> e) (LamV <> e)
. - Make a notation for
par (LamV <> e) (LamV <> e)
and state the lemma in terms of that notation.
None of these appear appealing to me.
Edited by Robbert Krebbers- Have a lemma for
Not a huge fan of that.
By the way, there is a worse problem when defining things like
while
loops. There you would hope to have the usual spec:WP if e1 then (e2; while e1 do e2) else #() {{ Φ }} -∗ WP while e1 do e2 {{ Φ }}}
But this only works in case
while
is a version with lambda-values for the thunks. If you would write it analogous to the way you propose for par, you end up with:WP if e1 then (e2; while (λ <>, e1)%V (λ <>, e2)%V) else #() {{ Φ }} -∗ WP while (λ <>, e1)%V (λ <>, e2)%V {{ Φ }}}
Which is rather ugly. If you write the lemma without thunking, you end up with:
WP if v1 #() then (v2 #(); while v1 v2) else #() {{ Φ }} -∗ WP while v1 v2 {{ Φ }}}
Which is not great either...
Not a huge fan of that.
I don't understand why. I also don't understand why you bring up
while
.par (λ _, e1)%V (λ _, e2)%V
is the shape that the expressions will always have in the moment the user can applywp_par
. So it makes perfect sense to state the lemma that way. Is the lack of notation your only concern?I don't understand why.
Because the spec using value lambdas does not use the notation.
I also don't understand why you bring up
while
.Because there we have exactly the same issues:
- while takes thunks as arguments, like par.
- the notation for while will be stated using thunks, like par.
- these thunks have to be turned into value lambdas.
- stating the spec using value lambdas is ugly, which is the same problem we are having here for par.
Edited by Robbert KrebbersBecause the spec using value lambdas does not use the notation.
I agree the spec is less readable than it should, but I think that's worth the trade-off for producing more readable goals after being applied. This is weighing displaying the proof state right after
iApply wp_par
in any user of this spec against readability of the spec.Actually it's not even a trade-off, because if you don't like
wp_par
you can usepar_spec
in your proofs. But I don't understand why you want to force everyone else to have an uglier proof state.Just to get things clear: By saying that I'm not a huge fan of
wp_par
the way you would like to state it, I'm not necessarily suggesting to remove it, I'm mostly wondering if we can do better and pointing out where similar issues appear (c.f. the while example) so that we can come up with a uniform solution.Also, it would be good if we have some way of making clear to users when to use which specs. For a novice user it's not really clear when to use neither
wp_par
norpar_spec
. (And not just notice users, which is witnessed by the fact this issue exists in the first place).Edited by Robbert KrebbersI made a proposal at https://gitlab.mpi-sws.org/FP/iris-coq/merge_requests/210, to at least move us a bit into the right direction (and to unblock this MR).
mentioned in merge request iris!210 (merged)
added 2 commits
added 9 commits
-
c7d3c88b...43cf91c4 - 7 commits from branch
master
- 5efd4e91 - Merged from master.
- 9a31dcc8 - Merge branch 'master' into latest_iris
-
c7d3c88b...43cf91c4 - 7 commits from branch
I think we are ready for merging, up to version information, but I don't really know what version number to point to. What I known is that everything works fine with
dev.2019-01-22.0.b85a3cfc
. What should I do @jung?@lepigre then please point it to that specific version in the
opam
file. It's as good as any...28 opam repo add iris-dev https://gitlab.mpi-sws.org/FP/opam-dev.git 27 29 28 Then you can do `opam install coq-iris.3.1.0`. 30 Then you can do `opam install coq-iris`. 29 31 30 32 ## Installing Iris from source 31 33 32 34 If you are unable to use opam, you can also build Iris from source. For this, 33 make sure to `git checkout` the correct versions, and run `make; make install` 34 for all of: 35 run `make; make install` for all of: 35 36 36 37 * ssreflect: <https://github.com/math-comp/math-comp/archive/mathcomp-1.7.0.tar.gz> 37 38 (`cd mathcomp/ssreflect` to only compile and install what is needed) 38 39 * std++: <https://gitlab.mpi-sws.org/iris/stdpp/repository/coq-stdpp-1.1.0/archive.tar.gz> 39 40 * Iris: <https://gitlab.mpi-sws.org/FP/iris-coq/repository/iris-3.1.0/archive.tar.gz> added 1 commit
- 7e44373e - Compatible [iris-coq] version in the [opam] file.
mentioned in commit 53a92a4e
8 8 9 9 clean: Makefile.coq 10 10 +@make -f Makefile.coq clean 11 find theories $$(test -d tests && echo tests) \( -name "*.d" -o -name "*.vo" -o -name "*.aux" -o -name "*.cache" -o -name "*.glob" -o -name "*.vio" \) -print -delete mentioned in merge request !3 (merged)