Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:110619 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 91832 invoked from network); 17 Jun 2020 09:46:09 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 17 Jun 2020 09:46:09 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 28F801804CB for ; Wed, 17 Jun 2020 01:31:48 -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.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2, SPF_HELO_NONE,SPF_PASS 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-vs1-f46.google.com (mail-vs1-f46.google.com [209.85.217.46]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Wed, 17 Jun 2020 01:31:47 -0700 (PDT) Received: by mail-vs1-f46.google.com with SMTP id m25so881089vsp.8 for ; Wed, 17 Jun 2020 01:31:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=KcAlxf+SLWAcuN1qcujg7YvdKveyjx525mFylMtJfkY=; b=YN7ZbB5WSS7/u7GtLhe1KTFd/yR+JFIuctMXBdjtxs0jQI29Htx78vrFLIIZkUhpC7 gHQYC56RZo+sNchNw9SxJ12I+7iuzxan1FHhbil3HrvErYX257ZHtdgPjVh0mxO0ygIW VsjEKpbhwQb/oLCE1Mn6kgH8eMTTmZTGsXW62QoVHw+P3Fw4aZwdV/+I9KHYqqaydGie ZZjs4ECNrcoMyNUWydh6Zhy9dMg+zflerEWTuMqldkFKWMp1V17dqKjEX51OQO/Ce4ys ADgxF3orZPyg6Ic1OM0MilsUQI1vvK2bIN325AgsGH0gNt0rJUHZtpCQdVUXpswYq2AI 5Z+g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=KcAlxf+SLWAcuN1qcujg7YvdKveyjx525mFylMtJfkY=; b=UgM2LjJZHmFF21U71I+olY3X6My8jff4l8O3mcKkM34kZNNW3qgYOkFMg9m82xEymb JJpLt1/w6k+f+50MRnoMvX0YpKQD5AAX1GgH/FvRJ0PFBu5jhaXU5iHO9PEVUOED8h5O QJEtarxwWX4EddpkrJXSzlhgp2Zem9NpRnyv7HicJ6KyTt3Qt5VEWTRXVL6TTgF3pX7A Gj71lquAQIaQllACR3iQNlOTQu6uyzJburyyTUm/dxNvPUKsH1KqO9m7nY24EFy2+vvZ nd7aP+dBOHjtSqIKoLVRy3povCrog5NpsFGB4iHAGW2ynjj4gLs+6AHi5ICwngzmF7O3 KTOg== X-Gm-Message-State: AOAM530y2YW9RC8jXsgP9aTNRi2wtrrLADDzmCOpolWRYCWbTFmORM0e RUtDH7ilyKfNNkE1UQsVhxWD1CSfKiMGDVbwFPQ= X-Google-Smtp-Source: ABdhPJwFGHqC2zjTIiMs2HG7JnDgze8+fKYwrR3ldHN+doSt4RLqLDMaEZ5DHDBDPndIfVRs5pef9/8Em8ve6C5Ot8Y= X-Received: by 2002:a67:6ec4:: with SMTP id j187mr4766182vsc.35.1592382704764; Wed, 17 Jun 2020 01:31:44 -0700 (PDT) MIME-Version: 1.0 References: <8ADA2EC7-EE07-4429-8F84-1E5ADC7660E6@cschneid.com> In-Reply-To: Date: Wed, 17 Jun 2020 10:31:34 +0200 Message-ID: To: Nikita Popov Cc: Christian Schneider , Benas IML , PHP Internals List Content-Type: multipart/alternative; boundary="00000000000076cc5205a8437d1c" Subject: Re: [PHP-DEV] [RFC] [DISCUSSION] Allow void return type for constructors/destructors From: kocsismate90@gmail.com (=?UTF-8?B?TcOhdMOpIEtvY3Npcw==?=) --00000000000076cc5205a8437d1c Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable > > This PR should also address all of M=C3=A1t=C3=A9's concerns since it mak= es > constructors and destructors always return `void` (even when no explicit > `void` return type is specified). To be clear, my main concern was that declaring a void return type shouldn't be allowed, unless it's actually enforced. Now, it's all fine because you stated your intentions :) However, I am also fine if the void return value is only enforced when the void return type is declared. Additionally, we could emit a deprecation notice/warning when there is no return type declaration, but a value is returned. I think this would be a nice way to immediately give people the possibility to disallow a return value, while being respectful for older code bases. Regards, M=C3=A1t=C3=A9 --00000000000076cc5205a8437d1c--