Debian Codegraph @

vernac/prettyp.mli

raw symbols SCIP
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 Names
12 open Environ
13 open Libnames
14
15 (** This module implements Print/About/Locate commands *)
16
17 val assumptions_for_print : Name.t list -> Termops.names_context (* unused? *)
18
19 val print_closed_sections : bool ref
20 val print_context (* unused? *)
21 : env
22 -> Evd.evar_map
23 -> with_values:Global.indirect_accessor option -> int option -> 'a Lib.library_segment -> Pp.t
24 val print_library_leaf
25 : env
26 -> Evd.evar_map
27 -> with_values:Global.indirect_accessor option
28 -> ModPath.t
29 -> Libobject.t
30 -> Pp.t option
31 val print_library_node : Summary.Interp.frozen Lib.node -> Pp.t (* unused? *)
32 val print_full_context : Global.indirect_accessor -> env -> Evd.evar_map -> Pp.t
33 val print_full_context_typ : env -> Evd.evar_map -> Pp.t
34
35 val print_full_pure_context : Global.indirect_accessor -> env -> Evd.evar_map -> Pp.t
36
37 val print_sec_context : Global.indirect_accessor -> env -> Evd.evar_map -> qualid -> Pp.t
38 val print_sec_context_typ : env -> Evd.evar_map -> qualid -> Pp.t
39 val print_judgment : env -> Evd.evar_map -> EConstr.unsafe_judgment -> Pp.t
40 val print_safe_judgment : Safe_typing.judgment -> Pp.t
41
42 val print_name : Global.indirect_accessor -> env -> Evd.evar_map
43 -> qualid Constrexpr.or_by_notation
44 -> UnivNames.full_name_list option
45 -> Pp.t
46 val print_notation : env -> Evd.evar_map
47 -> qualid Constrexpr.notation_entry_gen
48 -> string
49 -> Pp.t
50
51 val print_abbreviation : Global.indirect_accessor -> env -> Evd.evar_map -> KerName.t -> Pp.t
52
53 val print_about : env -> Evd.evar_map -> qualid Constrexpr.or_by_notation ->
54 UnivNames.full_name_list option -> Pp.t
55 val print_impargs : env -> GlobRef.t -> Pp.t
56
57 (** Pretty-printing functions for classes and coercions *)
58 val print_graph : unit -> Pp.t
59 val print_classes : unit -> Pp.t
60 val print_coercions : unit -> Pp.t
61 val print_coercion_paths : Coercionops.cl_typ -> Coercionops.cl_typ -> Pp.t
62 val print_canonical_projections : env -> Evd.evar_map -> GlobRef.t list -> Pp.t
63
64 (** Pretty-printing functions for type classes and instances *)
65 val print_typeclasses : unit -> Pp.t
66 val print_instances : GlobRef.t -> Pp.t
67 val print_all_instances : unit -> Pp.t
68
69 val inspect : env -> Evd.evar_map -> int -> Pp.t
70
71 (** {5 Locate} *)
72
73 type 'a locatable_info = {
74 locate : qualid -> 'a option;
75 (** Locate the most precise object with the provided name if any. *)
76 locate_all : qualid -> 'a list;
77 (** Locate all objects whose name is a suffix of the provided name *)
78 shortest_qualid : 'a -> qualid;
79 (** Return the shortest name in the current context *)
80 name : 'a -> Pp.t;
81 (** Data as printed by the Locate command *)
82 print : 'a -> Pp.t;
83 (** Data as printed by the Print command *)
84 about : 'a -> Pp.t;
85 (** Data as printed by the About command *)
86 }
87 (** Generic data structure representing locatable objects. *)
88
89 val register_locatable : string -> 'a locatable_info -> unit
90 (** Define a new type of locatable objects that can be reached via the
91 corresponding generic vernacular commands. The string should be a unique
92 name describing the kind of objects considered and that is added as a
93 grammar command prefix for vernacular commands Locate. *)
94
95 val print_located_qualid : env -> qualid -> Pp.t
96 val print_located_term : env -> qualid -> Pp.t
97 val print_located_module : env -> qualid -> Pp.t
98 val print_located_other : env -> string -> qualid -> Pp.t