From 9b96062b2eb355b6f6a6583391a6958d9da28bed Mon Sep 17 00:00:00 2001 From: Matthias Andreas Benkard Date: Sat, 20 Jul 2013 18:19:04 +0200 Subject: Make variables shadow symbol macros. --- sb-eval2.lisp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/sb-eval2.lisp b/sb-eval2.lisp index 853ba02..1e16620 100644 --- a/sb-eval2.lisp +++ b/sb-eval2.lisp @@ -148,8 +148,13 @@ (and parent (context-find-go-tag parent go-tag))))) (defun context-find-symbol-macro (context symmac) (let ((parent (context-parent context))) - (or (cdr (assoc (the symbol symmac) (context-symbol-macros context))) - (and parent (context-find-symbol-macro parent symmac))))) + (and (not (member symmac + (context-lexicals context) + :test #'equal + :key #'lexical-name)) + (not (member symmac (context-specials context) :test #'equal)) + (or (cdr (assoc (the symbol symmac) (context-symbol-macros context))) + (and parent (context-find-symbol-macro parent symmac)))))) (defun context-find-macro (context mac) (let ((parent (context-parent context))) (and (not (member `(function ,mac) -- cgit v1.2.3