anchor.diff:  ;;; Function adjoin
   
   (defun adjoin-identity-eq (name item list)
  -  (if (member-eq-identity name item list)
  +  (if (|member test=eq key=identity| name item list)
         list
         (cons item list)))
   
   (defun adjoin-identity-eql (name item list)
  -  (if (member-eql-identity name item list)
  +  (if (|member test=eql key=identity| name item list)
         list
         (cons item list)))
   
   (defun adjoin-identity-test (name item list test)
  -  (if (member-test-identity name item list test)
  +  (if (|member test=other key=identity| name item list test)
         list
         (cons item list)))
   
   (defun adjoin-identity-test-not (name item list test-not)
  -  (if (member-test-not-identity name item list test-not)
  +  (if (|member test-not=other key=identity| name item list test-not)
         list
         (cons item list)))
   
   (defun adjoin-key-eq (name item list key)
  -  (if (member-eq-key name (funcall key item) list key)
  +  (if (|member test=eq key=other| name (funcall key item) list key)
         list
         (cons item list)))
   
   (defun adjoin-key-eql (name item list key)
  -  (if (member-eql-key name (funcall key item) list key)
  +  (if (|member test=eql key=other| name (funcall key item) list key)
         list
         (cons item list)))
   
   (defun adjoin-key-test (name item list key test)
  -  (if (member-test-key name (funcall key item) list test key)
  +  (if (|member test=other key=other| name (funcall key item) list test key)
         list
         (cons item list)))
   
   (defun adjoin-key-test-not (name item list key test-not)
  -  (if (member-test-not-key name (funcall key item) list test-not key)
  +  (if (|member test-not=other key=other| name (funcall key item) list test-not key)
         list
         (cons item list)))
   
  
positive.code: ;;;
  ;;; Function set-exclusive-or
  
  (defun set-exclusive-or-identity-eql (list1 list2)
    (let ((result '()))
      (loop for element in list1
  	  unless (member element list2)
  	    do (push element result))
      (loop for element in list2
  	  unless (member element list1)
  	    do (push element result))
      result))
  
  (defun set-exclusive-or-identity-eq (list1 list2)
    (let ((result '()))
      (loop for element in list1
  	  unless (member element list2 :test #'eq)
  	    do (push element result))
      (loop for element in list2
  	  unless (member element list1 :test #'eq)
  	    do (push element result))
      result))
  
  (defun set-exclusive-or-key-eql (list1 list2 key)
    (let ((result '()))
      (loop for element in list1
  	  unless (member (funcall key element) list2 :key key)
  	    do (push element result))
      (loop for element in list2
  	  unless (member (funcall key element) list1 :key key)
  	    do (push element result))
      result))
  
  (defun set-exclusive-or-key-eq (list1 list2 key)
    (let ((result '()))
      (loop for element in list1
  	  unless (member (funcall key element) list2 :test #'eq :key key)
  	    do (push element result))
      (loop for element in list2
  	  unless (member (funcall key element) list1 :test #'eq :key key)
  	    do (push element result))
      result))
  
  ;;; This is tricky because we can't use member to test whether 
  ;;; an element of list2 is a member of list1, simply because 
  ;;; that would reverse the arguments to the test, and the 
  ;;; test is not necessarily a commutative function. 
  (defun set-exclusive-or-identity-test (list1 list2 test)
    (let ((result '()))
      (loop for element1 in list1
  	  unless (loop for element2 in list2
  		       thereis (funcall test element1 element2))
  	    do (push element1 result))
      (loop for element2 in list2
  	  unless (loop for element1 in list1
  		       thereis (funcall test element1 element2))
  	    do (push element2 result))
      result))
  
  ;;; This is tricky because we can't use member to test whether 
  ;;; an element of list2 is a member of list1, simply because 
  ;;; that would reverse the arguments to the test, and the 
  ;;; test is not necessarily a commutative function. 
  (defun set-exclusive-or-key-test (list1 list2 key test)
    (let ((result '()))
      (loop for element1 in list1
  	  unless (loop for element2 in list2
  		       thereis (funcall test
  					(funcall key element1)
  					(funcall key element2)))
  	    do (push element1 result))
      (loop for element2 in list2
  	  unless (loop for element1 in list1
  		       thereis (funcall test
  					(funcall key element1)
  					(funcall key element2)))
  	    do (push element2 result))
      result))
  
  ;;; This is tricky because we can't use member to test whether 
  ;;; an element of list2 is a member of list1, simply because 
  ;;; that would reverse the arguments to the test, and the 
  ;;; test is not necessarily a commutative function. 
  (defun set-exclusive-or-identity-test-not (list1 list2 test-not)
    (let ((result '()))
      (loop for element1 in list1
  	  when (loop for element2 in list2
  		     always (funcall test-not element1 element2))
  	    do (push element1 result))
      (loop for element2 in list2
  	  when (loop for element1 in list1
  		     always (funcall test-not element1 element2))
  	    do (push element2 result))
      result))
  
  ;;; This is tricky because we can't use member to test whether 
  ;;; an element of list2 is a member of list1, simply because 
  ;;; that would reverse the arguments to the test, and the 
  ;;; test is not necessarily a commutative function. 
  (defun set-exclusive-or-key-test-not (list1 list2 key test-not)
    (let ((result '()))
      (loop for element1 in list1
  	  when (loop for element2 in list2
  		     always (funcall test-not
  				     (funcall key element1)
  				     (funcall key element2)))
  	    do (push element1 result))
      (loop for element2 in list2
  	  when (loop for element1 in list1
  		     always (funcall test-not
  				     (funcall key element1)
  				     (funcall key element2)))
  	    do (push element2 result))
      result))
  
  (defun set-exclusive-or-identity-eq-hash (list1 list2)
    (let ((table1 (make-hash-table :test #'eq))
  	(table2 (make-hash-table :test #'eq))
  	(result '()))
      (loop for element in list1
  	  do (setf (gethash element table1) t))
      (loop for element in list2
  	  do (setf (gethash element table2) t))
      (loop for element in list1
  	  unless (gethash element table2)
  	    do (push element result))
      (loop for element in list2
  	  unless (gethash element table1)
  	    do (push element result))
      result))
  
  (defun set-exclusive-or-identity-eql-hash (list1 list2)
    (let ((table1 (make-hash-table :test #'eql))
  	(table2 (make-hash-table :test #'eql))
  	(result '()))
      (loop for element in list1
  	  do (setf (gethash element table1) t))
      (loop for element in list2
  	  do (setf (gethash element table2) t))
      (loop for element in list1
  	  unless (gethash element table2)
  	    do (push element result))
      (loop for element in list2
  	  unless (gethash element table1)
  	    do (push element result))
      result))
  
  (defun set-exclusive-or-identity-equal-hash (list1 list2)
    (let ((table1 (make-hash-table :test #'equal))
  	(table2 (make-hash-table :test #'equal))
  	(result '()))
      (loop for element in list1
  	  do (setf (gethash element table1) t))
      (loop for element in list2
  	  do (setf (gethash element table2) t))
      (loop for element in list1
  	  unless (gethash element table2)
  	    do (push element result))
      (loop for element in list2
  	  unless (gethash element table1)
  	    do (push element result))
      result))
  
  (defun set-exclusive-or-identity-equalp-hash (list1 list2)
    (let ((table1 (make-hash-table :test #'equalp))
  	(table2 (make-hash-table :test #'equalp))
  	(result '()))
      (loop for element in list1
  	  do (setf (gethash element table1) t))
      (loop for element in list2
  	  do (setf (gethash element table2) t))
      (loop for element in list1
  	  unless (gethash element table2)
  	    do (push element result))
      (loop for element in list2
  	  unless (gethash element table1)
  	    do (push element result))
      result))
  
  (defun set-exclusive-or-key-eq-hash (list1 list2 key)
    (let ((table1 (make-hash-table :test #'eq))
  	(table2 (make-hash-table :test #'eq))
  	(result '()))
      (loop for element in list1
  	  do (setf (gethash (funcall key element) table1) t))
      (loop for element in list2
  	  do (setf (gethash (funcall key element) table2) t))
      (loop for element in list1
  	  unless (gethash (funcall key element) table2)
  	    do (push element result))
      (loop for element in list2
  	  unless (gethash (funcall key element) table1)
  	    do (push element result))
      result))
  
  (defun set-exclusive-or-key-eql-hash (list1 list2 key)
    (let ((table1 (make-hash-table :test #'eql))
  	(table2 (make-hash-table :test #'eql))
  	(result '()))
      (loop for element in list1
  	  do (setf (gethash (funcall key element) table1) t))
      (loop for element in list2
  	  do (setf (gethash (funcall key element) table2) t))
      (loop for element in list1
  	  unless (gethash (funcall key element) table2)
  	    do (push element result))
      (loop for element in list2
  	  unless (gethash (funcall key element) table1)
  	    do (push element result))
      result))
  
  (defun set-exclusive-or-key-equal-hash (list1 list2 key)
    (let ((table1 (make-hash-table :test #'equal))
  	(table2 (make-hash-table :test #'equal))
  	(result '()))
      (loop for element in list1
  	  do (setf (gethash (funcall key element) table1) t))
      (loop for element in list2
  	  do (setf (gethash (funcall key element) table2) t))
      (loop for element in list1
  	  unless (gethash (funcall key element) table2)
  	    do (push element result))
      (loop for element in list2
  	  unless (gethash (funcall key element) table1)
  	    do (push element result))
      result))
  
  (defun set-exclusive-or-key-equalp-hash (list1 list2 key)
    (let ((table1 (make-hash-table :test #'equalp))
  	(table2 (make-hash-table :test #'equalp))
  	(result '()))
      (loop for element in list1
  	  do (setf (gethash (funcall key element) table1) t))
      (loop for element in list2
  	  do (setf (gethash (funcall key element) table2) t))
      (loop for element in list1
  	  unless (gethash (funcall key element) table2)
  	    do (push element result))
      (loop for element in list2
  	  unless (gethash (funcall key element) table1)
  	    do (push element result))
      result))
  
  (defun set-exclusive-or (list1 list2 &key key test test-not)
  
negative.code: 	(if test
  	    (cond ((or (eq test #'eq) (eq test 'eq))
  		   (if use-hash
  		       (set-exclusive-or-key-eq-hash 'nset-exclusive-or list1 list2 key)
  		       (set-exclusive-or-key-eq 'nset-exclusive-or list1 list2 key)))
  		  ((or (eq test #'eql) (eq test 'eql))
  		   (if use-hash
  		       (set-exclusive-or-key-eql-hash 'nset-exclusive-or list1 list2 key)
  		       (set-exclusive-or-key-eql 'nset-exclusive-or list1 list2 key)))
  		  ((or (eq test #'equal) (eq test 'equal))
  		   (if use-hash
  		       (set-exclusive-or-key-equal-hash 'nset-exclusive-or list1 list2 key)
  		       (set-exclusive-or-key-test 'nset-exclusive-or list1 list2 key #'equal)))
  		  ((or (eq test #'equalp) (eq test 'equalp))
  		   (if use-hash
  		       (set-exclusive-or-key-equalp-hash 'nset-exclusive-or list1 list2 key)
  		       (set-exclusive-or-key-test 'nset-exclusive-or list1 list2 key #'equalp)))
  		  (t
  		   (set-exclusive-or-key-test 'nset-exclusive-or list1 list2 key test)))
  	    (if test-not
  		(set-exclusive-or-key-test-not 'nset-exclusive-or list1 list2 key test-not)
  		(if use-hash
  		    (set-exclusive-or-key-eql-hash 'nset-exclusive-or list1 list2 key)
  		    (set-exclusive-or-key-eql 'nset-exclusive-or list1 list2 key))))
  	(if test
  	    (cond ((or (eq test #'eq) (eq test 'eq))
  		   (if use-hash
  		       (set-exclusive-or-identity-eq-hash 'nset-exclusive-or list1 list2)
  		       (set-exclusive-or-identity-eq 'nset-exclusive-or list1 list2)))
  		  ((or (eq test #'eql) (eq test 'eql))
  		   (if use-hash
  		       (set-exclusive-or-identity-eql-hash 'nset-exclusive-or list1 list2)
  		       (set-exclusive-or-identity-eql 'nset-exclusive-or list1 list2)))
  		  ((or (eq test #'equal) (eq test 'equal))
  		   (if use-hash
  		       (set-exclusive-or-identity-equal-hash 'nset-exclusive-or list1 list2)
  		       (set-exclusive-or-identity-test 'nset-exclusive-or list1 list2 #'equal)))
  		  ((or (eq test #'equalp) (eq test 'equalp))
  		   (if use-hash
  		       (set-exclusive-or-identity-equalp-hash 'nset-exclusive-or list1 list2)
  		       (set-exclusive-or-identity-test 'nset-exclusive-or list1 list2 #'equalp)))
  		  (t
  		   (set-exclusive-or-identity-test 'nset-exclusive-or list1 list2 test)))
  	    (if test-not
  		(set-exclusive-or-identity-test-not 'nset-exclusive-or list1 list2 test-not)
  		(if use-hash
  		    (set-exclusive-or-identity-eql-hash 'nset-exclusive-or list1 list2)
  		    (set-exclusive-or-identity-eql 'nset-exclusive-or list1 list2)))))))
  
  ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  ;;;
  