]> git.eshelyaron.com Git - emacs.git/commitdiff
Define cl-concatenate as an alias to seq-concatenate
authorNicolas Petton <nicolas@petton.fr>
Wed, 15 Apr 2015 16:26:52 +0000 (18:26 +0200)
committerNicolas Petton <nicolas@petton.fr>
Wed, 15 Apr 2015 16:29:15 +0000 (18:29 +0200)
* lisp/emacs-lisp/cl-extra.el (cl-concatenate): Removes duplicated
  code by making cl-concatenate an alias to seq-concatenate.

lisp/emacs-lisp/cl-extra.el

index afc2adbee6d4641fec8656199c6debaae7959860..0a6bc3afda71d689ba67d6063d5562487566d3e5 100644 (file)
@@ -528,13 +528,9 @@ If START or END is negative, it counts from the end."
   (seq-subseq seq start end))
 
 ;;;###autoload
-(defun cl-concatenate (type &rest seqs)
+(defalias 'cl-concatenate #'seq-concatenate
   "Concatenate, into a sequence of type TYPE, the argument SEQUENCEs.
-\n(fn TYPE SEQUENCE...)"
-  (cond ((eq type 'vector) (apply 'vconcat seqs))
-       ((eq type 'string) (apply 'concat seqs))
-       ((eq type 'list) (apply 'append (append seqs '(nil))))
-       (t (error "Not a sequence type name: %s" type))))
+\n(fn TYPE SEQUENCE...)")
 
 
 ;;; List functions.