From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Mark Oteiza Newsgroups: gmane.emacs.bugs Subject: bug#28254: 26.0.50; SRFI-2 and-let* Date: Tue, 12 Sep 2017 16:21:34 -0400 Message-ID: <20170912202134.GA14004@holos.localdomain> References: <20170902041424.GA21189@holos.localdomain> <87tw0lzn7w.fsf@drachen> <20170902133604.GA27251@holos.localdomain> <20170904011356.GA21128@holos.localdomain> <20170905035548.GB11331@holos.localdomain> <20170909003355.GA3363@holos.localdomain> <87efrcccps.fsf@drachen> <20170912130947.GA23119@holos.localdomain> <87k213oiys.fsf@drachen> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: blaine.gmane.org 1505339480 17434 195.159.176.226 (13 Sep 2017 21:51:20 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Wed, 13 Sep 2017 21:51:20 +0000 (UTC) User-Agent: Mutt/1.9.0 (2017-09-02) Cc: 28254@debbugs.gnu.org, Noam Postavsky To: Michael Heerdegen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Sep 12 22:22:18 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1drrh7-0007hX-SC for geb-bug-gnu-emacs@m.gmane.org; Tue, 12 Sep 2017 22:22:06 +0200 Original-Received: from localhost ([::1]:38405 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1drrhF-0008GH-8A for geb-bug-gnu-emacs@m.gmane.org; Tue, 12 Sep 2017 16:22:13 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:36002) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1drrh8-0008G5-E1 for bug-gnu-emacs@gnu.org; Tue, 12 Sep 2017 16:22:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1drrh5-0002rb-1c for bug-gnu-emacs@gnu.org; Tue, 12 Sep 2017 16:22:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:55937) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1drrh4-0002qo-SC for bug-gnu-emacs@gnu.org; Tue, 12 Sep 2017 16:22:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1drrh4-000246-Id for bug-gnu-emacs@gnu.org; Tue, 12 Sep 2017 16:22:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Mark Oteiza Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 12 Sep 2017 20:22:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 28254 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 28254-submit@debbugs.gnu.org id=B28254.15052477047913 (code B ref 28254); Tue, 12 Sep 2017 20:22:02 +0000 Original-Received: (at 28254) by debbugs.gnu.org; 12 Sep 2017 20:21:44 +0000 Original-Received: from localhost ([127.0.0.1]:36385 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1drrgm-00023Y-CE for submit@debbugs.gnu.org; Tue, 12 Sep 2017 16:21:44 -0400 Original-Received: from mail-qk0-f170.google.com ([209.85.220.170]:37100) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1drrgj-00023G-TY for 28254@debbugs.gnu.org; Tue, 12 Sep 2017 16:21:42 -0400 Original-Received: by mail-qk0-f170.google.com with SMTP id b82so27659980qkc.4 for <28254@debbugs.gnu.org>; Tue, 12 Sep 2017 13:21:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=udel-edu.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=B5OkUiN+jh09ocIVjOoGmqefctKyw1E1zcr3M4/ev8w=; b=KpfVjRIAM2mIghIRKat+r6dd92KNHHuHNdPfRFHpM9O9Auyykq7uCljYlcM5WIr0MN IktPkbJn6yT2rPVdaCsbJQQE8hv5fdRyku6juPdVbYljHDsX9Jqh8MWWdRt/skVXvveF DNQTO4puaKdY90Xe0t2Qd8BFfh/oYK3kXGksUhHjwCouoZnBmzIRz7oVlmX/nmgxWnTJ l85RxrLyaQcpwyBLbcY32HM3V7O5qTwxOLnIMVEtpKz4gZB9SkSgWKhpLlVfrsH3ETJg RahP3vhpKfMaZsJ1TXXRejo7hIjTtk48pk/99Rqi/8JxBnE2B1XJL9dGXUDJCplTdqMB muGQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=B5OkUiN+jh09ocIVjOoGmqefctKyw1E1zcr3M4/ev8w=; b=G9v3Fr/JtD9HKdOLgDtZJlBhW+pbUscWIgDsMqBCTqcJGqQOBmuK6tLxBW3gitMPeo HUgroZaXwhfHkOhysDHB99MPXj4XLegFs4hzwX/5gdz+XdYUmMgp+doiw9a2xJkZyMrA 7AMSFUEp3x6Oj1c2A47jCU7wj1QrVywzC7J8sagJV6EvSJkOHKK1/TeFWVZSi74RQk8m Nd4hChoAFWAFOjHogTFtcBdYEKncuy5IGLkYXKU+BFLfFv/tD8xEtf9iKslqboQ7bPSn vs3TCqQZa2AszokFc43KB+8Cfv4DBi/9jONZ3CQbw21srvWN02Qa1TjIcpua/eApMqLD bF3Q== X-Gm-Message-State: AHPjjUhSDszMsPaLBRkrVqvWq6gMJkLa8DkYKacXfW+3HO+/M1hgBSGE q19/AmGszmEtXy4baZjUufn3 X-Google-Smtp-Source: AOwi7QDNSHTqq3v1D0yGO8f8qXVjR7q4snwiBotWJtc9fRYLgP8xB3gnO7f+BVhZM6mKyZx3QT2W1Q== X-Received: by 10.233.244.5 with SMTP id y5mr21090529qkl.162.1505247696189; Tue, 12 Sep 2017 13:21:36 -0700 (PDT) Original-Received: from holos.localdomain (pool-173-67-36-61.bltmmd.fios.verizon.net. [173.67.36.61]) by smtp.gmail.com with ESMTPSA id g132sm8016762qke.11.2017.09.12.13.21.35 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 12 Sep 2017 13:21:35 -0700 (PDT) Original-Received: by holos.localdomain (Postfix, from userid 1000) id A2F2668221; Tue, 12 Sep 2017 16:21:34 -0400 (EDT) Content-Disposition: inline In-Reply-To: <87k213oiys.fsf@drachen> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:136941 On 12/09/17 at 08:44pm, Michael Heerdegen wrote: > Mark Oteiza writes: > > > > Not really related to your change, but: Maybe we should additionally > > > say that THEN can refer to the bindings made in the VARLIST, but > > > ELSE to none, not even to those that resulted in non-nil values > > > before "failing". > > > > That's not true though--you can refer to the bindings in either branch: > > Hmm, that feels strange. FWIW, all the scheme implementations I looked > at implemented it in a way that binding variables stops after the first > nil. OTOH I would expect that all bindings are only available from the > THIS branch (this is my personal opinion). In our case, we have > something third: always all bindings are visible in the ELSEs, e.g. > > (let ((z 1)) > (if-let* ((nil) (z 100)) > (doesnt-matter) > z)) > > ==> nil > > That doesn't feel right. Yeah, it's a product of how this is written as building a list of shortcircuiting bindings instead of recursively or otherwise--not sure if there's more to it than that. I can't say I fully understood the Guile implementation when I read it last. Worth thinking about. > In `internal--listify': > isn't (or (listp form) (atom form)) always true? Yes, that could instead be (or form (null form)). It's meant to catch things like this: (should (equal nil (and-let* ((nil) (x 1))))) > Secondly, in `internal--build-binding-value-form': > How can it happen that (car binding) is an atom but not symbolp? And if > (car binding) == var is not a symbol, how does the returned binding make > sense? It's an expression, like a number. (should (equal 1 (and-let* ((2) (x 1)))))