diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2021-05-28 23:52:49 -0700 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2021-05-28 23:52:49 -0700 |
commit | 2ec8502b72574b244c1ed1e07383d8735aa90ac0 (patch) | |
tree | ddbc56534a5daee631aafa355af5aa1ccd383e7c /signal.h | |
parent | f05f004356e91f110f5297bdb61827a7c4436d2f (diff) | |
download | txr-2ec8502b72574b244c1ed1e07383d8735aa90ac0.tar.gz txr-2ec8502b72574b244c1ed1e07383d8735aa90ac0.tar.bz2 txr-2ec8502b72574b244c1ed1e07383d8735aa90ac0.zip |
parser: remove some parser access functions.
* parser.c (lisp_parse_impl): Access pi->eof directly instead
of going through parser_eof. We are using pi->errors in the
same expression! This is the only place pi->eof is needed.
(read_file_common): Don't call parser_eof. Assume that if
error_val emerges, and errors is zero, it must be eof.
(read_eval_ret_last): Simplify: the code actually does nothing
specia for eof versus errors, so we just bail if error_var
emerges.
(get_parser): Function removed.
(parse_errors): This is the only caller of get_parser, which
now just calls gethash to fetch the parser.
(parser_eof): Function removed.
(parse_init): sys:get-parser, sys:parser-errors and
sys:parser-eof intrinsics removed. The C function
parser_errors still exists; it is used in a few places.
* parser.h (get_parser, parser_eof): Declarations removed.
* share/txr/stdlib/compiler.tl (compile-file-conditionally):
Use the new parse-errors function instead of the removed
sys:parser-errors. Since that works on the stream, we don't
have to call sys:get-parser. Because it returns nil if there
are no errors, we drop the > test.
Diffstat (limited to 'signal.h')
0 files changed, 0 insertions, 0 deletions