summaryrefslogtreecommitdiffstats
path: root/parser.c
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2019-11-29 22:05:12 -0800
committerKaz Kylheku <kaz@kylheku.com>2019-11-29 22:05:12 -0800
commit91d2751f4fddaf80bd75d54f1bb62c5960ebdb7d (patch)
treebe5df153580c0b17573c9d97252ec2906ff402b1 /parser.c
parent05f11f5ab799e48301461756ea13b36d5f7b2510 (diff)
downloadtxr-91d2751f4fddaf80bd75d54f1bb62c5960ebdb7d.tar.gz
txr-91d2751f4fddaf80bd75d54f1bb62c5960ebdb7d.tar.bz2
txr-91d2751f4fddaf80bd75d54f1bb62c5960ebdb7d.zip
load: bug: source loc gathered for .tlo files.
Contrary to the belief expressed in the commit message of June 2018's 46480c25e62f60c761088c561d90b0f2f5a3143f, source location info is being recorded during the loading of compiled files. The reason is that the function used for processing the forms, lisp_parse_impl, overrides it. * parser.c (read_file_common): Use lisp_parse_impl directly, rather than lisp_parse. Specify that function's rlcp_p argument as false when processing compiled code.
Diffstat (limited to 'parser.c')
-rw-r--r--parser.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/parser.c b/parser.c
index 60d98df3..312c5476 100644
--- a/parser.c
+++ b/parser.c
@@ -720,6 +720,7 @@ static val read_file_common(val self, val stream, val error_stream, val compiled
val first = t;
val big_endian = nil;
val parser = ensure_parser(stream, name);
+ val not_compiled = null(compiled);
if (compiled) {
parser_t *pi = parser_get_impl(self, parser);
@@ -727,7 +728,8 @@ static val read_file_common(val self, val stream, val error_stream, val compiled
}
for (;;) {
- val form = lisp_parse(stream, error_stream, error_val, name, colon_k);
+ val form = lisp_parse_impl(self, nil, not_compiled, stream,
+ error_stream, error_val, name, colon_k);
if (form == error_val) {
if (parser_errors(parser) != zero)