diff options
| author | Leo Liu | 2014-05-20 00:08:40 +0800 |
|---|---|---|
| committer | Leo Liu | 2014-05-20 00:08:40 +0800 |
| commit | 427de5355f3c70e60ddc65324f1270d533fca0c2 (patch) | |
| tree | be2292cea55b91f48095800b20fb0ced45648501 | |
| parent | 8bb5971691aa57b9eda5993440316f6bd3d667d1 (diff) | |
| download | emacs-427de5355f3c70e60ddc65324f1270d533fca0c2.tar.gz emacs-427de5355f3c70e60ddc65324f1270d533fca0c2.zip | |
* emacs-lisp/cl-lib.el (cl-endp): Conform to CL's semantics.
| -rw-r--r-- | lisp/ChangeLog | 4 | ||||
| -rw-r--r-- | lisp/emacs-lisp/cl-lib.el | 8 |
2 files changed, 11 insertions, 1 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index abe240a5ea4..733d060f453 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,7 @@ | |||
| 1 | 2014-05-19 Leo Liu <sdl.web@gmail.com> | ||
| 2 | |||
| 3 | * emacs-lisp/cl-lib.el (cl-endp): Conform to CL's semantics. | ||
| 4 | |||
| 1 | 2014-05-18 Glenn Morris <rgm@gnu.org> | 5 | 2014-05-18 Glenn Morris <rgm@gnu.org> |
| 2 | 6 | ||
| 3 | * loadup.el: | 7 | * loadup.el: |
diff --git a/lisp/emacs-lisp/cl-lib.el b/lisp/emacs-lisp/cl-lib.el index 929e3dfb2f5..9ca9459987f 100644 --- a/lisp/emacs-lisp/cl-lib.el +++ b/lisp/emacs-lisp/cl-lib.el | |||
| @@ -358,7 +358,13 @@ SEQ, this is like `mapcar'. With several, it is like the Common Lisp | |||
| 358 | (cl--defalias 'cl-first 'car) | 358 | (cl--defalias 'cl-first 'car) |
| 359 | (cl--defalias 'cl-second 'cadr) | 359 | (cl--defalias 'cl-second 'cadr) |
| 360 | (cl--defalias 'cl-rest 'cdr) | 360 | (cl--defalias 'cl-rest 'cdr) |
| 361 | (cl--defalias 'cl-endp 'null) | 361 | |
| 362 | (defun cl-endp (x) | ||
| 363 | "Return true if X is the empty list; false if it is a cons. | ||
| 364 | Signal an error if X is not a list." | ||
| 365 | (if (listp x) | ||
| 366 | (null x) | ||
| 367 | (signal 'wrong-type-argument (list 'list x 'x)))) | ||
| 362 | 368 | ||
| 363 | (cl--defalias 'cl-third 'cl-caddr "Return the third element of the list X.") | 369 | (cl--defalias 'cl-third 'cl-caddr "Return the third element of the list X.") |
| 364 | (cl--defalias 'cl-fourth 'cl-cadddr "Return the fourth element of the list X.") | 370 | (cl--defalias 'cl-fourth 'cl-cadddr "Return the fourth element of the list X.") |