disp1
Tdf pretty printer
Usage
disp [options]
input-file
[output-file]
Overview
disp translates the input TDF capsule, input-file into a human-readable form, the layout of which reflects the structure of the underlying TDF tree. If the output-file argument is present, this is used for output; otherwise the standard output is used.
Whenever possible the output of disp matches the TDF specification. The most important exception is the use of asterisks after a token name to indicate an application of that token. Also a dash is used to indicate the absense of an optional argument and an ellipsis (...) is used to indicate that a token's arguments have been skipped rather than decoded (since the token was undeclared).
It is recommended that disp is invoked via tcc(1) using the -disp or the -disp_t option. The -opt flag can be passed to disp by passing the flag -Wd,-opt to tcc.
Options
-
-g -
Makes
dispprint any diagnostic information units within the TDF capsule.
-
-ncolumns -
Makes
disptry to format its output to fit into a page width of columns. The default page width is 80.
-
-q -
Makes
dispignore the specified page width and print its output with the minimum possible indentation. This makes it run faster, but does not make the best use of the available page width.
-
-r -
Makes
dispcontinue after any errors. The use of this flag is not recommended since anything read after an error is likely to be of very little value.
-
-v -
Makes
dispprint its version number and the version of the TDF specification it supports.
-
-A -
Makes
dispdecode all the units it recognises (including diagnostic and linking units) within the TDF capsule.
-
-D -
Makes
dispprint a simple binary dump of the input file. This is intended for debugging purposes.
-
-E -
Makes
dispreport such information as the number of external tags and tokens which it usually omits.
-
-S -
Because tokens may be defined in terms of other tokens and do not need to be declared before they are defined,
dispmakes two passes of all the token definition units. In the first pass it extracts only the declaration information, stepping over the main body of the definition. On the second pass all the information is read. The-Soption makesdispskip the first pass.
-
-T -
The skip pass described under the
-Soption is usual done silently, without printing any information. This is changed by the-Toption.
-
-U -
Makes
dispprint the usage information associated with the external tokens and tags and also any linkage information units within the capsule.
-
-V -
By default
dispattempts to rationalise the TDF it reads. In particular it uses the external token and tag names whenever possible, following the token and tag bindings to find these, and makes up names for those tokens and tags which do not have external names. The-Voption makes it not attempt any such rationalisation, but instead to output exactly what it reads.
-
-W -
Makes
dispissue a warning about every token which is used before it is declared.
Diagnostics
The error reports if the input file is not a legal TDF capsule are intended to aid developers writing programs which produce TDF. Thus they try to give all the information that may be required, including the position within the input file that the error occurred.
Releases
Unchanged in 6 releases since Debian 2.2 (Potato).