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: cond* Date: Mon, 25 Dec 2023 23:03:17 -0500 Message-ID: References: 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="633"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Pedro Andres Aranda Gutierrez Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Dec 26 05:04:23 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 1rHyg2-000AQn-HH for ged-emacs-devel@m.gmane-mx.org; Tue, 26 Dec 2023 05:04:22 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rHyf2-0008FD-Nf; Mon, 25 Dec 2023 23:03:20 -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 1rHyf0-0008De-HF for emacs-devel@gnu.org; Mon, 25 Dec 2023 23:03:18 -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 1rHyf0-0006Dw-7V; Mon, 25 Dec 2023 23:03:18 -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=TZL2hjDeWxDajLdFNLFQzTPaLW/tizDi+VB9YzS0Gks=; b=Rg1evayTmMRB NzjgBi06Tq0/aisq78YORV7T3UBJJdc2vQ5KY7GoQH/H4Srs3g4TbUonKAeUgJETIPPANDEIlI9JV oFQB0/hBmTlWPnshBs4/szE0zvcpO8KJ3K1bPhdpwAAysom18asiP1PAFWT/j8N6RUDC930corVnb 47DTDkFY5i3JGnFDJriDoOHrqRRWCJot1E3Bd5q0xxJtAY2gsPxuECwePYvHL6RX9C2WSQEWNobVF /5vIyyawhAjr9ETkQGrJAcj3NurfrGZOC6JBD2weoh9/CNMSouuDwbd6D/dkXtlAs+FxzO1sgF+t9 w77wOMS8AM+0Z0WdAS/M0A==; Original-Received: from rms by fencepost.gnu.org with local (Exim 4.90_1) (envelope-from ) id 1rHyez-0003MY-IA; Mon, 25 Dec 2023 23:03:17 -0500 In-Reply-To: (message from Pedro Andres Aranda Gutierrez on Sat, 23 Dec 2023 07:17:09 +0100) 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:314223 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. ]]] > wouldn't a clause starting with t be the most natural choice? > Just because it would mimic cond and make things consistent. A no-exit clause in cond* executes unconditionally but does not terminate the cond*. A cond clause that start with t does terminate the cond, which is why it is useful only as the last clause. The no-exit clause in cond* is an extension in capability over cond. It is not the same as any way of using cond itself. Whatever syntax is used to specify a no-exit clause will not be parallel to the syntax of cond. That's not a reason there shouldn't be a new feature. These are the four choices that seem plausible: > * A clause with one element. > * A clause that starts with t. > * A clause that starts with nil. > * A keyword. I am interested in people's preferences between them. If a no-exit clause is indicated by its first element, then a final element in the clause, with no side effects, will make no difference unless that clause is the last clause. But if it is the last clause, there is no need to make it a "no-exit" clause. So you could add a keyword at the end -- :no-exit or :fall-through or whatever you like -- and it would not change anything, but might serve as a kind of comment. A real comment, perhaps `;; no-exit clause', could serve the same purpose. You could add them at the beginning, too. -- 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)