hat-2.7.0.0: docs/hat-trans.html
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html><head><title>hat-trans reference guide</title></head>
<body bgcolor=#ffffff>
<table><tr><td width=500>
<center><h1>hat-trans reference guide</h1></center>
<hr>
<p>
<b>hat-trans</b> is a stand-alone program that performs a
source-to-source transformation on a single Haskell module, such
that the functions in the transformed module deposit traces in a
<em>.hat</em> file in addition to computing their original results.
<p>
The transformed module is written to a file of the same name as the
original, but in a directory called <tt>Hat</tt>. If the directory
does not exist, hat-trans creates it. If the module is part of the
hierarchical namespace, then a single <tt>Hat</tt> directory is created
at the root of the tree, and it is populated with new directories
corresponding to the remainder of the hierarchy. For instance, a
module called <tt>A.B.C</tt>, in a file named <tt>A/B/C.hs</tt>,
is transformed by hat-trans into a module called <tt>Hat.A.B.C</tt>,
stored in a file named <tt>Hat/A/B/C.hs</tt>.
</td></tr></table>
<table width=500>
<tr><td valign=top>
<p>
<b>File arguments.</b>
<table width=250><tr>
<td valign=top><em>.hs</em></td>
<td>Haskell source file</td>
</tr><tr>
<td valign=top><em>.lhs</em></td>
<td>literate Haskell source file</td>
</tr></table>
</td><td valign=top>
<p>
<b>Flags.</b>
<table width=250><tr>
<td valign=top><em><b>-I</b>dir</em></td>
<td>search directory <em>dir</em> for imported modules during transformation.
(hat-trans actually looks for the <em>.hx</em> file generated by a
prior invocation of hat-trans, rather than the source module itself.)</td>
</tr><tr>
<td valign=top><em><b>-P</b>dir</em></td>
<td>search directory <em>dir</em> for prelude and stdlib modules during
transformation</td>
</tr><tr>
<td valign=top><em><b>+RTS</b></em></td>
<td>the following options (up to <em><b>-RTS</b></em>) should be passed only
to hat-trans's runtime system
(for instance to increase its heap size for processing a large file)</td>
</tr></table>
</table>
<table width=500>
<tr><td valign=top>
<p>
<b>Options to change the usual transformation behaviour.</b>
<table width=250><tr>
<td valign=top><em><b>-unix</b></em></td>
<td>Use unix filenames (default)</td>
</tr><tr>
<td valign=top><em><b>-nounix</b></em></td>
<td>Use RiscOS filenames</td>
</tr><tr>
<td valign=top><em><b>-unlit</b></em></td>
<td>Unliterate the source code</td>
</tr><tr>
<td valign=top><em><b>-nounlit</b></em></td>
<td>Do not unliterate the source code (default)</td>
</tr><tr>
<td valign=top><em><b>-underscore</b></em></td>
<td>Treat underscores strictly as lowercase (default)</td>
</tr><tr>
<td valign=top><em><b>-nounderscore</b></em></td>
<td>Treat underscores as invisible, e.g. _f is varid, _F is conid</td>
</tr><tr>
<td valign=top><em><b>-prelude</b></em></td>
<td>Treat prelude definitions specially</td>
</tr><tr>
<td valign=top><em><b>-noprelude</b></em></td>
<td>Do not treat definitions specially (default)</td>
</tr><tr>
<td valign=top><em><b>-trusted</b></em></td>
<td>make this a "trusted" module</td>
</tr><tr>
<td valign=top><em><b>-notrusted</b></em></td>
<td>make this an "untrusted" module (default)</td>
</tr></table>
</td><td valign=top>
<p>
<b>Options to examine the internal progress of the transformation.</b>
<table width=250><tr>
<td valign=top><em>-<b>showwidth=</b>w</em></td>
<td>set width in characters of output of an intermediate syntax tree
to <em>w</em> (default=80)</td>
</tr><tr>
<td valign=top><em>-<b>showindent=</b>i</em></td>
<td>set indentation in characters for nesting of output of an intermediate
syntax tree to <em>i</em> (default=2)</td>
</tr><tr>
<td valign=top><em>-<b>showqualified</b></em></td>
<td>use qualified names in output of intermediate syntax tree
(default=on)</td>
</tr><tr>
<td valign=top><em><b>-lex</b></em></td>
<td>show lexical input</td>
</tr><tr>
<td valign=top><em><b>-parse</b></em></td>
<td>show syntax tree after parser</td>
</tr><tr>
<td valign=top><em><b>-tracefns</b></em></td>
<td>show syntax tree after tracing translation</td>
</tr></table>
</td></tr></table>
<table><tr><td width=500>
<hr>
<p>
This page last updated: 5th February 2003<br>
</td></tr></table>
</body></html>