pub enum ScannerStatus {
Normal,
Defining,
Matching,
Aligning,
Absorbing,
}Expand description
What the scanner is reading, for the recovery TeX makes when a file ends in
the middle of it: tex.web §305 scanner_status (with warning_index, the
command it names). A scan that owns a status sets it for its duration with
set_scanner_status and restores the enclosing one after, as tex.web
saves and restores it (§389 macro_call, §473 scan_toks); every nested
read that sets none inherits it. recover_at_file_end consults it.
tex.web’s skipping (conditional text) is not modelled: a skip that runs
off an input level stops there, as Perl’s does (read_next_conditional).
Variants§
Normal
Not inside any of the scans below: a file’s end is not a runaway.
Defining
defining: a definition body, \def/\edef (§473 scan_toks(true, _)).
Matching
matching: a macro’s arguments (§389-391 macro_call).
Aligning
aligning: an alignment preamble (§777 init_align).
Absorbing
absorbing: a balanced text, \message, \write, \toks=,
\detokenize … (§473 scan_toks(false, _), eTeX scan_general_text).