Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:117883 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 6464 invoked from network); 8 Jun 2022 21:23:50 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 8 Jun 2022 21:23:50 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 1AF561804C6 for ; Wed, 8 Jun 2022 16:09:55 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=-1.4 required=5.0 tests=BAYES_00, FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.2 X-Spam-ASN: AS15169 209.85.128.0/17 X-Spam-Virus: No X-Envelope-From: Received: from mail-ej1-f52.google.com (mail-ej1-f52.google.com [209.85.218.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Wed, 8 Jun 2022 16:09:54 -0700 (PDT) Received: by mail-ej1-f52.google.com with SMTP id m20so44174735ejj.10 for ; Wed, 08 Jun 2022 16:09:54 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=tzoGud0oba2P8A83OpV6CGRcUkDKM6ZbG6NauslEWUU=; b=fuPNfrXywBAN0Z23NCahvW0VkcAxT3eYpkyJllm/1YKKCIvTNBS0TGSGbtVCZxOvLs REHGV6k0BWl8yM884cdLdwkdgtItWJz+rk6iPAa++DMfYTe4Dt/AC9e4eHRGvxRBQMEF YfUra4Tb3KxEOWKYjv3bhaI5R6cIMS2ks6iw0xS6eeQtDoly+Hocxesqb244pa4xDLno kxf7nWe061y7+6IW8xhP4nxDlzhIbkxidLGyN1YkOsjs9ecgCMUVsaZEHmv2FLwyzUoV 28CmjqVrojtvlqgNuCf8gK12h1BUtGGLLAzWanh3muMhYBfXle5u3Ie/SpjwI32RG/ZG Yd3g== X-Gm-Message-State: AOAM531VaULby3g3CZcA8wAKk8/j2mxK8oByYRdgEinopDgTQVI+9Znk 8MbC2lYOHMqacYlYFRgWdUi3UB/GjH3MWQ== X-Google-Smtp-Source: ABdhPJzfqW2SM+LF9I+95gbF97TNxq1U9+WrmoFN+XafXwdPmohtsOcnCDWpitpsUMgDL6A0n1P1lA== X-Received: by 2002:a17:906:8501:b0:711:bf65:2a47 with SMTP id i1-20020a170906850100b00711bf652a47mr19672457ejx.150.1654729793060; Wed, 08 Jun 2022 16:09:53 -0700 (PDT) Received: from mail-wr1-f50.google.com (mail-wr1-f50.google.com. [209.85.221.50]) by smtp.gmail.com with ESMTPSA id jg36-20020a170907972400b00701eb600df8sm10346659ejc.169.2022.06.08.16.09.52 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 08 Jun 2022 16:09:52 -0700 (PDT) Received: by mail-wr1-f50.google.com with SMTP id m26so18721257wrb.4 for ; Wed, 08 Jun 2022 16:09:52 -0700 (PDT) X-Received: by 2002:adf:da42:0:b0:212:3a25:5b97 with SMTP id r2-20020adfda42000000b002123a255b97mr34402417wrl.7.1654729792393; Wed, 08 Jun 2022 16:09:52 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: Date: Thu, 9 Jun 2022 08:09:41 +0900 X-Gmail-Original-Message-ID: Message-ID: To: Guilliam Xavier Cc: internals Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Subject: Re: [PHP-DEV] Re: Adding new closing tag =?> for keeping trailing newline From: sji@sj-i.dev (shinji igarashi) Hi, thanks for supporting this! > Maybe just 2 days (of internals and Reddit feedback) is a bit early to > "give up" I kinda thought so too after I declared defeat, but... The Feature Freeze for 8.2 is July 19! The RFC process requires two weeks each for discussion and voting. If we want to add something good to 8.2, we have to draft the RFC and start discussing it on internals by June 21 at the latest. So I may be a bit impatient, yeah. Other template engines, such as twig or ERB, often have flexible ways of handling whitespace and newline characters around tags. I'm not trying to make PHP more sophisticated to compete with them, but it seemed that just handling trailing newlines would be easy to implement, doesn't complicate the engine, so I proposed this. I am encouraged by the supportive people and will try to work on it again when I have more time to use. Thanks! -- Shinji Igarashi 2022=E5=B9=B46=E6=9C=888=E6=97=A5(=E6=B0=B4) 21:48 Guilliam Xavier : > > Hi, > > > https://github.com/php/php-src/pull/8708 > > > https://www.reddit.com/r/PHP/comments/v5le6h/adding_new_closing_tag_for= _keeping_trailing/ > > Thanks for proposing! this "feature" bothered me more than once... > Maybe just 2 days (of internals and Reddit feedback) is a bit early to > "give up" (but I won't blame you either). > > FWIW, the Twig templating engine has distinct delimiters for output > ({{ ... }}) and control ({% ... %}), and the former does *not* eat > newline; for the latter you can use ~%} > (https://twigfiddle.com/54daye), and there are other "whitespace > control" options > (https://twig.symfony.com/doc/3.x/templates.html#whitespace-control). > > For PHP, if we could ignore BC, I would rather have ?> not eat > newline, and add an optional way to do it; but we can't, so I guess > the opposite (e.g. your =3D?>) is the best we could hope for. > > Regards, > > -- > Guilliam Xavier