249 lines
3.1 KiB
HTML
249 lines
3.1 KiB
HTML
|
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
|
<HTML><HEAD><TITLE>Man page of Pparse</TITLE>
|
|
</HEAD><BODY>
|
|
<H1>Pparse</H1>
|
|
Section: OCaml library (3o)<BR>Updated: 2020-01-30<BR><A HREF="#index">Index</A>
|
|
<A HREF="/cgi-bin/man/man2html">Return to Main Contents</A><HR>
|
|
|
|
<A NAME="lbAB"> </A>
|
|
<H2>NAME</H2>
|
|
|
|
Pparse - Driver for the parser, external preprocessors and ast plugin hooks
|
|
<A NAME="lbAC"> </A>
|
|
<H2>Module</H2>
|
|
|
|
Module Pparse
|
|
<A NAME="lbAD"> </A>
|
|
<H2>Documentation</H2>
|
|
|
|
<P>
|
|
Module
|
|
<B>Pparse</B>
|
|
|
|
<BR> :
|
|
<B>sig end</B>
|
|
|
|
<P>
|
|
<P>
|
|
Driver for the parser, external preprocessors and ast plugin hooks
|
|
<P>
|
|
Warning: this module is unstable and part of
|
|
<B>Compiler_libs</B>
|
|
|
|
.
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<I>type error </I>
|
|
|
|
=
|
|
<BR> | CannotRun
|
|
<B>of </B>
|
|
|
|
<B>string</B>
|
|
|
|
<BR> | WrongMagic
|
|
<B>of </B>
|
|
|
|
<B>string</B>
|
|
|
|
<BR>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<I>exception Error </I>
|
|
|
|
<B>of </B>
|
|
|
|
<B>error</B>
|
|
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<I>val preprocess </I>
|
|
|
|
:
|
|
<B>string -> string</B>
|
|
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<I>val remove_preprocessed </I>
|
|
|
|
:
|
|
<B>string -> unit</B>
|
|
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<I>type </I>
|
|
|
|
<B>'a</B>
|
|
|
|
<I>ast_kind </I>
|
|
|
|
=
|
|
<BR> | Structure
|
|
<B>: </B>
|
|
|
|
<B>Parsetree.structure ast_kind</B>
|
|
|
|
<BR> | Signature
|
|
<B>: </B>
|
|
|
|
<B>Parsetree.signature ast_kind</B>
|
|
|
|
<BR>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<I>val read_ast </I>
|
|
|
|
:
|
|
<B>'a ast_kind -> string -> 'a</B>
|
|
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<I>val write_ast </I>
|
|
|
|
:
|
|
<B>'a ast_kind -> string -> 'a -> unit</B>
|
|
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<I>val file </I>
|
|
|
|
:
|
|
<B>tool_name:string -></B>
|
|
|
|
<B>string -> (Lexing.lexbuf -> 'a) -> 'a ast_kind -> 'a</B>
|
|
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<I>val apply_rewriters </I>
|
|
|
|
:
|
|
<B>?restore:bool -> tool_name:string -> 'a ast_kind -> 'a -> 'a</B>
|
|
|
|
<P>
|
|
If
|
|
<B>restore = true</B>
|
|
|
|
(the default), cookies set by external
|
|
rewriters will be kept for later calls.
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<I>val apply_rewriters_str </I>
|
|
|
|
:
|
|
<B>?restore:bool -></B>
|
|
|
|
<B>tool_name:string -> Parsetree.structure -> Parsetree.structure</B>
|
|
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<I>val apply_rewriters_sig </I>
|
|
|
|
:
|
|
<B>?restore:bool -></B>
|
|
|
|
<B>tool_name:string -> Parsetree.signature -> Parsetree.signature</B>
|
|
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<I>val report_error </I>
|
|
|
|
:
|
|
<B>Format.formatter -> error -> unit</B>
|
|
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<I>val parse_implementation </I>
|
|
|
|
:
|
|
<B>tool_name:string -> string -> Parsetree.structure</B>
|
|
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<I>val parse_interface </I>
|
|
|
|
:
|
|
<B>tool_name:string -> string -> Parsetree.signature</B>
|
|
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<I>val call_external_preprocessor </I>
|
|
|
|
:
|
|
<B>string -> string -> string</B>
|
|
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<I>val open_and_check_magic </I>
|
|
|
|
:
|
|
<B>string -> string -> in_channel * bool</B>
|
|
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<I>module ImplementationHooks : </I>
|
|
|
|
<B>sig end</B>
|
|
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<I>module InterfaceHooks : </I>
|
|
|
|
<B>sig end</B>
|
|
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
<P>
|
|
|
|
<HR>
|
|
<A NAME="index"> </A><H2>Index</H2>
|
|
<DL>
|
|
<DT id="1"><A HREF="#lbAB">NAME</A><DD>
|
|
<DT id="2"><A HREF="#lbAC">Module</A><DD>
|
|
<DT id="3"><A HREF="#lbAD">Documentation</A><DD>
|
|
</DL>
|
|
<HR>
|
|
This document was created by
|
|
<A HREF="/cgi-bin/man/man2html">man2html</A>,
|
|
using the manual pages.<BR>
|
|
Time: 00:05:52 GMT, March 31, 2021
|
|
</BODY>
|
|
</HTML>
|