Module Search
Search facilities.
type glob_search_about_item=|GlobSearchSubPattern of Pattern.constr_pattern|GlobSearchString of stringtype filter_function= Names.GlobRef.t -> Environ.env -> Constr.constr -> booltype display_function= Names.GlobRef.t -> Environ.env -> Constr.constr -> unit
Generic filter functions
val blacklist_filter : filter_functionCheck whether a reference is blacklisted.
val module_filter : (Names.DirPath.t list * bool) -> filter_functionCheck whether a reference pertains or not to a set of modules
val search_about_filter : glob_search_about_item -> filter_functionCheck whether a reference matches a SearchAbout query.
Specialized search functions
search_xxx gl pattern modinout searches the hypothesis of the glth goal and the global environment for things matching pattern and satisfying module exclude/include clauses of modinout.
val search_by_head : ?pstate:Proof_global.t -> int option -> Pattern.constr_pattern -> (Names.DirPath.t list * bool) -> display_function -> unitval search_rewrite : ?pstate:Proof_global.t -> int option -> Pattern.constr_pattern -> (Names.DirPath.t list * bool) -> display_function -> unitval search_pattern : ?pstate:Proof_global.t -> int option -> Pattern.constr_pattern -> (Names.DirPath.t list * bool) -> display_function -> unitval search_about : ?pstate:Proof_global.t -> int option -> (bool * glob_search_about_item) list -> (Names.DirPath.t list * bool) -> display_function -> unit
type search_constraint=|Name_Pattern of Str.regexpWhether the name satisfies a regexp (uses Ocaml Str syntax)
|Type_Pattern of Pattern.constr_patternWhether the object type satisfies a pattern
|SubType_Pattern of Pattern.constr_patternWhether some subtype of object type satisfies a pattern
|In_Module of Names.DirPath.tWhether the object pertains to a module
|Include_BlacklistBypass the Search blacklist
type 'a coq_object={coq_object_prefix : string list;coq_object_qualid : string list;coq_object_object : 'a;}
val interface_search : ?pstate:Proof_global.t -> ?glnum:int -> (search_constraint * bool) list -> Constr.constr coq_object list
Generic search function
val generic_search : ?pstate:Proof_global.t -> int option -> display_function -> unitThis function iterates over all hypothesis of the goal numbered
glnum(if present) and all known declarations.
Search function modifiers
val prioritize_search : (display_function -> unit) -> display_function -> unitprioritize_search iteriterates over the values ofiter(seen as a sequence of declarations), in a relevance order. This requires to perform the entire iteration ofiterbefore starting streaming. Soprioritize_searchshould not be used for low-latency streaming.