Hi Mike,

I’m loving add-auxiliary-notes but it plays havoc with handle-ties when used in conjunction with any of the tie-over-rests, etc. methods.

I’ve added an extra line to the add-auxiliary-notes-aux function which makes everything work nicely. Could this be incorporated into the download, please?

(defun add-auxiliary-notes-aux (pitch-list &key (num-notes 3) (interval 1)
                                             ignore (activity-level 5)
                                             destructively verbose)
  (let* ((igns (loop for p in (force-list ignore) collect
                    (frequency (make-pitch p))))
         (most-used (hash-least-useds (pitch-list-stats pitch-list)
                                      :ignore igns :num num-notes
                                      :auto-inc nil :invert t))
         (result '())
         (als (loop repeat num-notes collect (make-al 2))))
    (loop for thing in pitch-list
       for freq = (get-freq thing)
       for pos = (position freq most-used)
       do
         (push (if (and (atom freq)     ; don't fiddle with chords
                        pos
                        (active (nth pos als) activity-level))
		   ;; DJR - Mon Jun 27 18:34:35 BST 2016
		   ;; The following line stops the function from
		   ;; disrupting handle-ties
		   (unless (or (is-tied-to thing)(is-tied-from thing))
		     (if (event-p thing)
			 (prog2
			     (when verbose
			       (format t "~&At bar ~a, transposing ~a "
				       (bar-num thing) (get-pitch-symbol thing)))
			     (transpose thing interval
					:destructively destructively)
			   (when verbose
			     (format t "to ~a" (get-pitch-symbol thing))))
			 (transpose thing interval)))
                   thing)
               result))
    (nreverse result)))