Skip to content

Support for Rocq/Coq 9.0 #547

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

Open
wants to merge 8 commits into
base: master
Choose a base branch
from
Open

Support for Rocq/Coq 9.0 #547

wants to merge 8 commits into from

Conversation

xavierleroy
Copy link
Contributor

This PR adds basic support for the Rocq prover version 9.0.

We still use the coqc, coqtop, etc, command-line tools, relying on the Coq 9.0 compatibility layer.

The main change is the explicit prefixing of imports from the standard library with From Coq. At some later point this will become From Stdlib, but right now this would break compatibility with Coq 8.

Works around a strange link-time inconsistency in some cases.
For compatibility with Rocq 9.0.
New Flocq require >= 8.15.
Coq 9.0 is supported.
Warn if Rocq is installed but not Coq.
Coq is now able to extract empty Coq types to empty OCaml types.
This triggers a "unused-case" warning on pattern-matches involving the
`BI_platform` constructor of argument `platform_builtin`,
since the type `platform_builtin` is empty for RISC-V.

This commit simply turns warning "unused-case" (56) off for extracted files.

Note that "unused-case" warning is triggered by pattern-matching cases
that are not reachable for reasons of types.  It concerns mainly GADTs.
The classic, non-type based "redundant-case" warning (11) is
still active.
Rocq 9.0 wants `From Stdlib`, but Coq 8 understands `From Coq`.
Changing `From Coq` to `From Stdlib` later will be easy.
@xavierleroy
Copy link
Contributor Author

CI action latest not yet updated to use 9.0, see rocq-community/docker-rocq#10 .

@xavierleroy
Copy link
Contributor Author

The docker situation was resolved (thanks @erikmd !), so the latest CI action now uses Coq/Rocq 9.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant