[ << ] | [ < ] | [ Up ] | [ > ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
19.6.2 ‘#line’ and TeX
As mentioned, makeinfo
recognizes the ‘#line’
directives described in the previous section. However,
‘texinfo.tex’ does not and cannot. Therefore, such a line will
be incorrectly typeset verbatim if TeX sees it. The solution is to
use makeinfo
’s macro expansion options before running
TeX. There are three approaches:
-
If you run
texi2dvi
or its variants (see section Format withtexi2dvi
), you can pass ‘-E’ andtexi2dvi
will runmakeinfo
first to expand macros and eliminate ‘#line’. -
If you run
makeinfo
or its variants (see sectiontexi2any
: The Generic Translator for Texinfo), you can specify ‘--no-ifinfo --iftex -E somefile.out’, and then give ‘somefile.out’ totexi2dvi
in a separate command. -
Or you can run ‘makeinfo --dvi --Xopt -E’. (Or ‘--pdf’
instead of ‘--dvi’.)
makeinfo
will then calltexi2dvi -E
.
One last caveat regarding use with TeX: since the #line
directives are not recognized, the line numbers emitted by the
@errormsg{}
command (see section Conditional Commands), or by
TeX itself, are the (incorrect) line numbers from the derived file
which TeX is reading, rather than the preprocessor-specified line
numbers. This is another example of why we recommend running
makeinfo
for the best diagnostics (see section makeinfo
Advantages).
[ << ] | [ < ] | [ Up ] | [ > ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
This document was generated on October 2, 2013 using texi2html 5.0.