Function: format-make-relatively-unique

format-make-relatively-unique is a byte-compiled function defined in format.el.gz.

Signature

(format-make-relatively-unique A B)

Documentation

Delete common elements of lists A and B, return as pair.

Compare using equal.

Source Code

;; Defined in /usr/src/emacs/lisp/format.el.gz
(defun format-make-relatively-unique (a b)
  "Delete common elements of lists A and B, return as pair.
Compare using `equal'."
  (let* ((acopy (copy-sequence a))
	 (bcopy (copy-sequence b))
	 (tail acopy))
    (while tail
      (let ((dup (member (car tail) bcopy))
	    (next (cdr tail)))
	(if dup (setq acopy (format-delq-cons tail acopy)
		      bcopy (format-delq-cons dup  bcopy)))
	(setq tail next)))
    (cons acopy bcopy)))