]> matita.cs.unibo.it Git - helm.git/blob - helm/software/lambda-delta/src/common/options.ml
d9783c76623a62fcfa28d2f8b738c03d433df709
[helm.git] / helm / software / lambda-delta / src / common / options.ml
1 (*
2     ||M||  This file is part of HELM, an Hypertextual, Electronic        
3     ||A||  Library of Mathematics, developed at the Computer Science     
4     ||T||  Department, University of Bologna, Italy.                     
5     ||I||                                                                
6     ||T||  HELM is free software; you can redistribute it and/or         
7     ||A||  modify it under the terms of the GNU General Public License   
8     \   /  version 2 or (at your option) any later version.              
9      \ /   This software is distributed as is, NO WARRANTY.              
10       V_______________________________________________________________ *)
11
12 module C = Cps
13
14 type uri_generator = string -> string
15
16 (* interface functions ******************************************************)
17
18 let indexes = ref false      (* show de Bruijn indexes *)
19
20 let expand = ref false       (* always expand global definitions *)
21
22 let si = ref false           (* use sort inclusion *)
23
24 let unquote = ref false      (* do not quote identifiers when lexing *)
25
26 let icm = ref 0              (* complexity measure of relocated terms *)
27
28 let cover = ref ""           (* initial uri segment *)
29
30 let debug_parser = ref false (* output parser debug information *)
31
32 let debug_lexer = ref false  (* output lexer debug information *)
33
34 let mk_uri = ref (fun _ _ -> C.err : bool -> string -> uri_generator) 
35
36 let get_mk_uri () =
37    !mk_uri !si !cover
38
39 let clear () =
40    expand := false; si := false; cover := ""; indexes := false; icm := 0;
41    debug_parser := false; debug_lexer := false;
42    mk_uri := fun _ _ -> C.err