# HG changeset patch # User Colin Walters # Date 1023575526 0 # Node ID 5204b7681bdc161db3bfa2d402c4d6d1066ef9f5 # Parent 85a6d63fb0181f8a8848660a93a95ae61f98cb03 (cl-copy-tree): Moved to `copy-tree' in subr.el. Add a defalias with the old name. diff -r 85a6d63fb018 -r 5204b7681bdc lisp/emacs-lisp/cl-extra.el --- a/lisp/emacs-lisp/cl-extra.el Sat Jun 08 22:12:57 2002 +0000 +++ b/lisp/emacs-lisp/cl-extra.el Sat Jun 08 22:32:06 2002 +0000 @@ -565,24 +565,7 @@ (setq list (cdr list))) (if (numberp sublist) (equal sublist list) (eq sublist list))) -(defun cl-copy-tree (tree &optional vecp) - "Make a copy of TREE. -If TREE is a cons cell, this recursively copies both its car and its cdr. -Contrast to copy-sequence, which copies only along the cdrs. With second -argument VECP, this copies vectors as well as conses." - (if (consp tree) - (let ((p (setq tree (copy-list tree)))) - (while (consp p) - (if (or (consp (car p)) (and vecp (vectorp (car p)))) - (setcar p (cl-copy-tree (car p) vecp))) - (or (listp (cdr p)) (setcdr p (cl-copy-tree (cdr p) vecp))) - (cl-pop p))) - (if (and vecp (vectorp tree)) - (let ((i (length (setq tree (copy-sequence tree))))) - (while (>= (setq i (1- i)) 0) - (aset tree i (cl-copy-tree (aref tree i) vecp)))))) - tree) -(defalias 'copy-tree 'cl-copy-tree) +(defalias 'cl-copy-tree 'copy-tree) ;;; Property lists.