diff options
| author | Stefan Monnier | 2003-05-18 02:31:19 +0000 |
|---|---|---|
| committer | Stefan Monnier | 2003-05-18 02:31:19 +0000 |
| commit | b6a1ce0b31ff2dc163a614b75226130756dddf4a (patch) | |
| tree | dd6508ddc00fc24c5353419fe836102d6b803968 | |
| parent | de0abe8c694031dc279bfaa3e4d8c9d90188a43b (diff) | |
| download | emacs-b6a1ce0b31ff2dc163a614b75226130756dddf4a.tar.gz emacs-b6a1ce0b31ff2dc163a614b75226130756dddf4a.zip | |
(macro-declaration-function): Avoid `dolist' and `cadr'.
| -rw-r--r-- | lisp/subr.el | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/lisp/subr.el b/lisp/subr.el index 864af300e3e..54e1d04df22 100644 --- a/lisp/subr.el +++ b/lisp/subr.el | |||
| @@ -43,13 +43,17 @@ This is set as the value of the variable `macro-declaration-function'. | |||
| 43 | MACRO is the name of the macro being defined. | 43 | MACRO is the name of the macro being defined. |
| 44 | DECL is a list `(declare ...)' containing the declarations. | 44 | DECL is a list `(declare ...)' containing the declarations. |
| 45 | The return value of this function is not used." | 45 | The return value of this function is not used." |
| 46 | (dolist (d (cdr decl)) | 46 | ;; We can't use `dolist' or `cadr' yet for bootstrapping reasons. |
| 47 | (cond ((and (consp d) (eq (car d) 'indent)) | 47 | (let (d) |
| 48 | (put macro 'lisp-indent-function (cadr d))) | 48 | ;; Ignore the first element of `decl' (it's always `declare'). |
| 49 | ((and (consp d) (eq (car d) 'debug)) | 49 | (while (setq decl (cdr decl)) |
| 50 | (put macro 'edebug-form-spec (cadr d))) | 50 | (setq d (car decl)) |
| 51 | (t | 51 | (cond ((and (consp d) (eq (car d) 'indent)) |
| 52 | (message "Unknown declaration %s" d))))) | 52 | (put macro 'lisp-indent-function (car (cdr d)))) |
| 53 | ((and (consp d) (eq (car d) 'debug)) | ||
| 54 | (put macro 'edebug-form-spec (car (cdr d)))) | ||
| 55 | (t | ||
| 56 | (message "Unknown declaration %s" d)))))) | ||
| 53 | 57 | ||
| 54 | (setq macro-declaration-function 'macro-declaration-function) | 58 | (setq macro-declaration-function 'macro-declaration-function) |
| 55 | 59 | ||