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: Why shouldn't we have a #if .... #else .... #endif construct in Emacs Lisp? Date: Tue, 29 Aug 2023 11:36:35 +0100 Message-ID: References: <87zg2bosf3.fsf@dataswamp.org> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="00000000000071873606040d635c" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="35698"; mail-complaints-to="usenet@ciao.gmane.io" To: emacs-devel Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Aug 29 12:37:56 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 1qaw6d-00092S-Qp for ged-emacs-devel@m.gmane-mx.org; Tue, 29 Aug 2023 12:37:55 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qaw5l-0001He-14; Tue, 29 Aug 2023 06:37:01 -0400 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 1qaw5i-0001HO-Oz for emacs-devel@gnu.org; Tue, 29 Aug 2023 06:36:59 -0400 Original-Received: from mail-lj1-x234.google.com ([2a00:1450:4864:20::234]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qaw5e-0000Fm-3e for emacs-devel@gnu.org; Tue, 29 Aug 2023 06:36:58 -0400 Original-Received: by mail-lj1-x234.google.com with SMTP id 38308e7fff4ca-2b95d5ee18dso63200971fa.1 for ; Tue, 29 Aug 2023 03:36:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1693305410; x=1693910210; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :from:to:cc:subject:date:message-id:reply-to; bh=A+l93YkL8Onfxi6KCzf3ahNMveyIwPlQu6vJ4iJlLug=; b=jJfpwwhn5nHVgBoJiu+8uAUNv6MGmY0lxrVtxzJSzBNB0YMKP5ANQ2hsEEnxVVyDsD 4MLN1yq3VgySS1IaiXYxEj4csf7zDiTICnvLe8zCX+MRMDTh0fEx1sB0Z28G6gTVRPH4 QhdAtHGq4UApe3vXdcmm/p5g/171mv6gDKckZBLlpS6q33RLwmhAuMMYCEoNVkTZtflL 7TQT7mu6ZPQ7D4A63s2DdjiRChTOvlySRNLczUIFzUbwNGLPuCSoyF/FZ2wBwD6Fc/Lf MfqxyCaHq4V2nJzx3Tdacr0u2/S2/HrvyudCidxBshgZfxvELpL6BWE/TOFbnxdY4hU5 gFCg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1693305410; x=1693910210; h=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=A+l93YkL8Onfxi6KCzf3ahNMveyIwPlQu6vJ4iJlLug=; b=T55sxKc1aEYot6qulgzLzV1l/nQ8FD8FAZhV8yUkpfI83FUONREfwbf3fWV7/oRMOk V1VBo97HpIZUtaM9uwKUkUdKwt8DyiYpk/RPThAMaIPSgg3aRJi6CtSwAKZP8dZxiN39 tJp7Hs0vO+D0S0FhAjH7T+1s5VTzjpjM1A/2OdbBP2v1I8SBqtrNuAJ9mCyT1BjTqCeQ 5nuiwU8rT7woCwpr5uO6JUlfqne46hoS/1i+CqYCTbtb/kpttj0LEuM1cXf3tonQEfHx EBkc6vUUJMPUeQQCJAdb5HwbfiMqh3BS9nxEAy6VWLfUw+8jg76WJzW2Tc6d/32iJwqI cAvA== X-Gm-Message-State: AOJu0YweXBxOW/Mls2yaUUUXCrG3VcG6/0UdRb5MnOmz8wPqTK57MrF8 NibzfCSQj039ybqp5f1Vk9hW4EglZgaMUQlZvscnbsRrFyk= X-Google-Smtp-Source: AGHT+IG2wkWZfUokpTfIXHqmVYFU5R6AI9QEcOOJtOGktiZAasosxoEBs8UI70aQXeC728kdEMZBxPNx9Z25Bve3mK4= X-Received: by 2002:a2e:3004:0:b0:2bc:efa4:2c36 with SMTP id w4-20020a2e3004000000b002bcefa42c36mr9367737ljw.11.1693305409733; Tue, 29 Aug 2023 03:36:49 -0700 (PDT) In-Reply-To: <87zg2bosf3.fsf@dataswamp.org> Received-SPF: pass client-ip=2a00:1450:4864:20::234; envelope-from=joaotavora@gmail.com; helo=mail-lj1-x234.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, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 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:309483 Archived-At: --00000000000071873606040d635c Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Tue, Aug 29, 2023, 03:21 Emanuel Berg wrote: > Alan Mackenzie wrote: > > > In C, we have the very useful conditional compilation > > directives introduced by #if or #ifdef, etc., which end at > > #end. > > Those are directives to the C preprocessor and some people say > it is a sign of weakness such a thing is even necessary to > begin with. > > Let's see if they are right! > > What problem do you have? If we can solve it in Elisp, we > cannot say those people saying that are wrong. > FWIW, Common Lisp has reader macros to solve the problem: http://clhs.lisp.se/Body/24_aba.htm If Elisp had a better, more programmable reader, this would be the way to solve it IMO Jo=C3=A3o > --00000000000071873606040d635c Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
On Tue, Aug 29, 2023, 03:21 Emanuel Berg <incal@dataswamp.= org> wrote:
Alan Mackenzie w= rote:

> In C, we have the very useful conditional compilation
> directives introduced by #if or #ifdef, etc., which end at
> #end.

Those are directives to the C preprocessor and some people say
it is a sign of weakness such a thing is even necessary to
begin with.

Let's see if they are right!

What problem do you have? If we can solve it in Elisp, we
cannot say those people saying that are wrong.
=

FWIW, Common Lisp has reader = macros to solve the problem:=C2=A0http://clhs.lisp.se/Body/24_aba= .htm

If Elisp had a = better, more programmable reader, this would be the way to solve it IMO

Jo=C3=A3o
--00000000000071873606040d635c--