Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:115733 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 51927 invoked from network); 15 Aug 2021 03:55:08 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 15 Aug 2021 03:55:08 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 99F8518053C for ; Sat, 14 Aug 2021 21:26:44 -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-f42.google.com (mail-ej1-f42.google.com [209.85.218.42]) (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, 14 Aug 2021 21:26:44 -0700 (PDT) Received: by mail-ej1-f42.google.com with SMTP id bt14so9915158ejb.3 for ; Sat, 14 Aug 2021 21:26:44 -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=Hw7A9xcEbjYd5pRKwm1RPLVGuQWPwDwYF8EEqR4MhR0=; b=JHHhXKl82QZiPF4EnKOZS2uQyVSPAQp5MXRd/ijhE1bJxaKNKO5ySBz5/RYDZysJa5 0qh/frP5ZazW9pQkT/aPr7egxHu1iifg8yseP+FMr1yUYbkXWY5NloYcu6VADDwV6buI 5b4nigq+RX9PwO6ItTO0ykULiI8Edy0tkEpZBGH3gsNRHllbCa/07ey1brU6aAWVi1pW lChtpoE83ksbLNlmDJZtLBvDcUUX9BiTtnPEUKd2zEyMz16POWeScq4pH5rUt5i8xRVN 8vljTP+oUSx3f+olrHDLTZUUlr0oODVLGlMQiCynLf/vAP6AR3MVllrfK7ZpzfvY5rtD IqPg== 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=Hw7A9xcEbjYd5pRKwm1RPLVGuQWPwDwYF8EEqR4MhR0=; b=CXWUnCHtK8mMiRoi0JNhOEDhTuhiULCXDxDmbnPLhiD87kSkIBR+7Hf6ncY54CpmhG zRkzCzd8O6Iqo7DpsgMoITrBQZlnPWDLzhFYj6bQB/yvCrpPtWIbUA7HETfab0fzPzJ7 dbApbRx/RRziNbvQY4BuPGcaPLNl2jCbMNrjRWaKuV7yiRWR2/yt4inYKmO8rpROVZXK FrWSeCIUi5mZGmkF+BUCaXS+Hv+XCzRLAtaff0Ws4prtwYOcwaazVzOKFA0ovi2JPs3T hHUFexMauIW3rpDpdrSzhSqsIvn+kk6fLBaZUkXqh9fNGORG/a68Dm3Y3dibqr36fida y1XA== X-Gm-Message-State: AOAM5307h8kOuJIPaactfksSs4Tb3kUajyjI99K32Hc4wQpfVEn2xDGM EnpdFwlKEihMAJ6yZ7dPxx2Qb5sz+/Itd+wO2vU= X-Google-Smtp-Source: ABdhPJw9lEmFeGr812qU7IyYErFbnpfuWzeLeP2Rc9ynb6O3cnpEnSeAOhQy6z4TrZhMDOrZzggVgD6PVpRwL+Ftnko= X-Received: by 2002:a17:907:384:: with SMTP id ss4mr4839436ejb.430.1629001602944; Sat, 14 Aug 2021 21:26:42 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: Date: Sun, 15 Aug 2021 06:26:32 +0200 Message-ID: To: Marco Pivetta Cc: Nicolas Grekas , PHP Internals List Content-Type: multipart/alternative; boundary="000000000000e1d2ea05c9917d36" Subject: Re: [PHP-DEV] [VOTE] Nullable intersection types From: drealecs@gmail.com (=?UTF-8?Q?Alexandru_P=C4=83tr=C4=83nescu?=) --000000000000e1d2ea05c9917d36 Content-Type: text/plain; charset="UTF-8" On Sun, Aug 15, 2021, 04:33 Marco Pivetta wrote: > Heyo, just a follow-up. > > On Fri, 13 Aug 2021, 13:30 Marco Pivetta, wrote: > > > Hey Nicolas, > > > > I voted NO on this one. I'm not opposed to nullable intersection types, > > but not in PHP 8.1. > > > > Specifically, I'm waiting for the first RC releases to land in September > > to even start looking at PHP 8.1 support for any of my projects, and > > stability is key. > > > > I also am not on board with the lack of design around reflection API > here. > > > > I just re-checked the RFC, and I'm completely against the reflection design > in here (which I previously dismissed as "oversight"). > > An `(A&B)|null` is **not** a `ReflectionIntersectionType`, but should > instead be a `ReflectionUnionType`. > > > Therefore, adding this to the "NO" reasons, since we'll otherwise have to > live with this mistake for many years to come. > > Just to mention here, `A|null` is also not a `ReflectionUnionType` but a `ReflectionNamedType`, union with null already being a special case. https://3v4l.org/lM9NJ But the fact that these things might not be known clearly and the fact that nullability concept wasn't discussed and agreed on for the type system in general, I also think the feature can wait for 8.2. Alex --000000000000e1d2ea05c9917d36--