summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp
diff options
context:
space:
mode:
authorLeo Liu <sdl.web@gmail.com>2011-08-26 17:52:07 +0800
committerLeo Liu <sdl.web@gmail.com>2011-08-26 17:52:07 +0800
commitf8ccf16762e094505989b9d60fab2cc24d117daa (patch)
tree77abba834a243d1ff081756df9a9cd1ebfaca496 /lisp/emacs-lisp
parent2a9878fd77cdc566643a071beb61b5436d96f9ab (diff)
downloademacs-f8ccf16762e094505989b9d60fab2cc24d117daa.tar.gz
emacs-f8ccf16762e094505989b9d60fab2cc24d117daa.tar.bz2
emacs-f8ccf16762e094505989b9d60fab2cc24d117daa.zip
Fix format bug in defstruct
http://debbugs.gnu.org/9357
Diffstat (limited to 'lisp/emacs-lisp')
-rw-r--r--lisp/emacs-lisp/cl-macs.el10
1 files changed, 4 insertions, 6 deletions
diff --git a/lisp/emacs-lisp/cl-macs.el b/lisp/emacs-lisp/cl-macs.el
index fb19115287c..d9531cc5261 100644
--- a/lisp/emacs-lisp/cl-macs.el
+++ b/lisp/emacs-lisp/cl-macs.el
@@ -2416,9 +2416,8 @@ value, that slot cannot be set via `setf'.
(append
(and pred-check
(list (list 'or pred-check
- (list 'error
- (format "%s accessing a non-%s"
- accessor name)))))
+ `(error "%s accessing a non-%s"
+ ',accessor ',name))))
(list (if (eq type 'vector) (list 'aref 'cl-x pos)
(if (= pos 0) '(car cl-x)
(list 'nth pos 'cl-x)))))) forms)
@@ -2426,9 +2425,8 @@ value, that slot cannot be set via `setf'.
(push (list 'define-setf-method accessor '(cl-x)
(if (cadr (memq :read-only (cddr desc)))
(list 'progn '(ignore cl-x)
- (list 'error
- (format "%s is a read-only slot"
- 'accessor)))
+ `(error "%s is a read-only slot"
+ ',accessor))
;; If cl is loaded only for compilation,
;; the call to cl-struct-setf-expander would
;; cause a warning because it may not be