Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:110706 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 17995 invoked from network); 23 Jun 2020 10:07:23 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 23 Jun 2020 10:07:23 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 8742A1804B7 for ; Tue, 23 Jun 2020 01:54:32 -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=-2.6 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.2 X-Spam-ASN: AS3301 81.224.0.0/12 X-Spam-Virus: No X-Envelope-From: Received: from v-smtpout1.han.skanova.net (v-smtpout1.han.skanova.net [81.236.60.154]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Tue, 23 Jun 2020 01:54:31 -0700 (PDT) Received: from [192.168.7.8] ([213.64.245.126]) by cmsmtp with ESMTPA id nehKjTW1AvaXxnehKjpRc6; Tue, 23 Jun 2020 10:54:30 +0200 To: Ilija Tovilo References: <37f1f8fb-0e1b-cc39-f4b6-6c943a731d49@telia.com> <250b7671-2919-9385-c149-931212397e4b@telia.com> <04d86e2d-0815-195a-6111-3034e0ca5918@telia.com> Cc: PHP internals Message-ID: Date: Tue, 23 Jun 2020 10:54:30 +0200 User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.9.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-GB X-CMAE-Envelope: MS4wfIMmd0MAWCPwrII+5oQYgu8YuPy3G38s6zv4XnQ0VzbL6HB4Kjc2X7XIjO7G9KkN2RWDDlEriWe2xT+Awys5t0U2+Iq/TyzlogQv6RJy+RBnTrH1OuW7 GWMPEtBuKY5KUUCr9cpwbm7Ad8e7ywn76Di4Sj53AjyysB5s7OwOVSwp1tUzsONu18IoLDoN0TObd4DwvluAR1E6K+iVA16p16BNFVjUDIz+OweFnSNWRT/g Subject: Re: [PHP-DEV] Re: [RFC][DISCUSSION] Match expression v2 From: bjorn.x.larsson@telia.com (=?UTF-8?Q?Bj=c3=b6rn_Larsson?=) Den 2020-06-23 kl. 10:30, skrev Ilija Tovilo: > Hi Björn > >>> I'd like to announce the match expression v2 RFC: >>> https://wiki.php.net/rfc/match_expression_v2 >> Absolutely so. I was thinking of the case mentioned in v1 RFC when it's used >> as a stand-alone expression. >> match ($y) { >> ... >> }; >> ` Optional? > In this RFC the semicolon is required. Many people thought the grammar > rules for the optional semicolon were confusing which is why I dropped > that feature in this RFC. > > Ilija Ok, thanks for the clarification. The reason for me to bring this up is that I was pondering on if this is the only place in PHP where a semicolon is required after a curly bracket when not used in an expression. If so I a counter argument could that it it is confusing for programmers, not so privy to all the ins and outs of PHP. Anyway, maybe a feature to consider for a future 8.1 RFC. r//Björn