| 1 | (************************************************************************) |
| 2 | (* * The Rocq Prover / The Rocq Development Team *) |
| 3 | (* v * Copyright INRIA, CNRS and contributors *) |
| 4 | (* <O___,, * (see version control and CREDITS file for authors & dates) *) |
| 5 | (* \VV/ **************************************************************) |
| 6 | (* // * This file is distributed under the terms of the *) |
| 7 | (* * GNU Lesser General Public License Version 2.1 *) |
| 8 | (* * (see LICENSE file for the text of the license) *) |
| 9 | (************************************************************************) |
| 10 | |
| 11 | open Ind_tables |
| 12 | open Names |
| 13 | open Environ |
| 14 | |
| 15 | (** Declare an inductive should be eliminated dependently even though it's in Prop *) |
| 16 | val declare_prop_but_default_dependent_elim : inductive -> unit |
| 17 | |
| 18 | (** Check if an inductive should be eliminated dependently even though it's in Prop *) |
| 19 | val is_prop_but_default_dependent_elim : inductive -> bool |
| 20 | |
| 21 | (** Legacy API, returns the quality of the inductive except if it's |
| 22 | prop_but_default_dependent_elim in which case we return Type |
| 23 | instead. *) |
| 24 | val pseudo_sort_quality_for_elim : inductive -> Declarations.one_inductive_body -> Sorts.Quality.t |
| 25 | |
| 26 | (** Returns [false] on inductives which cannot be eliminated |
| 27 | dependently or are in Prop without being declared |
| 28 | prop_but_default_dependent_elim. *) |
| 29 | val default_case_analysis_dependence : env -> inductive -> bool |
| 30 | |
| 31 | (** Induction/recursion schemes *) |
| 32 | val elim_scheme : dep:bool -> to_kind:UnivGen.QualityOrSet.t -> individual scheme_kind |
| 33 | |
| 34 | (** Case analysis schemes *) |
| 35 | |
| 36 | val case_dep : individual scheme_kind |
| 37 | val case_nodep : individual scheme_kind |
| 38 | val casep_dep : individual scheme_kind |
| 39 | val casep_nodep : individual scheme_kind |
| 40 | |
| 41 | (** Recursor names utilities *) |
| 42 | |
| 43 | val lookup_eliminator : Environ.env -> Names.inductive -> UnivGen.QualityOrSet.t -> Names.GlobRef.t |
| 44 | val elimination_suffix : UnivGen.QualityOrSet.t -> string |
| 45 | val make_elimination_ident : Names.Id.t -> UnivGen.QualityOrSet.t -> Names.Id.t |