Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!aramis.rutgers.edu!paul.rutgers.edu!sparky.rutgers.edu!gaynor From: gaynor@sparky.rutgers.edu (Silver) Newsgroups: comp.emacs Subject: Re: Why does completion require an alist? Message-ID: Date: 1 Sep 90 07:08:24 GMT References: <9008311659.AA14901@STEVE-DALLAS.MIT.EDU> Organization: Rutgers Univ., New Brunswick, N.J. Lines: 16 bjaspan@ATHENA.MIT.EDU ("Barr3y Jaspan") writes: > Why does read-completion require an alist instead of an ordinary list of > strings? Considering that only the car of each element of the alist is used > or returned, it doesn't seem to be a sensible limitation. Just the way things are. Probably turned out that the predominating case was one of using completing-read to grab an association from an alist, eg, (assoc (completing-read "Well, which one? " some-alist) some-alist) I probably don't need to say this, but an easy way to use completing read with a list of strings is to simply mapcar list on the list of strings, as in: (completing-read "Well, which one? " (mapcar 'list list-of-strings)) Regards, [Ag]