diff options
| author | Richard M. Stallman | 1995-04-24 04:21:21 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 1995-04-24 04:21:21 +0000 |
| commit | 5d265171c80e735ef13fb8d2d0b57551e7183b41 (patch) | |
| tree | 93c6ba8d4fc43a8da606ceea1edb4eed09db7187 | |
| parent | 0656272711fe7443e26390f717914f2ebdccaefe (diff) | |
| download | emacs-5d265171c80e735ef13fb8d2d0b57551e7183b41.tar.gz emacs-5d265171c80e735ef13fb8d2d0b57551e7183b41.zip | |
(byte-optimize-letX): Use car-safe and cdr-safe.
| -rw-r--r-- | lisp/emacs-lisp/byte-opt.el | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lisp/emacs-lisp/byte-opt.el b/lisp/emacs-lisp/byte-opt.el index 1d394511c96..6e89aa20435 100644 --- a/lisp/emacs-lisp/byte-opt.el +++ b/lisp/emacs-lisp/byte-opt.el | |||
| @@ -940,7 +940,8 @@ | |||
| 940 | form) | 940 | form) |
| 941 | ;; The body is nil | 941 | ;; The body is nil |
| 942 | ((eq (car form) 'let) | 942 | ((eq (car form) 'let) |
| 943 | (append '(progn) (mapcar 'car (mapcar 'cdr (nth 1 form))) '(nil))) | 943 | (append '(progn) (mapcar 'car-safe (mapcar 'cdr-safe (nth 1 form))) |
| 944 | '(nil))) | ||
| 944 | (t | 945 | (t |
| 945 | (let ((binds (reverse (nth 1 form)))) | 946 | (let ((binds (reverse (nth 1 form)))) |
| 946 | (list 'let* (reverse (cdr binds)) (nth 1 (car binds)) nil))))) | 947 | (list 'let* (reverse (cdr binds)) (nth 1 (car binds)) nil))))) |