From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Thorsten Jolitz Newsgroups: gmane.emacs.help Subject: Re: design ponderings: plist to alist Date: Wed, 16 Apr 2014 10:16:19 +0200 Message-ID: <87zjjl1ygc.fsf@gmail.com> References: <87a9bl7rkd.fsf@zigzag.favinet> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1397636152 25660 80.91.229.3 (16 Apr 2014 08:15:52 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 16 Apr 2014 08:15:52 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Apr 16 10:15:45 2014 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1WaL0S-0000fq-FI for geh-help-gnu-emacs@m.gmane.org; Wed, 16 Apr 2014 10:15:44 +0200 Original-Received: from localhost ([::1]:53376 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WaL0R-0007db-QB for geh-help-gnu-emacs@m.gmane.org; Wed, 16 Apr 2014 04:15:43 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54738) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WaKzw-0007bG-SK for help-gnu-emacs@gnu.org; Wed, 16 Apr 2014 04:15:18 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WaKzq-0008NP-Va for help-gnu-emacs@gnu.org; Wed, 16 Apr 2014 04:15:12 -0400 Original-Received: from plane.gmane.org ([80.91.229.3]:51644) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WaKzq-0008LO-Ow for help-gnu-emacs@gnu.org; Wed, 16 Apr 2014 04:15:06 -0400 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1WaKzl-0007iF-VB for help-gnu-emacs@gnu.org; Wed, 16 Apr 2014 10:15:01 +0200 Original-Received: from e178188222.adsl.alicedsl.de ([85.178.188.222]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 16 Apr 2014 10:15:01 +0200 Original-Received: from tjolitz by e178188222.adsl.alicedsl.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 16 Apr 2014 10:15:01 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 58 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: e178188222.adsl.alicedsl.de User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) Cancel-Lock: sha1:ausFEzYQlDKt0QIel3X0MxKU1f0= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 80.91.229.3 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:97146 Archived-At: Thien-Thi Nguyen writes: > includes a function to convert plist (succinct to humans) to alist > (succinct to computers). I spent 20 minutes poking around the Emacs > source searching for something builtin, to no avail. Are you aware of package kv.el from Nic Ferrier? ,-------------------------------------------------------------------------------- | 43 matches for "^[[:space:]]*(def[maus][^elt][a-z]*\*? " in buffer: kv.el | 37:(defun kvalist->hash (alist &rest hash-table-args) | 48:(defun kvhash->alist (hash &optional func) | 68:(defun kvfa (key alist receive) | 77:(defun kva (key alist) | 83:(defun kvaq (key alist) | 89:(defun kvaqc (key alist) | 97:(defun kvassoc= (key value alist) | 107:(defun kvassoqc (key alist) | 115:(defun kvassoq= (key value alist) | 129:(defun kvmatch (key regex alist) | 134:(defun* kvquery->func (query &key | 177:(defun kvplist2get (plist2 keyword value) | 183:(defun kvthing->keyword (str-or-symbol) | 192:(defun kvalist->plist (alist) | 201:(defun kvacons (&rest args) | 205:(defun keyword->symbol (keyword) | 213:(defun kvplist->alist (plist &optional keys-are-keywords) | 228:(defun kvalist2->plist (alist2) | 234:(defun kvalist->keys (alist) | 238:(defun kvalist->values (alist) | 242:(defun kvalist-sort (alist pred) | 246:(defun kvalist-sort-by-value (alist pred) | 250:(defun kvalist->filter-keys (alist &rest keys) | 258:(defun kvplist->filter-keys (plist &rest keys) | 273:(defun kvplist2->filter-keys (plist2 &rest keys) | 278:(defun kvalist2->filter-keys (alist2 &rest keys) | 283:(defun kvalist2->alist (alist2 car-key cdr-key &optional proper) | | 317:(defun* kvalist-keys->symbols (alist &key (first-fn 'identity)) | 329:(defun kvalist2-filter (alist2 fn) | 337:(defun kvidentity (a b) | 341:(defun kvcar (a b) | 345:(defun kvcdr (a b) | 349:(defun kvcmp (a b) | 356:(defun kvqsort (lst) | 368:(defun kvalist-set-value! (alist key value) | 378:(defun kvdotassoc-fn (expr table func) | 412:(defun kvdotassoc (expr table) | 416:(defun kvdotassq (expr table) | 420:(defun kvdotassoc= (expr value table) | 428:(defmacro kv--destructuring-map (map-function args sequence &rest body) | 436:(defmacro kvmap-bind (args sexp seq) | 449:(defun kvplist-merge (&rest plists) `-------------------------------------------------------------------------------- -- cheers, Thorsten