Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:124476 X-Original-To: internals@lists.php.net Delivered-To: internals@lists.php.net Received: from php-smtp4.php.net (php-smtp4.php.net [45.112.84.5]) by qa.php.net (Postfix) with ESMTPS id 8F0951A00B7 for ; Thu, 18 Jul 2024 13:12:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=php.net; s=mail; t=1721308457; bh=Asx9M6xBvZYCWGukqZOFDKWR7L6Dc07z+JC65blsxZs=; h=In-Reply-To:References:Date:From:To:Cc:Subject:From; b=HP7cVFzEp7ykcR0Y+7dwaUxyjF+w+JwMLQM0sykR/SC0GWOrFjAhZ+YWSPSphlrHZ 4lYcgs2f7LcqX7Rc6xOlPMECoBUahTUVhblUoNrCOHxrTchJP0yKJdaSR5d5ekoHkJ Czf51IbmieaSKvueZIeOZVAtyBByNuBsm0eOkWa/YPXSrTwxU6DFl8dlyB7PKOcTlH gGdVyhIevs7EI9/M/YERMJquFCY7D5uQREvLa557LwuoINReV2Ecg1RAGgu1yiDEYr v7Zcmc+wIITkvdRrVoT5MVWYnYFtAJksqS2uSgT2RwnulmntC0az7CsQ7lcg0byK8I zJJvYfczP/itw== Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id C60F618074C for ; Thu, 18 Jul 2024 13:14:16 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 4.0.0 (2022-12-13) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=-0.1 required=5.0 tests=BAYES_50,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,DMARC_MISSING,HTML_MESSAGE, RCVD_IN_DNSWL_LOW,RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS, SPF_PASS autolearn=no autolearn_force=no version=4.0.0 X-Spam-Virus: No X-Envelope-From: Received: from fhigh2-smtp.messagingengine.com (fhigh2-smtp.messagingengine.com [103.168.172.153]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Thu, 18 Jul 2024 13:14:16 +0000 (UTC) Received: from compute9.internal (compute9.nyi.internal [10.202.2.228]) by mailfhigh.nyi.internal (Postfix) with ESMTP id 346FD114022E; Thu, 18 Jul 2024 09:12:45 -0400 (EDT) Received: from wimap25 ([10.202.2.85]) by compute9.internal (MEProxy); Thu, 18 Jul 2024 09:12:45 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bottled.codes; h=cc:cc:content-type:content-type:date:date:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:subject:subject:to:to; s=fm3; t=1721308365; x= 1721394765; bh=Asx9M6xBvZYCWGukqZOFDKWR7L6Dc07z+JC65blsxZs=; b=A TQINjRVm6Xb8ortskSjwzZwScYAI8Rac2YKQlgLMH71757Dr3yNaEQfSxwt8tE5w lkXqqDcd6xIypuc3T/ZbFNbwh4NNwoYcbbekmddWWmlzRO9LwCZw21vC0/9AexcF A3WgkTlrD5p452DPwRWloaE50SNajBdhnRxclaWpi+Jlm8B9ftmoDyNrevJ0WdLU Y6sr1AVZcmsnLjEsj071vtm/8H8wnb0yBGfnpBVac3VFyA6mFyHuKf+Kp0BdAHRB 0o1WVLeDYWlYdCipCwNHjlpmOYMCzy/YNCcua9fcMGxSMA1BBWtbB3DRfho1DceL 1Htu7NqhjSII9Gz+81FQA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:subject:subject:to :to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm2; t=1721308365; x=1721394765; bh=Asx9M6xBvZYCWGukqZOFDKWR7L6D c07z+JC65blsxZs=; b=vraAUoIOXT6KbFE99IyNwrGZaDz/eoCIysMyWDjOJLaK oKlt3v6SwApGSu2Qlt+LV6RL06AQ1KWa8GWXSyykz4XwYL2JmgcnocnB8+Lrl8ej MMKopc86yuOlJD+A0fuVmYLqpZd7+iS5tgQGZWdpW1T5xE2ai0+WjtAmnNYhIgWH pVyu/bAHhmJJ3cO9bdJ1L4cAbp5FkcQhiEVs8F7UIyKJjuuOt6ICqR2RThTvqBKx +s07DDl5sojOdZfhvpc60NSuRrl7Udc8IgEzKjd/FRcncIQiRd1YTxarHIw8+Bni tGEYj6V0U+FhXRzExZSDW+PFqytiwVUYvOkAzf48vQ== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeeftddrgeelgdeiudcutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefofgggkfgjfhffhffvvefutgesrgdtreerreerjeenucfhrhhomhepfdftohgs ucfnrghnuggvrhhsfdcuoehrohgssegsohhtthhlvggurdgtohguvghsqeenucggtffrrg htthgvrhhnpedvheekteelveetfeevgeekgfffvdeuhfelveehvdetiefggedtfeejheet gffhueenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpe hrohgssegsohhtthhlvggurdgtohguvghs X-ME-Proxy: Feedback-ID: ifab94697:Fastmail Received: by mailuser.nyi.internal (Postfix, from userid 501) id C81641040065; Thu, 18 Jul 2024 09:12:43 -0400 (EDT) X-Mailer: MessagingEngine.com Webmail Interface User-Agent: Cyrus-JMAP/3.11.0-alpha0-568-g843fbadbe-fm-20240701.003-g843fbadb Precedence: bulk list-help: list-post: List-Id: internals.lists.php.net x-ms-reactions: disallow MIME-Version: 1.0 Message-ID: In-Reply-To: References: Date: Thu, 18 Jul 2024 15:12:23 +0200 To: "Oliver Nybroe" , "Lily Bergonzat" Cc: "Ayesh Karunaratne" , "PHP internals" Subject: Re: [PHP-DEV] Optional constructor body Content-Type: multipart/alternative; boundary=54bfe7fe66a04174837285be76a17a54 From: rob@bottled.codes ("Rob Landers") --54bfe7fe66a04174837285be76a17a54 Content-Type: text/plain;charset=utf-8 Content-Transfer-Encoding: quoted-printable On Thu, Jul 18, 2024, at 12:11, Oliver Nybroe wrote: > Thanks for sharing previous discussions, I will definitely take a look= at those before writing up the RFC.=20 >=20 >=20 > > If you do with to go with an RFC, I'd like to see if your proposal > addresses whether this syntax should implicitly call > `parent::__construct()`, and if a semi colon is expected or not > (`public function __construct(public int $foo);` vs `public function > __construct(public int $foo)`). > Thank you, these are very valuable points to address in the RFC.=20 >=20 > I can definitely feel that there will be some mixed opinions about sem= icolon vs no semi colon. >=20 >=20 > Best regards > Oliver Nybroe (he/him) Don't forget to bottom post :) I have a feeling a semi-colon is going to be required to disambiguate: public function __construct(protected string $foo) protected string $bar; Without semi-colons, that is perfectly valid and confusing. =E2=80=94 Rob --54bfe7fe66a04174837285be76a17a54 Content-Type: text/html;charset=utf-8 Content-Transfer-Encoding: quoted-printable
On Thu, Jul 18,= 2024, at 12:11, Oliver Nybroe wrote:
Thanks for sharing previous = discussions, I will definitely take a look at those before writing = up the RFC. 


> If yo= u do with to go with an RFC, I'd like to see if your proposal
<= div>addresses whether this syntax should implicitly call
`= parent::__construct()`, and if a semi colon is expected or not
=
(`public function __construct(public int $foo);` vs `public functio= n
__construct(public int $foo)`).
Thank= you, these are very valuable points to address in the RFC. 

I can definitely feel that there will be som= e mixed opinions about semicolon vs no semi colon.
<= div>


Best regards
Olive= r Nybroe (he/him)

Don't forget to bottom post :)
I have a feeling a semi-colon is going to be required to dis= ambiguate:

public function __construct(prot= ected string $foo) protected string $bar;

W= ithout semi-colons, that is perfectly valid and confusing.
=E2=80=94 Rob
--54bfe7fe66a04174837285be76a17a54--