diff options
author | Noam Postavsky <npostavs@gmail.com> | 2020-03-22 07:48:14 -0400 |
---|---|---|
committer | Noam Postavsky <npostavs@gmail.com> | 2020-03-22 23:06:31 -0400 |
commit | 9ab85f087f7db38168dcf07d24f51ecd2c583f8a (patch) | |
tree | 0ae48c0410b18776d4605fe46e303001683ee7d8 /test | |
parent | 561e9fb91bba98616f6d7ea3818727c1cdd2d853 (diff) | |
download | emacs-9ab85f087f7db38168dcf07d24f51ecd2c583f8a.tar.gz |
Fix cl-concatenate (Bug#40180)
* lisp/emacs-lisp/cl-extra.el (cl-concatenate): Use apply, to avoid
adding extra nesting of args.
* test/lisp/emacs-lisp/cl-extra-tests.el (cl-concatenate): New test.
Diffstat (limited to 'test')
-rw-r--r-- | test/lisp/emacs-lisp/cl-extra-tests.el | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/lisp/emacs-lisp/cl-extra-tests.el b/test/lisp/emacs-lisp/cl-extra-tests.el index 2d20ba75d29..7546c149377 100644 --- a/test/lisp/emacs-lisp/cl-extra-tests.el +++ b/test/lisp/emacs-lisp/cl-extra-tests.el @@ -99,4 +99,12 @@ ;; Test for Bug#33731. (should-not (eq s (cl-make-random-state s))))) +(ert-deftest cl-concatenate () + (should (equal (cl-concatenate 'list '(1 2 3) '(4 5 6)) + '(1 2 3 4 5 6))) + (should (equal (cl-concatenate 'vector [1 2 3] [4 5 6]) + [1 2 3 4 5 6])) + (should (equal (cl-concatenate 'string "123" "456") + "123456"))) + ;;; cl-extra-tests.el ends here |