|
From: | Kevin Rodgers |
Subject: | Re: best way to get the list of unique keys from 2 alists |
Date: | Mon, 19 Dec 2005 11:50:18 -0700 |
User-agent: | Mozilla Thunderbird 0.9 (X11/20041105) |
Stefan Monnier wrote:
I've got 2 alists of (SYMBOL . "STRING") pairs, and I need to get the list of unique symbol names to pass to completing-read as its TABLE argument: (("SYMBOL-NAME") ...)I'd just do: (completing-read "foo" (mapcar (lambda (x) (symbol-name (car x))) (append list1 list2))) You don't need to remove duplicates.
In 21.4 the TABLE elements must be lists, and duplicates are displayed in the *Completions* buffer. -- Kevin Rodgers
[Prev in Thread] | Current Thread | [Next in Thread] |