From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?UTF-8?B?Sm/Do28gVMOhdm9yYQ==?= Newsgroups: gmane.emacs.devel Subject: Re: cond* Date: Thu, 21 Dec 2023 09:50:59 +0000 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="4481"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: rms@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu Dec 21 10:52:12 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 1rGFiu-0000vp-7W for ged-emacs-devel@m.gmane-mx.org; Thu, 21 Dec 2023 10:52:12 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rGFi3-0006T6-6z; Thu, 21 Dec 2023 04:51:21 -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 1rGFhz-0006Sg-Lc for emacs-devel@gnu.org; Thu, 21 Dec 2023 04:51:15 -0500 Original-Received: from mail-lj1-x22f.google.com ([2a00:1450:4864:20::22f]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rGFhy-0002g2-0A; Thu, 21 Dec 2023 04:51:15 -0500 Original-Received: by mail-lj1-x22f.google.com with SMTP id 38308e7fff4ca-2cc6eecd319so6323011fa.1; Thu, 21 Dec 2023 01:51:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1703152271; x=1703757071; darn=gnu.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=svll3mBRkrykgdt9kj+Cfh8aBut8h3h/fylln88xFbo=; b=IcNHsd305s/a5t2seaZXa8ptNPCmijuBKYFvVb5OVbaXvgNmOP0toNtzdf0galWes1 gAgxsII4FciebfsZB8jAUtsJ8wVIj20btTGbiiAJukDQjc3ZRu+Ny9YeEmh4cGoiccSb EHWbAlQSzlMOoPuwq5edYDsArTRZvLL4cAx8yt48JElCrKOauuXArDhSzNjluQK+x1zB Gh0BV/RUBAXXZqjjsEGwDp6O1AdaVJG1xD8gmKmec/DHCHNUHeLKOl+sybR8JKw3V8Og 6mgMEy6E8NqSWzpiMvJg1RsQo7A1E+W+L3ED9Y/PpNg9en9EGOU6fqGxP8b7Jk1WsTD8 MCBQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703152271; x=1703757071; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=svll3mBRkrykgdt9kj+Cfh8aBut8h3h/fylln88xFbo=; b=E8YrX16wPR1qXvmW2AZLWyIO0cY57+FYEwQSQnnMXIFS+mgpMVpHmXmlNiMpLBLQeN VQF3vSQ8wTOI8l0fehLsPCOHo/hA84ZNZb+hcxZjsnBlt6Ty51xZnG7U9qlP6uEp+zN4 vS8ft4y5UBIZFPn5sipahWnom2CwrqOknfRxRHN5wvGlyNfkJ1fYxkQaTV4wqxQkFmsQ Jxka4o5hSVI4IfYQfshvK5Tm6CDg4mnzlTk45+Pll1xvx8fVPmQ5+EmULG7r8y0gKCc0 8FyqAcp9usPk/J5hmvWwzUF/yYUuCMw3uYzn6Y5+kPCR+fO3+uF1E1IqV3aOz5HUZ6Mb xpYg== X-Gm-Message-State: AOJu0YyMYa/QFRTAqSlLtDKUknfZkX76s7vNNZpmnxGKJpkSGh3oMLoC LcY4UkRl5a8RLmTb2zRYju4PZxU+Sa3q5DFiILhl6BA3ySM= X-Google-Smtp-Source: AGHT+IGiJxiCVD3iUPoSK/hsEFgF1uJhsQab6/zPk8o1sJg94jfun2OzH/nH7zYxqYJ4Y+r+pn6AsSc5hBqeFLQ8ofM= X-Received: by 2002:a05:651c:207:b0:2cc:7127:ebb1 with SMTP id y7-20020a05651c020700b002cc7127ebb1mr3435688ljn.81.1703152271249; Thu, 21 Dec 2023 01:51:11 -0800 (PST) In-Reply-To: Received-SPF: pass client-ip=2a00:1450:4864:20::22f; envelope-from=joaotavora@gmail.com; helo=mail-lj1-x22f.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action 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:314034 Archived-At: On Thu, Dec 21, 2023 at 4:20=E2=80=AFAM Richard Stallman wrot= e: > Are you talking about this? > > (cond* > ((match* `(expt ,foo ,bar) x)) > (t > (something-that-depends-on FOO BAR) ; is this how to use it? > ) Yes. It is very simple. In Elisp or any Lisp I know, forms that introduce bindings are also the containers of any forms that use such bindings, most notable case being (let VARLIST BODY...) This principle is not a cosmetic convention. It's essential as it makes things like following the 'foo' in: (dolist (foo '(1)) (funcall (lambda (foo) (let ((foo 2)) (message "%" foo))) 3)) easy, even to the beginner, because one just travels up the form tree to a notable binding-introducing form. A given match* form in a given use of your cond* doesn't have this property. It introduces bindings that can be used by other forms _outside_ it and this leads to ambiguity. Adam noted this too. > So you're judging them by a criterion they do not try to fit. Well, I can't guess your intent, but I can tell you skipping this criterion is a bad idea, IMO. Jo=C3=A3o