Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:121022 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 4016 invoked from network); 8 Sep 2023 22:16:24 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 8 Sep 2023 22:16:24 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id C4CEE1804AC for ; Fri, 8 Sep 2023 15:16:20 -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=0.6 required=5.0 tests=BAYES_50,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, 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-pg1-f174.google.com (mail-pg1-f174.google.com [209.85.215.174]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature ECDSA (P-256) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Fri, 8 Sep 2023 15:16:20 -0700 (PDT) Received: by mail-pg1-f174.google.com with SMTP id 41be03b00d2f7-573d52030fbso1876767a12.0 for ; Fri, 08 Sep 2023 15:16:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1694211379; x=1694816179; darn=lists.php.net; h=to:subject:message-id:date:from:mime-version:from:to:cc:subject :date:message-id:reply-to; bh=V9toMV79xf1jpX6Oqx15mPVAo3nBDobpDNCIYGyCti0=; b=XKei6AIANg17EAxQZj+eGxRRAhFtg7/GUeAgJRvK3su9vq5qzXes9WkwB8/L20kxsu pSTCaFY4UqzeeIopvyvnrSI1eo9lpnxMmR3ECidMSJGJw9LbNEGj0V98zBWSaSwonmKi XD5eOw6+m9Oe42OTlYtZ52nLzdsiwwG8iJy4/dEzqh1ExyxXahmAiSeQZjqfUFF6A6rH xoF39fnfexB8nF5+AkVlTEdZ04HPAn5CZg2H55dM9hrTgloXaz6uGL1tn2HNmoTgo63M SUC6IVDd2B7mdw7pZ7omK00JDiNm1ULiA0+hg5qUeRtfuGIA4DxMW3845Et1JmPQkObO Z7hw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1694211379; x=1694816179; h=to:subject:message-id:date:from:mime-version:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=V9toMV79xf1jpX6Oqx15mPVAo3nBDobpDNCIYGyCti0=; b=GHRtuQhStOR7jMvmHnR3/Wt8NSI5liz97KNJevxsUEDrR79yBjujI0XSJgZwqmvdoN GHS4NYH3EA1reqUwA34GZN/x5Xm/5bOgiX9a5KdesXTW5jwFn2DhbLoFapMjOVDUIYK4 du906Fhhfz0mJE/DwNNpeAZoLByWfxiY4SagaIJk8EEiJkHEORdvWt/RCGPTw9BATEEZ sePuTGcJgpoApUmnd1IXBDnNSqraUxFR/B6gke1ZPS45DbcOCPrFVf+Ti+JkAWMWQRxj TQuY6j4pqdi5W3xvNrFvfMvUdz2U4JV4swm4+ic+2sv7YXU8KP8TwxOJAto4fTOlal9R +2kg== X-Gm-Message-State: AOJu0Yzx/b/78U3AIeojUvO61F2MhkgeKIoARj+yQVoahWGsF6MqWABB 515s9o5dMhCH0KrxH/qHhCMBuxIO9HCndZQg1sSTIUlRB5s= X-Google-Smtp-Source: AGHT+IHhUgONN5Z/NP6j8mYHi2ksdGy/R0TWNeGsSJYsEmXrgM0ulZEQI4YbudTTZ0FhHCUIvSefZzhGQwbi0r8XGuo= X-Received: by 2002:a17:90a:5ac4:b0:26b:6a2f:7d90 with SMTP id n62-20020a17090a5ac400b0026b6a2f7d90mr3948671pji.23.1694211378780; Fri, 08 Sep 2023 15:16:18 -0700 (PDT) MIME-Version: 1.0 Date: Sat, 9 Sep 2023 00:16:07 +0200 Message-ID: To: PHP internals Content-Type: text/plain; charset="UTF-8" Subject: [RFC][Draft] Match block From: tovilo.ilija@gmail.com (Ilija Tovilo) Hello everyone I've been working on match blocks over the last few weeks. https://wiki.php.net/rfc/match_blocks I've already shared it in R11 and got conflicting feedback, which makes me unsure on how to proceed. We have a few options. 1. Add blocks only to match, possibly adding blocks to other constructs in separate RFCs (the approach of this RFC) 2. Support block expressions as a language-level concept, analogous to https://doc.rust-lang.org/reference/expressions/block-expr.html 3. Do nothing The two main complaints/questions I've gotten was whether this approach is the right one, and whether the syntax can be improved. The RFC tries to go into detail on explaining the rationale for the chosen approach. Additionally, it proposes a few alternate syntax options, although none of them are very satisfactory. At this point I'm unsure whether a proposal can satisfy all camps. Let me know if you have any thoughts/ideas. Ilija