SimonBoulier / TypingFlags

A Coq plugin to disable positivity check, guard check and termination check
16 stars 0 forks source link

Typing Flags is a Coq plugin to disable positivity check, guard check and termination check.

Disabling those checks leads of course to inconsistencies, use it at your own risks ...

This plugin is not perfect but it does the job. A better version will be integrated in Coq 8.11.

Tested with coq 8.6, 8.7, 8.8, 8.9.

Usage

Load the plugin with From TypingFlags Require Import Loader..

Then, the plugin provides the following commands:

The Print Assumptions command keeps track of which definition and inductives are unsafe. The command About also prints safety datas.

Installation

With OPAM

opam install coq-typing-flags

Magic, isn't it? Thanks to @clarus for the package.

Manually

Run make to compile the plugin, it needs to have coqc available.

Then, provided the repository theories of the plugin is in your load path, load it with:

Require Import TypingFlags.Loader.

To copy the plugin in the contrib directory of your local installation of Coq, and thus make it always available simply run:

make install

Examples

Acknowledgments

This plugin does not implement anything and only make accessible to the user some hidden functionalities of Coq. The implementation is due to Coq developers and in particular Arnaud Spiwack.

References: https://github.com/coq/coq/pull/79, https://github.com/coq/coq/pull/7651

Feedback and other use cases welcome.