From 8eba35e0399f56dd861a1c0b5308c704ce7f9cd4 Mon Sep 17 00:00:00 2001 From: vitaly Date: Tue, 26 May 2009 15:04:41 +0000 Subject: [PATCH] New helper function: elmo-union Makes a union of two possibly unsorted lists. This function is needed for partial update, I forgot to include it... --- elmo/elmo-util.el | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/elmo/elmo-util.el b/elmo/elmo-util.el index f5191fb..b796432 100644 --- a/elmo/elmo-util.el +++ b/elmo/elmo-util.el @@ -485,6 +485,10 @@ Return value is a cons cell of (STRUCTURE . REST)" (setq list (cdr list)))) list) +(defun elmo-union (l1 l2) + "Make a union of two lists" + (elmo-uniq-sorted-list (sort (append l1 l2) #'<))) + (defun elmo-list-insert (list element after) (let* ((match (memq after list)) (rest (and match (cdr (memq after list))))) -- 1.7.10.4