Function: bytecomp--copy-tree-1
bytecomp--copy-tree-1 is a byte-compiled function defined in
bytecomp.el.gz.
Signature
(bytecomp--copy-tree-1 TREE)
Source Code
;; Defined in /usr/src/emacs/lisp/emacs-lisp/bytecomp.el.gz
(defun bytecomp--copy-tree-1 (tree)
;; TREE must be a cons.
(or (gethash tree bytecomp--copy-tree-seen)
(let* ((next (cdr tree))
(result (cons nil next))
(copy result))
(while (progn
(puthash tree copy bytecomp--copy-tree-seen)
(let ((a (car tree)))
(setcar copy (if (consp a)
(bytecomp--copy-tree-1 a)
a)))
(and (consp next)
(let ((tail (gethash next bytecomp--copy-tree-seen)))
(if tail
(progn (setcdr copy tail)
nil)
(setq tree next)
(setq next (cdr next))
(let ((prev copy))
(setq copy (cons nil next))
(setcdr prev copy)
t))))))
result)))