Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:127563 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 lists.php.net (Postfix) with ESMTPS id 1EE081A00C1 for ; Tue, 3 Jun 2025 15:46:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=php.net; s=mail; t=1748965484; bh=AWoii74TtQWcUZTP5qUo131hVTpLRD/B7+NI/b8WvYU=; h=Date:To:From:Cc:Subject:In-Reply-To:References:From; b=Y0OMM9v6/e5amSlyWPrx1V48fjozRni3E6wEz2ihs0J8h5hNtAIHMVShHUb6VsN+M jLkR4zrLynEOXkRoNl4sZyIWJNEHFDjetIBl9BCEPFSYo2FqRLc0RYBdfXyWR91I/G th/g3RaoInxNMfJ2ToVbfXNlzr6E5oJ+Iv2j3AyUp/jpR1VFXRan2ev8bOizSAKo1z LYL/qyDRD965JYzVqLvfCYlNUNg/TnPbNFpZxAgwBxQxCpoH3cKReWfHV+1GEB9Nhq F94O4LtlVE3k1DQliMvM+HgIMg7WU4Y/ggzgFUMKCbWFQCBh7Vdib2QcZ8wwo7i0wG 37+4+wU7tis6w== Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 3C546180646 for ; Tue, 3 Jun 2025 15:44:43 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=-0.4 required=5.0 tests=BAYES_50,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,DMARC_PASS,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,SPF_PASS autolearn=no autolearn_force=no version=4.0.1 X-Spam-Virus: Error (Cannot connect to unix socket '/var/run/clamav/clamd.ctl': connect: Connection refused) X-Envelope-From: Received: from mail-4323.protonmail.ch (mail-4323.protonmail.ch [185.70.43.23]) (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 ; Tue, 3 Jun 2025 15:44:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gpb.moe; s=protonmail3; t=1748965603; x=1749224803; bh=AWoii74TtQWcUZTP5qUo131hVTpLRD/B7+NI/b8WvYU=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector:List-Unsubscribe:List-Unsubscribe-Post; b=bnf5EczwCcCtvZ0HvMl8fhirY8cyEDQl06zhSKIc4QmJ0az8TTpuLkmBizotygTNB g3BL9mnxS4kX5vGvUzDxYWBDhdllljF/WzML4QpQ3qltTkg2YAZxMu/tQ6lu77rPSG FOoGy8m2FrPflfYplJEzidqstJcA0MPz7cg2hJWxwIGRPE3G/D/mFrQv2bqkQKhxIU HYkXiZGyvBmWEtkxIGxhQlDCB9qdb38DddkiyxEC/rWTXtYN8lrs0n099TNNtpE8CG zpjPBwUuICwFyOZ/RcB1afycc3OZYv80AM1dkPBVdSTI/R9J3Yuggi9LbK1JLFh339 6p9M8+9UIV2Vg== Date: Tue, 03 Jun 2025 15:46:40 +0000 To: =?utf-8?Q?Tim_D=C3=BCsterhus?= Cc: Ilija Tovilo , PHP internals Subject: Re: [PHP-DEV] [RFC] Transform void into an alias for null Message-ID: In-Reply-To: References: <6Z2Ysh6MjYp1nyzuB0bTPJc5srObIcMRqt731JaQeXUJk1f_V_Yo2nRn8WvjI7er7pp7pIUE6WYl5pRwvYrtcrd07nCutyAqKPSsZHmrS-Y=@gpb.moe> Feedback-ID: 96993444:user:proton X-Pm-Message-ID: 6be9fbffc9166408e23dc105f4ca55009f0bc1a8 Precedence: bulk list-help: list-post: List-Id: internals.lists.php.net x-ms-reactions: disallow MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable From: internals@gpb.moe ("Gina P. Banyard") On Tuesday, 3 June 2025 at 16:18, Tim D=C3=BCsterhus wro= te: > Am 2025-06-03 01:46, schrieb Ilija Tovilo: >=20 > > IMO, these checks are useful enough not to be removed. >=20 > I agree with Ilija (and also Rowan). Well, I'm not sure Ilija and Rowan agree between each other. AFAIU Ilija thinks void living on its weird island is good. Meanwhile, Rowan thinks it is somewhat confusing and that void should be a = subtype of null. > To me there is an important semantic difference between =E2=80=9Cnot retu= rning anything=E2=80=9D > and =E2=80=9Calways returning null=E2=80=9D. > I believe that `void` being in a distinct type > hierarchy is the right choice and when considering =E2=80=9Cuntyped retur= ns=E2=80=9D to > be soft-deprecated / discouraged, there are no inconsistencies either. Then our type system is not logical as we have a top type that is not actua= lly a top type. This is something that will cause problems for function types, especially i= f they have generic arguments. (if not causing weird issues on its own just for generics) Best regards, Gina P. Banyard