~ubuntu-branches/ubuntu/wily/coq-doc/wily

« back to all changes in this revision

Viewing changes to checker/inductive.mli

  • Committer: Bazaar Package Importer
  • Author(s): Stéphane Glondu, Stéphane Glondu, Samuel Mimram
  • Date: 2010-01-07 22:50:39 UTC
  • mfrom: (1.2.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20100107225039-n3cq82589u0qt0s2
Tags: 8.2pl1-1
[ Stéphane Glondu ]
* New upstream release (Closes: #563669)
  - remove patches
* Packaging overhaul:
  - use git, advertise it in Vcs-* fields of debian/control
  - use debhelper 7 and dh with override
  - use source format 3.0 (quilt)
* debian/control:
  - set Maintainer to d-o-m, set Uploaders to Sam and myself
  - add Homepage field
  - bump Standards-Version to 3.8.3
* Register PDF documentation into doc-base
* Add debian/watch
* Update debian/copyright

[ Samuel Mimram ]
* Change coq-doc's description to mention that it provides documentation in
  pdf format, not postscript, closes: #543545.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
(************************************************************************)
 
2
(*  v      *   The Coq Proof Assistant  /  The Coq Development Team     *)
 
3
(* <O___,, * CNRS-Ecole Polytechnique-INRIA Futurs-Universite Paris Sud *)
 
4
(*   \VV/  **************************************************************)
 
5
(*    //   *      This file is distributed under the terms of the       *)
 
6
(*         *       GNU Lesser General Public License Version 2.1        *)
 
7
(************************************************************************)
 
8
 
 
9
(*i $Id: inductive.mli 9420 2006-12-08 15:34:09Z barras $ i*)
 
10
 
 
11
(*i*)
 
12
open Names
 
13
open Term
 
14
open Declarations
 
15
open Environ
 
16
(*i*)
 
17
 
 
18
(*s Extracting an inductive type from a construction *)
 
19
 
 
20
val find_rectype : env -> constr -> inductive * constr list
 
21
 
 
22
type mind_specif = mutual_inductive_body * one_inductive_body
 
23
 
 
24
(*s Fetching information in the environment about an inductive type.
 
25
    Raises [Not_found] if the inductive type is not found. *)
 
26
val lookup_mind_specif : env -> inductive -> mind_specif
 
27
 
 
28
val type_of_inductive : env -> mind_specif -> constr
 
29
 
 
30
(* Return type as quoted by the user *)
 
31
val type_of_constructor : constructor -> mind_specif -> constr
 
32
 
 
33
val arities_of_specif : mutual_inductive -> mind_specif -> constr array
 
34
 
 
35
(* [type_case_branches env (I,args) (p:A) c] computes useful types
 
36
   about the following Cases expression:
 
37
      <p>Cases (c :: (I args)) of b1..bn end
 
38
   It computes the type of every branch (pattern variables are
 
39
   introduced by products) and the type for the whole expression.
 
40
 *)
 
41
val type_case_branches :
 
42
  env -> inductive * constr list -> constr * constr -> constr
 
43
    -> constr array * constr
 
44
 
 
45
(* Check a [case_info] actually correspond to a Case expression on the
 
46
   given inductive type. *)
 
47
val check_case_info : env -> inductive -> case_info -> unit
 
48
 
 
49
(*s Guard conditions for fix and cofix-points. *)
 
50
val check_fix : env -> fixpoint -> unit
 
51
val check_cofix : env -> cofixpoint -> unit
 
52
 
 
53
(*s Support for sort-polymorphic inductive types *)
 
54
 
 
55
val type_of_inductive_knowing_parameters :
 
56
  env -> one_inductive_body -> constr array -> constr
 
57
 
 
58
val max_inductive_sort : sorts array -> Univ.universe
 
59
 
 
60
val instantiate_universes : env -> rel_context ->
 
61
    polymorphic_arity -> constr array -> rel_context * sorts
 
62
 
 
63
(***************************************************************)
 
64
(* Debug *)
 
65
 
 
66
type size = Large | Strict
 
67
type subterm_spec =
 
68
    Subterm of (size * wf_paths)
 
69
  | Dead_code
 
70
  | Not_subterm
 
71
type guard_env =
 
72
  { env     : env;
 
73
    (* dB of last fixpoint *)
 
74
    rel_min : int;
 
75
    (* inductive of recarg of each fixpoint *)
 
76
    inds    : inductive array;
 
77
    (* the recarg information of inductive family *)
 
78
    recvec  : wf_paths array;
 
79
    (* dB of variables denoting subterms *)
 
80
    genv    : subterm_spec list;
 
81
  }
 
82
 
 
83
val subterm_specif : guard_env -> constr -> subterm_spec
 
84
val case_branches_specif : guard_env -> subterm_spec -> inductive ->
 
85
  constr array -> (guard_env * constr) array