Skip to content
This repository
Newer
Older
100644 53 lines (44 sloc) 2.049 kb
fccc6851 » MLstate
2011-06-21 Initial open-source release
1 (*
2 Copyright © 2011 MLstate
3
4 This file is part of OPA.
5
6 OPA is free software: you can redistribute it and/or modify it under the
7 terms of the GNU Affero General Public License, version 3, as published by
8 the Free Software Foundation.
9
10 OPA is distributed in the hope that it will be useful, but WITHOUT ANY
11 WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
12 FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for
13 more details.
14
15 You should have received a copy of the GNU Affero General Public License
16 along with OPA. If not, see <http://www.gnu.org/licenses/>.
17 *)
18 (**
19 A family of pretty-printers for the OPA AST.
20 *)
21 type 'ident printer =
22 <
6e9d74e3 » BourgerieQuentin
2011-11-22 [feature] syntax: js-like printer first draft
23 code : 'dir. ('ident, [< SurfaceAst.all_directives ] as 'dir) SurfaceAst.code LangPrint.pprinter;
fccc6851 » MLstate
2011-06-21 Initial open-source release
24 code_elt : 'dir. ('ident, [< SurfaceAst.all_directives ] as 'dir) SurfaceAst.code_elt LangPrint.pprinter;
25 code_elt_node : 'dir. ('ident, [< SurfaceAst.all_directives ] as 'dir) SurfaceAst.code_elt_node LangPrint.pprinter;
26 expr : 'dir. ('ident, [< SurfaceAst.all_directives ] as 'dir) SurfaceAst.expr LangPrint.pprinter;
27 ty : 'ident SurfaceAst.ty LangPrint.pprinter;
28 directive : 'dir. ('ident,[< SurfaceAst.all_directives ] as 'dir) SurfaceAst.directive LangPrint.pprinter;
29 variant : 'dir. ([< SurfaceAst.all_directives ] as 'dir) LangPrint.pprinter;
30 typevar : 'ident SurfaceAst.typevar LangPrint.pprinter;
31 typeident : 'ident SurfaceAst.typeident LangPrint.pprinter;
32 ident : 'ident LangPrint.pprinter;
1011bc01 » OpaOnWindowsNow
2011-12-20 [feature] js-like,pretty-printer: some enhancements, mostly unfinished
33 keyword : string -> bool
fccc6851 » MLstate
2011-06-21 Initial open-source release
34 >
35
6e9d74e3 » BourgerieQuentin
2011-11-22 [feature] syntax: js-like printer first draft
36 module type Familly = sig
37 val string : string printer
38 val string_and_pos : string printer
39 val ident : Ident.t printer
40 val readable_ident : Ident.t printer
41 val full_ident : Ident.t printer
42 end
43
44 val makeFamilly : OpaSyntax.t -> (module Familly)
45
46 val getDefaultFamilly : unit -> (module Familly)
47
48
fccc6851 » MLstate
2011-06-21 Initial open-source release
49 val string : string printer
50 val string_and_pos : string printer
51 val ident : Ident.t printer
52 val readable_ident : Ident.t printer
53 val full_ident : Ident.t printer
Something went wrong with that request. Please try again.