Mercurial > emacs
changeset 74285:bdb0d9c34bd4
(byte-compile-get-constant):
Replace incorrect use of assoc-default with a loop.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Tue, 28 Nov 2006 02:22:17 +0000 |
parents | efbf3bcfde0b |
children | e7dacee7b66e |
files | lisp/emacs-lisp/bytecomp.el |
diffstat | 1 files changed, 6 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/emacs-lisp/bytecomp.el Tue Nov 28 02:21:28 2006 +0000 +++ b/lisp/emacs-lisp/bytecomp.el Tue Nov 28 02:22:17 2006 +0000 @@ -2864,8 +2864,12 @@ (defmacro byte-compile-get-constant (const) `(or (if (stringp ,const) - (assoc-default ,const byte-compile-constants - 'equal-including-properties nil) + ;; In a string constant, treat properties as significant. + (let (result) + (dolist (elt byte-compile-constants) + (if (equal-including-properties (car elt) ,const) + (setq result elt))) + result) (assq ,const byte-compile-constants)) (car (setq byte-compile-constants (cons (list ,const) byte-compile-constants)))))