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: Replace trivial pcase occurrences in the Emacs sources Date: Sat, 27 Oct 2018 18:56:11 +0200 Message-ID: <87sh0rib10.fsf@portable.galex-713.eu> References: <20151216202605.GA3752@acm.fritz.box> <8760zakb7q.fsf@fencepost.gnu.org> <56892BDA.6060103@dancol.org> <871t9yk98g.fsf@fencepost.gnu.org> <568936F0.3060505@yandex.ru> <87wprqitj5.fsf@fencepost.gnu.org> <56893C8C.3060200@yandex.ru> <87oad2irtd.fsf@fencepost.gnu.org> <5689456A.1010601@yandex.ru> <87egdy8tyz.fsf@fencepost.gnu.org> <56895FDE.4060406@yandex.ru> <8760za8r4a.fsf@fencepost.gnu.org> <87h9iunkcg.fsf@web.de> <87h8hc4xw2.fsf_-_@web.de> <83tvlcsnee.fsf@gnu.org> <87pnw037ar.fsf@web.de> <83ftwvs7y9.fsf@gnu.org> <877ei7mkfh.fsf@web.de> <87a7mze7tl.fsf@web.de> 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 1540659262 23948 195.159.176.226 (27 Oct 2018 16:54:22 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 27 Oct 2018 16:54:22 +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: Eli Zaretskii , Stefan Monnier , emacs-devel@gnu.org To: Michael Heerdegen Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Oct 27 18:54:17 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 1gGRqr-00068s-0g for ged-emacs-devel@m.gmane.org; Sat, 27 Oct 2018 18:54:17 +0200 Original-Received: from localhost ([::1]:37228 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gGRsx-0006RJ-Lg for ged-emacs-devel@m.gmane.org; Sat, 27 Oct 2018 12:56:27 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:46360) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gGRsq-0006R3-O1 for emacs-devel@gnu.org; Sat, 27 Oct 2018 12:56:21 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gGRsp-0004Mz-OB for emacs-devel@gnu.org; Sat, 27 Oct 2018 12:56:20 -0400 Original-Received: from portable.galex-713.eu ([2a00:5884:8305::1]:54234) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gGRso-0004Lr-7j; Sat, 27 Oct 2018 12:56:18 -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 1gGRsh-0003On-JJ; Sat, 27 Oct 2018 18:56:11 +0200 PGP-FINGERPRINT: E109 9988 4197 D7CB B0BC 5C23 8DEB 24BA 867D 3F7F Accept-Language: fr, en, eo, it, br In-Reply-To: <87a7mze7tl.fsf@web.de> (Michael Heerdegen's message of "Sat, 27 Oct 2018 17:19:02 +0200") 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:230736 Archived-At: On 2018-10-27 at 17:19, Michael Heerdegen wrote: > What's then left is the task to replace all pcase forms that can be > trivially rewritten by using case or cond/assoc. I must admit that > I'm very skeptical about this now. Not only that we would only > replace exactly these pcase occurrences that are really trivial to > read for anybody, which could be, at the end, counterproductive for > those people who dislike pcase because the pcase forms left are the > harder ones (Eli, I know you don't think like that). > > I also saw that people have very different likings, independent from > pcase. Say, we have one third of people who want to keep pcase in > these cases, one third who want to replace it with cl-case, and one > third who want cond or assoc instead. We have a clear majority > against pcase. But we also have a clear majority against cl-case, and > a majority against cond/assoc. First of all, on a practical ground, I=E2=80=99m not sure anything has been= that democratic yet, or anybody has found a that-much democratic process to be useful (at least it is complex to, well, process)=E2=80=A6 But, as the question is raised, that recalls me a lot Arrow=E2=80=99s parad= ox: normally this is the moment I notice you that each one of these thirds may have a preference too about the two forms they dislike (or only like less; for instance I might be a fan of case but prefer cond and assoc to pcase (or the other way around)), so we might ask a list of preferences rather than a single preference, and Arrow=E2=80=99s paradox says this issue keep going as in the end the comparisons may be A > B > C > A. Fyi, one solution of this paradox, is to allow multiple equalities (such as giving preferences in the form A =3D B > C =3D D), and do a median rather than a average/direct-superiority-count-compare, or, in a more intuitive, developed and straightforward way: =E2=80=9Cin a ringle round, g= ive a notation mark to each preference, then for each preference, take their median score, take the winner(s), and if several, the one who won by this score by more voices=E2=80=9D (very unlikely to get equalities). More pretty interesting documentation on arrow paradox: