summaryrefslogtreecommitdiffstats
path: root/tests/014
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2021-03-27 16:55:59 -0700
committerKaz Kylheku <kaz@kylheku.com>2021-03-27 16:55:59 -0700
commit893431eca5abc7df6f788912b9e7179bc47faf34 (patch)
tree16ae29fd01b678eab2ec4a5f1302664481191b67 /tests/014
parentfcd5374bc0a3cc878cfacea092ce074326ac5940 (diff)
downloadtxr-893431eca5abc7df6f788912b9e7179bc47faf34.tar.gz
txr-893431eca5abc7df6f788912b9e7179bc47faf34.tar.bz2
txr-893431eca5abc7df6f788912b9e7179bc47faf34.zip
compile/eval: more standard formatting for diags.
This patch eliminates parentheses from the error messages, as well as a leading ./ being added to relative paths. The word "warning: " is moved into the error message, so that it does not appear before the location. Example, when doing (compile-file "path/to/foo.tl"). Before patch: warning: (./path/to/foo.tl:37): unbound function foo After: path/to/foo.tl:37: warning: unbound function foo Now when I compile out of Vim, it nicely jumps to errors in Lisp code. * eval.c (eval_exception): Drop parentheses from error location, add colon. (eval_warn): Prepend "warning: " to format string. (eval_defr_warn): Drop parentheses from location, and prepend "warning: " to format string. * parser.c (repl-warning): Drop "warning:" prefix. * share/txr/stdlib/compiler.tl (open-compile-streams): Do not do parent substitution for relative paths if the parent path is the empty string "", to avoid inserting ./ onto relative paths in that case. * share/txr/stdlib/error.tl (sys:loc): Drop parentheses and space from location. (compile-error) Separate location with colon and space. (compile-warning, compile-defr-warning): Likewise and add "warning: " prefix. * unwind.c (uw_rthrow): Drop "warning: " prefix. (uw_warningf): Add "warning: " prefix. (uw_dump_deferred_warnings): Drop "warning: " prefix.
Diffstat (limited to 'tests/014')
0 files changed, 0 insertions, 0 deletions