Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:115579 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 96591 invoked from network); 24 Jul 2021 20:38:02 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 24 Jul 2021 20:38:02 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 3FB07180510 for ; Sat, 24 Jul 2021 14:04:16 -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.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,HTML_MESSAGE, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,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-ej1-f54.google.com (mail-ej1-f54.google.com [209.85.218.54]) (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 ; Sat, 24 Jul 2021 14:04:15 -0700 (PDT) Received: by mail-ej1-f54.google.com with SMTP id he41so9201821ejc.6 for ; Sat, 24 Jul 2021 14:04:15 -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=dVUhYykvUY+F93wwl4BBUlj1QsZ493ZEbJwD35bDHxU=; b=LvdIHZ6J8XGmX7uZV30UwrMhl3tTDwBn30QtdKslq2qT+IUhZxlaanIAchYcPguyhT 0FKCpi6D1qpI8GJ7eo/XoQnSAlGGByiFdn0k5afFO5XcEMf64JvISNE+qQ6Z64b/bxHN HkP6x83+33cUPQeXz4geCS6uzpcCVjw9q/qWkulBFdBqWJ0FvMb5JYd3ePmpQs1ihxJZ vvie41s5fO1+p/mLQY/44a8jpXykUsfZ4WJ0eoPryz8Urpi9ff2W8Jlf30tlmc912KOF WV0YYi+il3hpKKyd0Of7JiCFcZt5WF21q669iKqm04NYc0AZ/DuoZMaLbeQ8pBQRnXjB 2SKA== 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=dVUhYykvUY+F93wwl4BBUlj1QsZ493ZEbJwD35bDHxU=; b=t78jLMJZ5yMwNDX/XiSnmtriRqJcu1wTnoOtF1dJOt6n9tG9o3oKHjhjYfuh06TjFg Yc5B1DOWC2CYGNNsSwOAK/J+A5i1wmu/UIZiwjCHqJEjL8AfojrUkSKr7BqQJfdquwQC JuyljRWP9WlX6JfHEObZJFTewZ+t6NFXUhKOc8lGHu+mT9E1R59J0RYhPOhislxkHvKE lxPG+0eGZzUefwnOqoKJp94kpu3SxMtkE78+RUkRUvIZBMq6AQQENvY7np5NbzwUwHQn +5IzYu1I6ZYRQgyc+k7BO0Rf7g903fBetI2l/6VM1YyRFagPVJaYxtqIztqv8tcfLDeg oLag== X-Gm-Message-State: AOAM53357W7wUoTYquBDCcL5w+F+ZfSCkGvf0/RKXRZvM2bnyLBVEuLq af9jx/zZ41dnKOuAjAAyun+542fGWg5cbzdPK6I= X-Google-Smtp-Source: ABdhPJx15xHAq9fQKXn3ud5j7Dhw+DTP1l9229GFmMrvdupio176SAKWW80m52RWfZFqmKvYdEB1JM9qcLT+oAequuE= X-Received: by 2002:a17:907:3e02:: with SMTP id hp2mr10344615ejc.4.1627160649940; Sat, 24 Jul 2021 14:04:09 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: Date: Sat, 24 Jul 2021 23:03:57 +0200 Message-ID: To: Nicolas Grekas Cc: PHP Internals List Content-Type: multipart/alternative; boundary="00000000000088459705c7e4dc76" Subject: Re: [PHP-DEV] [RFC] Nullable intersection types From: drealecs@gmail.com (=?UTF-8?Q?Alexandru_P=C4=83tr=C4=83nescu?=) --00000000000088459705c7e4dc76 Content-Type: text/plain; charset="UTF-8" On Fri, Jul 23, 2021, 11:58 Nicolas Grekas wrote: > Hi everyone, > > as proposed by Nikita and Joe, I'm submitting this late RFC for your > consideration for inclusion in PHP 8.1. Intersection types as currently > accepted are not nullable. This RFC proposes to make them so. > > I wrote everything down about the reasons why here: > https://wiki.php.net/rfc/nullable_intersection_types > > Please have a look and let me know what you think. > Given the discussion, I think it might be better to remove all other syntax alternatives other than (X&Y)|null. There are persons here that mentioned they wish to wait for 8.2 than agree with 2/3 on the feature where the syntax might not be the most forward compatible one. One alternative could be to agree on a voting scheme where there could be 3 options: - No. - Yes, but only with (X&Y)|null. - Yes, any syntax, with additional vote on preferred syntax aiming for 2/3 on the second or third option. Regards, Alex --00000000000088459705c7e4dc76--