From 44366a564c2738f6d9085d828df80f3e4a5a6994 Mon Sep 17 00:00:00 2001 From: Kaz Kylheku Date: Fri, 3 Feb 2017 10:15:02 -0800 Subject: More accurate error wording from Lisp-1 operators. * eval.c (op_lisp1_setq, op_lisp1_value): If a Lisp-1 binding is not found, this is because it is neither a function nor variable, not because it is not a variable. The error message now reflects this. --- eval.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/eval.c b/eval.c index a4537e4b..e1431fdf 100644 --- a/eval.c +++ b/eval.c @@ -2064,7 +2064,7 @@ static val op_lisp1_setq(val form, val env) val binding = lookup_sym_lisp1(env, var); if (nilp(binding)) - eval_error(form, lit("unbound variable ~s"), var, nao); + eval_error(form, lit("unbound variable/function ~s"), var, nao); return sys_rplacd(binding, eval(newval, env, form)); } @@ -2101,7 +2101,7 @@ static val op_lisp1_value(val form, val env) } else { val binding = lookup_sym_lisp1(env, arg); if (nilp(binding)) - eval_error(form, lit("unbound variable ~s"), arg, nao); + eval_error(form, lit("unbound variable/function ~s"), arg, nao); return cdr(binding); } } -- cgit v1.2.3