HAT-TRANS

Section: User Commands (1)
Updated: local
Index Return to Main Contents
 

NAME

hat-trans - transform a Haskell module for tracing with the Hat system  

SYNOPSIS

hat-trans [-Idir]* [transopts] Mod.[l]hs ...  

DESCRIPTION

hat-trans is a batch tool for transforming a Haskell program into one which calculates its own trace. It transforms each source module Mod supplied as arguments. The modules may be ordinary source (.hs) or literate source (.lhs). The output is a transformed module, whose name is the original module name prefixed with "Hat.", and it is written to a file of similar name in the local subdirectory Hat/ (except that .lhs becomes .hs, because the literate part is stripped). If the subdirectory does not exist, it is created. The original source filename may include a directory path, in which case the transformed module is placed in an identical directory tree underneath the directory Hat/. This facilitates the easy transformation of modules within the hierarchical module namespace.

The resulting transformed modules can be compiled and linked in the normal way with your favorite Haskell compiler, with the addition of the option -package hat to its command-line.

Alternatively, rather than invoking hat-trans and a compiler by hand on your source files, but it is often more convenient to allow hmake(1) to invoke the tools automatically, especially because it also determines dependencies between modules and attempts to perform the minimum re-compilation necessary. Simple give the extra option "-hat" to hmake.

 

GENERAL OPTIONS

-Idir
Use the directory dir as an additional root when searching for imported modules.

 

TRANSFORMATION OPTIONS

The following options are available to change the usual transformation behaviour.
-unlit
Unliterate the source code. (Automatic if the file is .lhs)
-nounlit
Do not unliterate the source code. (Automatic if the file is .hs)
-underscore
Treat underscores strictly as lowercase (default).
-nounderscore
Treat underscores as invisible, e.g. _f is varid, _F is conid.
-prelude
Treat prelude definitions specially.
-noprelude
Do not treat definitions specially (default).
-trusted
Make this a "trusted" module.
-notrusted
Make this an "untrusted" module (default).
-showwidth=w
Set output width (in characters) to w (default=80).
-showindent=i
Set layout nesting indentation (in characters) to i (default=2).
-showqualified
Use fully qualified names in the output. This is off by default, because the output may refer to modules which are not explicitly imported.

 

EXAMINATION OPTIONS

The following options are available to examine the internal progress of the transformation.
-lex
Show input after lexical analysis.
-parse
Show syntax tree after parsing.
-tracefns
Show syntax tree after tracing translation.

 

FILES

/usr/local/bin/hat-trans

 

SEE ALSO

hmake(1), hat-detect(1), hat-observe(1), hat-trail(1), hat-stack(1)


 

Index

NAME
SYNOPSIS
DESCRIPTION
GENERAL OPTIONS
TRANSFORMATION OPTIONS
EXAMINATION OPTIONS
FILES
SEE ALSO

This document was created by man2html, using the manual pages.
Time: 16:04:58 GMT, July 03, 2003