diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2021-07-05 21:01:20 -0700 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2021-07-05 21:01:20 -0700 |
commit | 41be29f11bd1820a9ed4043b04d852a63e7e8480 (patch) | |
tree | 29bbd03fa102df1b9550fb68eb869b9f8e569e38 /ftw.h | |
parent | 7bbc3f87ec0194af20fd309cf20c06bc187fac1c (diff) | |
download | txr-41be29f11bd1820a9ed4043b04d852a63e7e8480.tar.gz txr-41be29f11bd1820a9ed4043b04d852a63e7e8480.tar.bz2 txr-41be29f11bd1820a9ed4043b04d852a63e7e8480.zip |
macro params: use compiler-style error reporting.
* eval.c (bind_macro_params): Take the error reporting
function as a functional argument which points either to
eval_error or expand_error. Update all the recursive calls to
pass it down. Replace all calls to eval_error with this
function pointer.
(me_interp_macro, op_mac_param_bind, op_mac_env_param_bind):
Call bind_macro_params with expand_error as the function, so
that under the right circumstances, the error will go to
standard error, as well as being thrown as an exception.
In the case of me_interp_macro, this is clear. The reason we
do it for the other two is that their primary use case is
inside macros.
(op_tree_case, op_tree_bind): Pass eval_error to
mac_param_bind, preserving existing behavior.
Diffstat (limited to 'ftw.h')
0 files changed, 0 insertions, 0 deletions