From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: Replace trivial pcase occurrences in the Emacs sources Date: Thu, 01 Nov 2018 20:07:26 +0200 Message-ID: <83va5ghdsx.fsf@gnu.org> References: <83tvlcsnee.fsf@gnu.org> <86mur137n8.fsf@gmail.com> <20181029130132.GB4195@ACM> <20181029134722.GC4195@ACM> <87lg6gifnb.fsf@web.de> <87muqwxs7m.fsf@ericabrahamsen.net> <83h8h3jlyd.fsf@gnu.org> <83efc7jjm2.fsf@gnu.org> <87tvl1poc8.fsf@portable.galex-713.eu> <83zhuth1z7.fsf@gnu.org> <87a7mtnziq.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: 8bit X-Trace: blaine.gmane.org 1541095549 22117 195.159.176.226 (1 Nov 2018 18:05:49 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 1 Nov 2018 18:05:49 +0000 (UTC) Cc: monnier@iro.umontreal.ca, emacs-devel@gnu.org To: "Garreau\, Alexandre" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Nov 01 19:05:44 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 1gIHLk-0005dt-0k for ged-emacs-devel@m.gmane.org; Thu, 01 Nov 2018 19:05:44 +0100 Original-Received: from localhost ([::1]:43386 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gIHNq-00057K-2v for ged-emacs-devel@m.gmane.org; Thu, 01 Nov 2018 14:07:54 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:50448) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gIHNh-00056P-Si for emacs-devel@gnu.org; Thu, 01 Nov 2018 14:07:46 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gIHNe-0003QP-Ml for emacs-devel@gnu.org; Thu, 01 Nov 2018 14:07:45 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:35786) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gIHNe-0003Q8-IO; Thu, 01 Nov 2018 14:07:42 -0400 Original-Received: from [176.228.60.248] (port=3207 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1gIHNd-0000LC-01; Thu, 01 Nov 2018 14:07:42 -0400 In-reply-to: <87a7mtnziq.fsf@portable.galex-713.eu> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e 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:230957 Archived-At: > From: "Garreau\, Alexandre" > Cc: monnier@iro.umontreal.ca, emacs-devel@gnu.org > Date: Thu, 01 Nov 2018 06:21:49 +0100 > > >> > @dfn{Destructuring} of an object is an operation that extracts > >> > multiple values stored in the object, e.g., the 2nd and the 3rd > >> > element of a list or a vector. @dfn{Destructuring binding} is > >> > similar to a local binding (@pxref{Local Variables}), but it gives > >> > values to multiple elements of a variable by extracting those values > >> > from an object of compatible structure. > >> > >> “(car list)” is extracting a value stored in an object, yet it’s not > >> destructuring (though a list is a structure). Nor even is “(cons (car > >> list) (caddr list))” or “(setq a (nth 1 list) b (nth 2 list))”. > > > > You forget the "multiple" part in the description. > > Then you forgot “(cons (car list) (caddr list))” which I proposed later. The values need to be extracted in one go, so the above doesn't qualify. > > "Destructuring" is not a term that Emacs invented. > > Yes, learnt it reading stuff about python and ocaml, afair. > > > You can look it up on the Internet; I think you will find that the > > adopted definitions are similar to what I wrote. > > Yes, and these are wrong. :-) > Wasn’t my definition attempt okay? it even defined three quite used and > intuitive terms. It didn't look like a more clear description to me, no.