Mercurial > hg > xemacs-beta
diff lisp/cl.el @ 5476:f2881cb841b4
Merged with trunk.
author | Mats Lidell <matsl@xemacs.org> |
---|---|
date | Tue, 26 Apr 2011 23:41:47 +0200 |
parents | 248176c74e6b 97ac18bd1fa3 |
children | 1b054bc2ac40 |
line wrap: on
line diff
--- a/lisp/cl.el Sat Apr 23 23:47:13 2011 +0200 +++ b/lisp/cl.el Tue Apr 26 23:41:47 2011 +0200 @@ -227,11 +227,17 @@ The second optional arg ENVIRONMENT specifies an environment of macro definitions to shadow the loaded ones for use in file byte-compilation." - (let ((cl-macro-environment cl-env)) - (while (progn (setq cl-macro (funcall cl-old-macroexpand cl-macro cl-env)) + (let ((cl-macro-environment + (if cl-macro-environment (append cl-env cl-macro-environment) cl-env)) + eq-hash) + (while (progn (setq cl-macro + (macroexpand-internal cl-macro cl-macro-environment)) (and (symbolp cl-macro) - (cdr (assq (symbol-name cl-macro) cl-env)))) - (setq cl-macro (cadr (assq (symbol-name cl-macro) cl-env)))) + (setq eq-hash (eq-hash cl-macro)) + (if (fixnump eq-hash) + (assq eq-hash cl-macro-environment) + (assoc eq-hash cl-macro-environment)))) + (setq cl-macro (cadr (assoc* eq-hash cl-macro-environment)))) cl-macro)) ;;; Declarations.