From b6403cfaa935cd7b144cb6c1c15ba9cfacd73441 Mon Sep 17 00:00:00 2001 From: Kaz Kylheku Date: Wed, 13 Apr 2016 20:00:31 -0700 Subject: Bugfix: track origin for built-in macros. This fix is no longer that important, since due to the previous commit, expand now tracks expansion origins thoroughly, which hides this bug. However, expand_macro is directly called from a few other functions, like macroexpand, which don't benefit from that fix. * eval.c (expand_macro): Add forgotten set_origin call in the case when the native C expander is called. --- eval.c | 1 + 1 file changed, 1 insertion(+) diff --git a/eval.c b/eval.c index a40f41b7..a0926a1d 100644 --- a/eval.c +++ b/eval.c @@ -1602,6 +1602,7 @@ static val expand_macro(val form, val mac_binding, val menv) if (cobjp(expander)) { mefun_t fp = coerce(mefun_t, cptr_get(expander)); val expanded = fp(form, menv); + set_origin(expanded, form); return expanded; } else { debug_enter; -- cgit v1.2.3