-
Notifications
You must be signed in to change notification settings - Fork 659
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Uniformize semantics of :> in class after deprecation phase of #16230 #18590
Conversation
1f06c14
to
9b95a02
Compare
9b95a02
to
27e0859
Compare
The job library:ci-fiat_crypto_legacy has failed in allow failure mode |
27e0859
to
32444fb
Compare
CI green, as far as I'm concerned, this is ready |
Still waiting for fcl |
I don't know why f-c-l is still allow failure. It was originally put there due to the intricacy of the tactic scripts, but it has not had an issue that required patching the tactics in a long time, it no longer tries to maintain backwards compatibily, and it has caught bugs that no other CI development has caught. I think it should be moved out of allowed failure. I'll try to create an overlay within the next couple days to a week. The fix is just to replace |
For coq/coq#18590 Change made with ```bash python -c "$(printf 'import re\nfs = {f:open(f, "r").read() for f in (%s)}\nfs2 = {f:[m for m in re.findall(r"%s", c, flags=re.MULTILINE|re.DOTALL) if not m.startswith("Existing") and ":>" in m and re.search(r"%s", m, flags=re.MULTILINE|re.DOTALL)] for f, c in fs.items()}\nfs3 = {f:m for f, m in fs2.items() if m}\nfs4 = {}\nfor f, m in fs3.items():\n orig = rep = fs[f]\n for val in m:\n rep = rep.replace(val, val.replace(":>", "::"))\n fs4[f] = rep\nfor f, c in fs4.items():\n open(f, "w").write(c)' "$(printf '"%s", ' $(git grep --name-only 'Class '))" '(?:Existing\s+)?Class\s.*?\.\s' ':=\s*{')" ```
doc/changelog/02-specification-language/18590-cleanup_16230.rst
Outdated
Show resolved
Hide resolved
For coq/coq#18590 Change made with ```bash python -c "$(printf 'import re\nfs = {f:open(f, "r").read() for f in (%s)}\nfs2 = {f:[m for m in re.findall(r"%s", c, flags=re.MULTILINE|re.DOTALL) if not m.startswith("Existing") and ":>" in m and re.search(r"%s", m, flags=re.MULTILINE|re.DOTALL)] for f, c in fs.items()}\nfs3 = {f:m for f, m in fs2.items() if m}\nfs4 = {}\nfor f, m in fs3.items():\n orig = rep = fs[f]\n for val in m:\n rep = rep.replace(val, val.replace(":>", "::"))\n fs4[f] = rep\nfor f, c in fs4.items():\n open(f, "w").write(c)' "$(printf '"%s", ' $(git grep --name-only 'Class '))" '(?:Existing\s+)?Class\s.*?\.\s' ':=\s*{')" ```
This way, in next version, we can finally have :> declare a coercion in any record declaration, including typeclasses. Whereas :: consistently declares typeclass instances since Coq 8.18.
The job library:ci-fiat_crypto_legacy has failed in allow failure mode |
@JasonGross fiat_crypto_legacy is still failing, apparently your script did not handle definitional typeclasses |
I fixed my script and made mit-plv/fiat-crypto#1830, which will auto-merge once CI finishes running there |
Thanks that seems to work |
@coqbot merge now |
Thanks! |
This ends the deprecation phases of #16230 and #15802 that introduced :: instead of :> for subclasses in Class declarations. Now :> produces an error in
Class
before we can make it mean coercion in all record declarations (including typeclasses) in next version.Updated documented syntax by runningmake doc_gram_rsts
.Overlays (to be merged before the current PR):
To prepare overlays, just ensure that the code compiles with any Coq >= 8.18 and options
-w +future-coercion-class-constructor
and-w +future-coercion-class-field