From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Tino Calancha Newsgroups: gmane.emacs.devel Subject: Re: [ELPA] New package: hap.el Date: Thu, 2 Mar 2017 15:52:42 +0900 (JST) Message-ID: References: <8760jtgymr.fsf@calancha-pc> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; format=flowed; charset=US-ASCII X-Trace: blaine.gmane.org 1488437583 8514 195.159.176.226 (2 Mar 2017 06:53:03 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 2 Mar 2017 06:53:03 +0000 (UTC) User-Agent: Alpine 2.20 (DEB 67 2015-01-07) Cc: Tino Calancha , Emacs developers To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Mar 02 07:52:50 2017 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cjKbZ-00012D-Vq for ged-emacs-devel@m.gmane.org; Thu, 02 Mar 2017 07:52:50 +0100 Original-Received: from localhost ([::1]:50741 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cjKbg-0006Zy-2r for ged-emacs-devel@m.gmane.org; Thu, 02 Mar 2017 01:52:56 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:53642) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cjKba-0006Zl-6r for emacs-devel@gnu.org; Thu, 02 Mar 2017 01:52:51 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cjKbX-0002Kv-50 for emacs-devel@gnu.org; Thu, 02 Mar 2017 01:52:50 -0500 Original-Received: from mail-pg0-x243.google.com ([2607:f8b0:400e:c05::243]:33212) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1cjKbW-0002Ki-Ul for emacs-devel@gnu.org; Thu, 02 Mar 2017 01:52:47 -0500 Original-Received: by mail-pg0-x243.google.com with SMTP id x17so8349417pgi.0 for ; Wed, 01 Mar 2017 22:52:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:date:to:cc:subject:in-reply-to:message-id:references :user-agent:mime-version; bh=ucl8rVTXHrMSKg3wKsrxm7zTrs7L65/Zumh9yPXovJE=; b=R34qfUEVTQbfi68wG3tuzhYWqy9Pb7rjs0W4S0CRoj3TdwCXPepLDWhGySJzI5OIdl kYoRkCCn2AkIIUUL3IAT5pNEPT9LxX2fznClOZFkNmRKGCMHQmBGj3PfZ9hfTydafGYR Ljk01jHPbdYk9+xB7bQnHgCoq4wzaZdjzgJfz+Y8SFZNCQdBVH45P3PrhYHMKBu2/R6t DBxN6Tp5YjfisoyA4bXUdAitm8w16ywX+fIU98olrhsl9yDKe1gxw/O57J+C0O3RCili Qw5U+WK6vd8UFgQSXy3J3CP9h03r57H30tCzlAPTWkcuSiuB+hAlsipOGooOqsSxktOS XFpQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:date:to:cc:subject:in-reply-to:message-id :references:user-agent:mime-version; bh=ucl8rVTXHrMSKg3wKsrxm7zTrs7L65/Zumh9yPXovJE=; b=Gr9qM/mwrxBDQBTmF14+WGHY6R91ZGX5PNxPVXhIcbT7ea/e4lI3rl0T5ThRsG/2js PGZzfySC6A6z4Jz1sPLMaTGfsGd/DRFmBoK9kq5ANqDZiwkAbLXHGdWjB+MzvG5CvMHR Ne2NpeUhvM6caTsLkcRD5EHLzv71KMS/vdJ3xIeoOElm6TDdfZJwovxQohsbEuHAjvej Vs4G8/TWRY2KGug//IeBqE2Jo72cM+gYc5wflIrixGR1zDEEsDIkvbqBHnx4Dp9hNmmV kb0d4JFMmerBM3J47MetJfKdvXc+AwK+LErX91FKASklQIjCTe9/+tVkBv7v4xA9yct+ CjeQ== X-Gm-Message-State: AMke39maOZpA3BGt3DBCdQevTxa1AVDbBwTE02DAi5JLWD/wNOwP7nPRUVCD1Ndgc3q0tw== X-Received: by 10.99.63.193 with SMTP id m184mr13865602pga.123.1488437565966; Wed, 01 Mar 2017 22:52:45 -0800 (PST) Original-Received: from calancha-pc (104.81.147.124.dy.bbexcite.jp. [124.147.81.104]) by smtp.gmail.com with ESMTPSA id r13sm14350611pfg.55.2017.03.01.22.52.44 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 01 Mar 2017 22:52:45 -0800 (PST) X-Google-Original-From: Tino Calancha X-X-Sender: calancha@calancha-pc In-Reply-To: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2607:f8b0:400e:c05::243 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:212696 Archived-At: On Thu, 2 Mar 2017, Stefan Monnier wrote: >> In hap.el, optionally, you can convert from alist to hash table, >> so that: >> (let ((map '((1 . a) (1 . foo) (2 . b)))) >> (equal >> (alist-get 1 map) >> (gethash 1 (map-into map 'hash-table)))) >> => t > > Oh, you've just found a bug in map.el. The intention is that it returns t. Wow, i'm on fire! Neither Michael Jordan in his best old times. >> We might do plist-get setf-able as it was done for alist-get. > > That seems to be unrelated to hap.el/map.el, or am I missing something? Yeah, basically. I said because `map-put' or `map-delete', for instance. Maybe the implemention is simpler if we make `plist-get' setf-able.