mirror of
https://github.com/c-cube/ocaml-containers.git
synced 2025-12-06 03:05:28 -05:00
325 lines
No EOL
21 KiB
HTML
325 lines
No EOL
21 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
|
<html>
|
|
<head>
|
|
<link rel="stylesheet" href="style.css" type="text/css">
|
|
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
|
|
<link rel="Start" href="index.html">
|
|
<link rel="next" href="Containers_string.Parse.html">
|
|
<link rel="Up" href="Containers_string.html">
|
|
<link title="Index of types" rel=Appendix href="index_types.html">
|
|
<link title="Index of exceptions" rel=Appendix href="index_exceptions.html">
|
|
<link title="Index of values" rel=Appendix href="index_values.html">
|
|
<link title="Index of class methods" rel=Appendix href="index_methods.html">
|
|
<link title="Index of class types" rel=Appendix href="index_class_types.html">
|
|
<link title="Index of modules" rel=Appendix href="index_modules.html">
|
|
<link title="Index of module types" rel=Appendix href="index_module_types.html">
|
|
<link title="CCVector" rel="Chapter" href="CCVector.html">
|
|
<link title="CCPrint" rel="Chapter" href="CCPrint.html">
|
|
<link title="CCError" rel="Chapter" href="CCError.html">
|
|
<link title="CCHeap" rel="Chapter" href="CCHeap.html">
|
|
<link title="CCList" rel="Chapter" href="CCList.html">
|
|
<link title="CCOpt" rel="Chapter" href="CCOpt.html">
|
|
<link title="CCPair" rel="Chapter" href="CCPair.html">
|
|
<link title="CCFun" rel="Chapter" href="CCFun.html">
|
|
<link title="CCHash" rel="Chapter" href="CCHash.html">
|
|
<link title="CCInt" rel="Chapter" href="CCInt.html">
|
|
<link title="CCBool" rel="Chapter" href="CCBool.html">
|
|
<link title="CCFloat" rel="Chapter" href="CCFloat.html">
|
|
<link title="CCArray" rel="Chapter" href="CCArray.html">
|
|
<link title="CCRef" rel="Chapter" href="CCRef.html">
|
|
<link title="CCSet" rel="Chapter" href="CCSet.html">
|
|
<link title="CCOrd" rel="Chapter" href="CCOrd.html">
|
|
<link title="CCRandom" rel="Chapter" href="CCRandom.html">
|
|
<link title="CCString" rel="Chapter" href="CCString.html">
|
|
<link title="CCHashtbl" rel="Chapter" href="CCHashtbl.html">
|
|
<link title="CCMap" rel="Chapter" href="CCMap.html">
|
|
<link title="CCFormat" rel="Chapter" href="CCFormat.html">
|
|
<link title="CCIO" rel="Chapter" href="CCIO.html">
|
|
<link title="CCInt64" rel="Chapter" href="CCInt64.html">
|
|
<link title="CCChar" rel="Chapter" href="CCChar.html">
|
|
<link title="CCResult" rel="Chapter" href="CCResult.html">
|
|
<link title="Containers" rel="Chapter" href="Containers.html">
|
|
<link title="CCKTree" rel="Chapter" href="CCKTree.html">
|
|
<link title="CCKList" rel="Chapter" href="CCKList.html">
|
|
<link title="CCLazy_list" rel="Chapter" href="CCLazy_list.html">
|
|
<link title="CCMultiMap" rel="Chapter" href="CCMultiMap.html">
|
|
<link title="CCMultiSet" rel="Chapter" href="CCMultiSet.html">
|
|
<link title="CCTrie" rel="Chapter" href="CCTrie.html">
|
|
<link title="CCFlatHashtbl" rel="Chapter" href="CCFlatHashtbl.html">
|
|
<link title="CCCache" rel="Chapter" href="CCCache.html">
|
|
<link title="CCPersistentHashtbl" rel="Chapter" href="CCPersistentHashtbl.html">
|
|
<link title="CCDeque" rel="Chapter" href="CCDeque.html">
|
|
<link title="CCFQueue" rel="Chapter" href="CCFQueue.html">
|
|
<link title="CCBV" rel="Chapter" href="CCBV.html">
|
|
<link title="CCMixtbl" rel="Chapter" href="CCMixtbl.html">
|
|
<link title="CCMixmap" rel="Chapter" href="CCMixmap.html">
|
|
<link title="CCRingBuffer" rel="Chapter" href="CCRingBuffer.html">
|
|
<link title="CCIntMap" rel="Chapter" href="CCIntMap.html">
|
|
<link title="CCPersistentArray" rel="Chapter" href="CCPersistentArray.html">
|
|
<link title="CCMixset" rel="Chapter" href="CCMixset.html">
|
|
<link title="CCHashconsedSet" rel="Chapter" href="CCHashconsedSet.html">
|
|
<link title="CCGraph" rel="Chapter" href="CCGraph.html">
|
|
<link title="CCHashSet" rel="Chapter" href="CCHashSet.html">
|
|
<link title="CCBitField" rel="Chapter" href="CCBitField.html">
|
|
<link title="CCHashTrie" rel="Chapter" href="CCHashTrie.html">
|
|
<link title="CCBloom" rel="Chapter" href="CCBloom.html">
|
|
<link title="CCWBTree" rel="Chapter" href="CCWBTree.html">
|
|
<link title="CCRAL" rel="Chapter" href="CCRAL.html">
|
|
<link title="CCAllocCache" rel="Chapter" href="CCAllocCache.html">
|
|
<link title="CCImmutArray" rel="Chapter" href="CCImmutArray.html">
|
|
<link title="CCHet" rel="Chapter" href="CCHet.html">
|
|
<link title="Containers_string" rel="Chapter" href="Containers_string.html">
|
|
<link title="CCKMP" rel="Chapter" href="CCKMP.html">
|
|
<link title="CCLevenshtein" rel="Chapter" href="CCLevenshtein.html">
|
|
<link title="CCApp_parse" rel="Chapter" href="CCApp_parse.html">
|
|
<link title="CCParse" rel="Chapter" href="CCParse.html">
|
|
<link title="CCBigstring" rel="Chapter" href="CCBigstring.html">
|
|
<link title="CCArray1" rel="Chapter" href="CCArray1.html">
|
|
<link title="CCPool" rel="Chapter" href="CCPool.html">
|
|
<link title="CCLock" rel="Chapter" href="CCLock.html">
|
|
<link title="CCSemaphore" rel="Chapter" href="CCSemaphore.html">
|
|
<link title="CCThread" rel="Chapter" href="CCThread.html">
|
|
<link title="CCBlockingQueue" rel="Chapter" href="CCBlockingQueue.html">
|
|
<link title="CCTimer" rel="Chapter" href="CCTimer.html">
|
|
<link title="Containers_advanced" rel="Chapter" href="Containers_advanced.html">
|
|
<link title="CCLinq" rel="Chapter" href="CCLinq.html">
|
|
<link title="CCBatch" rel="Chapter" href="CCBatch.html">
|
|
<link title="CCCat" rel="Chapter" href="CCCat.html">
|
|
<link title="CCMonadIO" rel="Chapter" href="CCMonadIO.html">
|
|
<link title="Containers_io_is_deprecated" rel="Chapter" href="Containers_io_is_deprecated.html">
|
|
<link title="CCUnix" rel="Chapter" href="CCUnix.html">
|
|
<link title="CCSexp" rel="Chapter" href="CCSexp.html">
|
|
<link title="CCSexpM" rel="Chapter" href="CCSexpM.html"><link title="Signatures" rel="Section" href="#2_Signatures">
|
|
<link title="Signatures" rel="Section" href="#2_Signatures">
|
|
<link title="Parse" rel="Section" href="#2_Parse">
|
|
<link title="Low-level interface" rel="Section" href="#2_Lowlevelinterface">
|
|
<link title="Defaults" rel="Section" href="#2_Defaults">
|
|
<link title="Combinators" rel="Subsection" href="#6_Combinators">
|
|
<link title="Parsing" rel="Subsection" href="#6_Parsing">
|
|
<title>Containers doc : Containers_string.App_parse</title>
|
|
</head>
|
|
<body>
|
|
<div class="navbar"> <a class="up" href="Containers_string.html" title="Containers_string">Up</a>
|
|
<a class="post" href="Containers_string.Parse.html" title="Containers_string.Parse">Next</a>
|
|
</div>
|
|
<h1>Module <a href="type_Containers_string.App_parse.html">Containers_string.App_parse</a></h1>
|
|
|
|
<pre><span class="keyword">module</span> App_parse: <code class="type"><a href="CCApp_parse.html">CCApp_parse</a></code></pre><hr width="100%">
|
|
|
|
<pre><span id="TYPEresult"><span class="keyword">type</span> <code class="type">('a, 'b)</code> result</span> = <code class="type">[ `Error of 'b | `Ok of 'a ]</code> </pre>
|
|
|
|
|
|
<pre><span id="TYPEt"><span class="keyword">type</span> <code class="type">'a</code> t</span> </pre>
|
|
<div class="info ">
|
|
Parser that yields an error or a value of type 'a<br>
|
|
</div>
|
|
|
|
<br>
|
|
<h6 id="6_Combinators">Combinators</h6><br>
|
|
|
|
<pre><span id="VALreturn"><span class="keyword">val</span> return</span> : <code class="type">'a -> 'a <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
Parser that succeeds with the given value<br>
|
|
</div>
|
|
|
|
<pre><span id="VALpure"><span class="keyword">val</span> pure</span> : <code class="type">'a -> 'a <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
Synonym to <a href="CCApp_parse.html#VALreturn"><code class="code"><span class="constructor">CCApp_parse</span>.return</code></a><br>
|
|
</div>
|
|
|
|
<pre><span id="VALjunk"><span class="keyword">val</span> junk</span> : <code class="type">unit <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
Skip next char<br>
|
|
</div>
|
|
|
|
<pre><span id="VALfail"><span class="keyword">val</span> fail</span> : <code class="type">string -> 'a <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
<code class="code">fail msg</code> fails with the given error message<br>
|
|
</div>
|
|
|
|
<pre><span id="VALfailf"><span class="keyword">val</span> failf</span> : <code class="type">('a, unit, string, 'b <a href="CCApp_parse.html#TYPEt">t</a>) Pervasives.format4 -> 'a</code></pre>
|
|
<pre><span id="VALapp"><span class="keyword">val</span> app</span> : <code class="type">('a -> 'b) <a href="CCApp_parse.html#TYPEt">t</a> -> 'a <a href="CCApp_parse.html#TYPEt">t</a> -> 'b <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
Applicative<br>
|
|
</div>
|
|
|
|
<pre><span id="VALmap"><span class="keyword">val</span> map</span> : <code class="type">('a -> 'b) -> 'a <a href="CCApp_parse.html#TYPEt">t</a> -> 'b <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
Map the parsed value<br>
|
|
</div>
|
|
|
|
<pre><span id="VALint"><span class="keyword">val</span> int</span> : <code class="type">int <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
Parse an integer<br>
|
|
</div>
|
|
|
|
<pre><span id="VALfloat"><span class="keyword">val</span> float</span> : <code class="type">float <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
Parse a floating point number<br>
|
|
</div>
|
|
|
|
<pre><span id="VALbool"><span class="keyword">val</span> bool</span> : <code class="type">bool <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
Parse "true" or "false"<br>
|
|
</div>
|
|
|
|
<pre><span id="VALchar"><span class="keyword">val</span> char</span> : <code class="type">char -> char <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
<code class="code">char c</code> parses <code class="code">c</code> and <code class="code">c</code> only<br>
|
|
</div>
|
|
|
|
<pre><span id="VALany_of"><span class="keyword">val</span> any_of</span> : <code class="type">string -> char <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
Parse any of the chars present in the given string<br>
|
|
</div>
|
|
|
|
<pre><span id="VALalpha_lower"><span class="keyword">val</span> alpha_lower</span> : <code class="type">char <a href="CCApp_parse.html#TYPEt">t</a></code></pre>
|
|
<pre><span id="VALalpha_upper"><span class="keyword">val</span> alpha_upper</span> : <code class="type">char <a href="CCApp_parse.html#TYPEt">t</a></code></pre>
|
|
<pre><span id="VALalpha"><span class="keyword">val</span> alpha</span> : <code class="type">char <a href="CCApp_parse.html#TYPEt">t</a></code></pre>
|
|
<pre><span id="VALsymbols"><span class="keyword">val</span> symbols</span> : <code class="type">char <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
Symbols, such as "!-=_"...<br>
|
|
</div>
|
|
|
|
<pre><span id="VALnum"><span class="keyword">val</span> num</span> : <code class="type">char <a href="CCApp_parse.html#TYPEt">t</a></code></pre>
|
|
<pre><span id="VALalpha_num"><span class="keyword">val</span> alpha_num</span> : <code class="type">char <a href="CCApp_parse.html#TYPEt">t</a></code></pre>
|
|
<pre><span id="VALword"><span class="keyword">val</span> word</span> : <code class="type">string <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
<code class="code">word</code> parses any identifier not starting with an integer and
|
|
not containing any whitespace nor delimiter
|
|
TODO: specify<br>
|
|
</div>
|
|
|
|
<pre><span id="VALquoted"><span class="keyword">val</span> quoted</span> : <code class="type">string <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
Quoted string, following OCaml conventions<br>
|
|
</div>
|
|
|
|
<pre><span id="VALstr_of_l"><span class="keyword">val</span> str_of_l</span> : <code class="type">char list -> string</code></pre><div class="info ">
|
|
Helper to build strings from lists of chars<br>
|
|
</div>
|
|
|
|
<pre><span id="VALspaces"><span class="keyword">val</span> spaces</span> : <code class="type">unit <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
Parse a sequence of <code class="code"><span class="string">'\t'</span></code> and <code class="code"><span class="string">' '</span></code><br>
|
|
</div>
|
|
|
|
<pre><span id="VALspaces1"><span class="keyword">val</span> spaces1</span> : <code class="type">unit <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
Same as <a href="CCApp_parse.html#VALspaces"><code class="code"><span class="constructor">CCApp_parse</span>.spaces</code></a> but requires at least one space<br>
|
|
</div>
|
|
|
|
<pre><span id="VALwhite"><span class="keyword">val</span> white</span> : <code class="type">unit <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
Parse a sequence of <code class="code"><span class="string">'\t'</span></code>, <code class="code"><span class="string">'\n'</span></code> and <code class="code"><span class="string">' '</span></code><br>
|
|
</div>
|
|
|
|
<pre><span id="VALwhite1"><span class="keyword">val</span> white1</span> : <code class="type">unit <a href="CCApp_parse.html#TYPEt">t</a></code></pre>
|
|
<pre><span id="VALeof"><span class="keyword">val</span> eof</span> : <code class="type">unit <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
Matches the end of input, fails otherwise<br>
|
|
</div>
|
|
|
|
<pre><span id="VALmany"><span class="keyword">val</span> many</span> : <code class="type">?sep:unit <a href="CCApp_parse.html#TYPEt">t</a> -> 'a <a href="CCApp_parse.html#TYPEt">t</a> -> 'a list <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
0 or more parsed elements of the given type.<br>
|
|
</div>
|
|
<div class="param_info"><code class="code">sep</code> : separator between elements of the list (for instance, <code class="code">space</code>)</div>
|
|
|
|
<pre><span id="VALmany1"><span class="keyword">val</span> many1</span> : <code class="type">?sep:unit <a href="CCApp_parse.html#TYPEt">t</a> -> 'a <a href="CCApp_parse.html#TYPEt">t</a> -> 'a list <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
Same as <a href="CCApp_parse.html#VALmany"><code class="code"><span class="constructor">CCApp_parse</span>.many</code></a>, but needs at least one element<br>
|
|
</div>
|
|
|
|
<pre><span id="VALskip"><span class="keyword">val</span> skip</span> : <code class="type">'a <a href="CCApp_parse.html#TYPEt">t</a> -> unit <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
Skip 0 or more instances of the given parser<br>
|
|
</div>
|
|
|
|
<pre><span id="VALskip1"><span class="keyword">val</span> skip1</span> : <code class="type">'a <a href="CCApp_parse.html#TYPEt">t</a> -> unit <a href="CCApp_parse.html#TYPEt">t</a></code></pre>
|
|
<pre><span id="VALopt"><span class="keyword">val</span> opt</span> : <code class="type">'a <a href="CCApp_parse.html#TYPEt">t</a> -> 'a option <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
<code class="code">opt x</code> tries to parse <code class="code">x</code>, and returns <code class="code"><span class="constructor">None</span></code> otherwise<br>
|
|
</div>
|
|
|
|
<pre><span id="VALfilter"><span class="keyword">val</span> filter</span> : <code class="type">('a -> bool) -> 'a <a href="CCApp_parse.html#TYPEt">t</a> -> 'a <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
<code class="code">filter f p</code> parses the same as <code class="code">p</code>, but fails if the returned value
|
|
does not satisfy <code class="code">f</code><br>
|
|
</div>
|
|
|
|
<pre><span id="VALswitch_c"><span class="keyword">val</span> switch_c</span> : <code class="type">?default:'a <a href="CCApp_parse.html#TYPEt">t</a> -><br> (char * 'a <a href="CCApp_parse.html#TYPEt">t</a>) list -> 'a <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
<code class="code">switch_c l</code> matches the next char and uses the corresponding parser.
|
|
Fails if the next char is not in the list, unless default is defined.<br>
|
|
<b>Raises</b> <code>Invalid_argument</code> if some char occurs several times in <code class="code">l</code><br>
|
|
</div>
|
|
<div class="param_info"><code class="code">default</code> : parser to use if no char matches</div>
|
|
|
|
<pre><span id="VALswitch_s"><span class="keyword">val</span> switch_s</span> : <code class="type">(string * 'a <a href="CCApp_parse.html#TYPEt">t</a>) list -> 'a <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
<code class="code">switch_s l</code> attempts to match matches any of the strings in <code class="code">l</code>.
|
|
If one of those strings matches, the corresponding parser
|
|
is used from now on.<br>
|
|
<b>Raises</b> <code>Invalid_argument</code> if some string is a prefix of another string,
|
|
or is empty, or if the list is empty<br>
|
|
</div>
|
|
|
|
<pre><span id="VALchoice"><span class="keyword">val</span> choice</span> : <code class="type">'a <a href="CCApp_parse.html#TYPEt">t</a> list -> 'a <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
<code class="code">choice l</code> chooses between the parsers, unambiguously<br>
|
|
<b>Raises</b> <code>Invalid_argument</code> if the list is empty, or if some parsers
|
|
overlap, making the choice ambiguous<br>
|
|
</div>
|
|
|
|
<pre><span id="VALfix"><span class="keyword">val</span> fix</span> : <code class="type">('a <a href="CCApp_parse.html#TYPEt">t</a> -> 'a <a href="CCApp_parse.html#TYPEt">t</a>) -> 'a <a href="CCApp_parse.html#TYPEt">t</a></code></pre><div class="info ">
|
|
<code class="code">fix f</code> makes a fixpoint<br>
|
|
</div>
|
|
|
|
<pre><span class="keyword">module</span> <a href="CCApp_parse.Infix.html">Infix</a>: <code class="code"><span class="keyword">sig</span></code> <a href="CCApp_parse.Infix.html">..</a> <code class="code"><span class="keyword">end</span></code></pre>
|
|
<pre><span class="keyword">include</span> <a href="CCApp_parse.Infix.html">CCApp_parse.Infix</a></pre>
|
|
<br>
|
|
<h2 id="2_Signatures">Signatures</h2><br>
|
|
<br>
|
|
<h2 id="2_Signatures">Signatures</h2><br>
|
|
<br>
|
|
<h6 id="6_Parsing">Parsing</h6><br>
|
|
|
|
<pre><code><span id="TYPEerror"><span class="keyword">type</span> <code class="type"></code>error</span> = {</code></pre><table class="typetable">
|
|
<tr>
|
|
<td align="left" valign="top" >
|
|
<code> </code></td>
|
|
<td align="left" valign="top" >
|
|
<code><span id="TYPEELTerror.line">line</span> : <code class="type">int</code>;</code></td>
|
|
|
|
</tr>
|
|
<tr>
|
|
<td align="left" valign="top" >
|
|
<code> </code></td>
|
|
<td align="left" valign="top" >
|
|
<code><span id="TYPEELTerror.col">col</span> : <code class="type">int</code>;</code></td>
|
|
|
|
</tr>
|
|
<tr>
|
|
<td align="left" valign="top" >
|
|
<code> </code></td>
|
|
<td align="left" valign="top" >
|
|
<code><span id="TYPEELTerror.msg">msg</span> : <code class="type">string</code>;</code></td>
|
|
|
|
</tr></table>
|
|
}
|
|
|
|
|
|
|
|
<pre><span id="VALstring_of_error"><span class="keyword">val</span> string_of_error</span> : <code class="type"><a href="CCApp_parse.html#TYPEerror">error</a> -> string</code></pre>
|
|
<pre><span id="EXCEPTIONError"><span class="keyword">exception</span> Error</span> <span class="keyword">of</span> <code class="type"><a href="CCApp_parse.html#TYPEerror">error</a></code></pre>
|
|
|
|
<pre><span class="keyword">module type</span> <a href="CCApp_parse.S.html">S</a> = <code class="code"><span class="keyword">sig</span></code> <a href="CCApp_parse.S.html">..</a> <code class="code"><span class="keyword">end</span></code></pre><br>
|
|
<h2 id="2_Parse">Parse</h2><br>
|
|
|
|
<pre><span class="keyword">module type</span> <a href="CCApp_parse.INPUT.html">INPUT</a> = <code class="code"><span class="keyword">sig</span></code> <a href="CCApp_parse.INPUT.html">..</a> <code class="code"><span class="keyword">end</span></code></pre>
|
|
<pre><span class="keyword">module</span> <a href="CCApp_parse.Make.html">Make</a> <code class="code">(</code><code class="code"><span class="constructor">I</span></code><code class="code"> : </code><code class="type"><a href="CCApp_parse.INPUT.html">INPUT</a></code><code class="code">) </code>: <code class="type"><a href="CCApp_parse.S.html">S</a></code><code class="type"> with type source = I.t</code></pre><br>
|
|
<h2 id="2_Lowlevelinterface">Low-level interface</h2><br>
|
|
|
|
<pre><span id="VALprint"><span class="keyword">val</span> print</span> : <code class="type">Format.formatter -> 'a <a href="CCApp_parse.html#TYPEt">t</a> -> unit</code></pre><div class="info ">
|
|
Print a parser structure, for debug purpose<br>
|
|
</div>
|
|
|
|
<pre><code><span id="TYPEtoken"><span class="keyword">type</span> <code class="type"></code>token</span> = </code></pre><table class="typetable">
|
|
<tr>
|
|
<td align="left" valign="top" >
|
|
<code><span class="keyword">|</span></code></td>
|
|
<td align="left" valign="top" >
|
|
<code><span id="TYPEELTtoken.Yield"><span class="constructor">Yield</span></span> <span class="keyword">of</span> <code class="type">char</code></code></td>
|
|
|
|
</tr>
|
|
<tr>
|
|
<td align="left" valign="top" >
|
|
<code><span class="keyword">|</span></code></td>
|
|
<td align="left" valign="top" >
|
|
<code><span id="TYPEELTtoken.EOF"><span class="constructor">EOF</span></span></code></td>
|
|
|
|
</tr></table>
|
|
|
|
|
|
|
|
<pre><span class="keyword">module type</span> <a href="CCApp_parse.READER.html">READER</a> = <code class="code"><span class="keyword">sig</span></code> <a href="CCApp_parse.READER.html">..</a> <code class="code"><span class="keyword">end</span></code></pre>
|
|
<pre><span class="keyword">module</span> <a href="CCApp_parse.MakeFromReader.html">MakeFromReader</a> <code class="code">(</code><code class="code"><span class="constructor">R</span></code><code class="code"> : </code><code class="type"><a href="CCApp_parse.READER.html">READER</a></code><code class="code">) </code>: <code class="type"><a href="CCApp_parse.S.html">S</a></code><code class="type"> with type source = R.source</code></pre><br>
|
|
<h2 id="2_Defaults">Defaults</h2><br>
|
|
|
|
<pre><span class="keyword">module</span> <a href="CCApp_parse.Str.html">Str</a>: <code class="type"><a href="CCApp_parse.S.html">S</a></code><code class="type"> with type source = string</code></pre>
|
|
<pre><span class="keyword">module</span> <a href="CCApp_parse.Chan.html">Chan</a>: <code class="type"><a href="CCApp_parse.S.html">S</a></code><code class="type"> with type source = in_channel</code></pre></body></html> |