From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: "Garreau\, Alexandre" Newsgroups: gmane.emacs.devel Subject: Re: dolist considered harmful Date: Thu, 01 Nov 2018 00:01:10 +0100 Message-ID: <871s85souh.fsf@portable.galex-713.eu> References: <877ehxsrji.fsf@portable.galex-713.eu> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1541026828 32030 195.159.176.226 (31 Oct 2018 23:00:28 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Wed, 31 Oct 2018 23:00:28 +0000 (UTC) User-Agent: Gnus (5.13), GNU Emacs 25.1.1 (i686-pc-linux-gnu, GTK+ Version 3.22.11) of 2017-09-15, modified by Debian Cc: Stefan Monnier , Emacs developers To: Noam Postavsky Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Nov 01 00:00:24 2018 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 1gHzTL-0008Do-5X for ged-emacs-devel@m.gmane.org; Thu, 01 Nov 2018 00:00:23 +0100 Original-Received: from localhost ([::1]:33948 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gHzVR-0005dE-Ko for ged-emacs-devel@m.gmane.org; Wed, 31 Oct 2018 19:02:33 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:46137) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gHzUL-0005aR-M5 for emacs-devel@gnu.org; Wed, 31 Oct 2018 19:01:26 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gHzUB-0008NO-1y for emacs-devel@gnu.org; Wed, 31 Oct 2018 19:01:18 -0400 Original-Received: from portable.galex-713.eu ([2a00:5884:8305::1]:46028) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gHzUA-0008MB-Iy for emacs-devel@gnu.org; Wed, 31 Oct 2018 19:01:14 -0400 Original-Received: from localhost ([::1] helo=portable.galex-713.eu) by portable.galex-713.eu with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1gHzU6-0003g8-T2; Thu, 01 Nov 2018 00:01:10 +0100 PGP-FINGERPRINT: E109 9988 4197 D7CB B0BC 5C23 8DEB 24BA 867D 3F7F Accept-Language: fr, en, eo, it, br In-Reply-To: (Noam Postavsky's message of "Wed, 31 Oct 2018 18:44:54 -0400") X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:5884:8305::1 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:230923 Archived-At: On 2018-10-31 at 18:44, Noam Postavsky wrote: > On Wed, 31 Oct 2018 at 18:10, Garreau, Alexandre = wrote: >> >> On 2018-10-30 at 14:39, Stefan Monnier wrote: >> > All this pcase-dolist discussion made me take a second look at dolist >> > and now I wondering whether we should keep it: >> >> This is still extreme: I never saw anyone suggesting to remove anything >> about pcase or its derivative=E2=80=A6 but I can get quite distracted so= metimes >> so maybe I missed it. > > Not pcase, but Alan talked about removing pcase-dolist and other derivati= ves: > > https://lists.gnu.org/archive/html/emacs-devel/2018-10/msg00664.html > > If we can't get quality doc strings for pcase-dolist and friends, I s= ay > we should remove them from Emacs. There are only around 30 occurrenc= es > of pcase-dolist. These are cool, and really beautiful examples of what it means to efficiently (in terms of semantics) generalize a high-level behavior pattern to outside things (if I wasn=E2=80=99t fearing pattern-matching to exageratedly spread, I=E2=80=99d even suggest for these to become the defau= lt as replacement of their non-pcase versions, as I already desired once (I dislike their current syntax but they happen to be potentially backward-compatible to all others lisp (pattern-)match(ing) that I would find acceptable)=E2=80=A6). If ever that much needed I=E2=80=99d like to help improving all these docst= rings so they keep existing. But I feel like there=E2=80=99s a stronger global w= ill to improve these anyway. >> (btw is emacs tail-recursive?), > > Nope. Which is why recursion is not idiomatic. Oh. I once heard emacs was =E2=80=9Ckind of, too, a naive implementation of lisp=E2=80=9D, and each day I discover it is effectively a bit more than I initially though. =E2=80=A6so it may end up with bignums before tail-recur= sion, I wonder if that=E2=80=99s not to be considered very surprising.