From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Richard Stallman Newsgroups: gmane.emacs.devel Subject: Re: Instead of pcase Date: Fri, 17 Nov 2023 22:04:14 -0500 Message-ID: References: <87fs169mjj.fsf@posteo.net> <093f11a1-57c2-5e56-d39b-26fef1c67cbb@gutov.dev> <25942.25061.217864.329049@retriever.mtv.corp.google.com> <87zfzdcz6z.fsf@posteo.net> Reply-To: rms@gnu.org Content-Type: text/plain; charset=Utf-8 Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="39853"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Philip Kaludercic Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat Nov 18 04:04:45 2023 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1r4BdU-000AAn-I1 for ged-emacs-devel@m.gmane-mx.org; Sat, 18 Nov 2023 04:04:44 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1r4BdH-00079R-Tb; Fri, 17 Nov 2023 22:04:31 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1r4Bd7-0006zO-3h for emacs-devel@gnu.org; Fri, 17 Nov 2023 22:04:21 -0500 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1r4Bd6-0005Vq-Dn; Fri, 17 Nov 2023 22:04:20 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=Date:References:Subject:In-Reply-To:To:From: mime-version; bh=BRUHu+8lx8T4/ig1745BDxbR3H2LzKV4uuOlvuobak8=; b=JYyzMOZAcmOE qYqsgKkPn/+yFPRhif1dDrAKlmzCv/b0ftB63f2y/mJ7IslGVYfwu/QYOnQG72H0HaVTotSYNkGyM AJwo26VqUootnZyOyJy/qjICk18FIgInqCNToHl5be6PVOsNpzq4B0KCQQjgRRXhBK0SjJAJi9HWs xqSwkSvRyYj33+U8H+rozBheqD9e+z1AUeMSh5Ms1aXPqDPiQOErhCpCCGImGwdhCT5Jl5LIQ7vTG JPAcScWInUOch9dfw2AC0GaF8z2re/416LYYlglyDj7KEC7cIUVLE88NDRRF5PgOZpyKN5iesRDIt 6V9CoRbNOU3C//jdLlfBPQ==; Original-Received: from rms by fencepost.gnu.org with local (Exim 4.90_1) (envelope-from ) id 1r4Bd0-000464-TP; Fri, 17 Nov 2023 22:04:16 -0500 In-Reply-To: <87zfzdcz6z.fsf@posteo.net> (message from Philip Kaludercic on Thu, 16 Nov 2023 18:47:48 +0000) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 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-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:312884 Archived-At: [[[ To any NSA and FBI agents reading my email: please consider ]]] [[[ whether defending the US Constitution against all enemies, ]]] [[[ foreign or domestic, requires you to follow Snowden's example. ]]] > (`(,_ . ,(and (pred functionp) f)) (funcall f)) > (`(,hookfun . (,start ,end ,collection . ,plist)) I read the Info documentation of pcase a few days ago and I can't recall the rules for understanding those two pcase clauses. What I recall is that they are not to be interpreted as Lisp expressions. They contain code that looks like Lisp but does not have the same semantic rules as Lisp. `(,_ . ,(and (pred functionp) f)) is not Lisp. `(,hookfun . (,start ,end ,collection . ,plist) is not Lisp either. That list would be meaningful as a Lisp expression but what it means here is different. That is a consequence of the terse little language that pcase defines. -- Dr Richard Stallman (https://stallman.org) Chief GNUisance of the GNU Project (https://gnu.org) Founder, Free Software Foundation (https://fsf.org) Internet Hall-of-Famer (https://internethalloffame.org)