Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:122231 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 43356 invoked from network); 23 Jan 2024 02:46:00 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 23 Jan 2024 02:46:00 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=php.net; s=mail; t=1705978003; bh=tuXNx9cP/M2dG1V7QuYVUPplqxuGy7b5iME/18rMnXI=; h=Subject:To:References:From:Date:In-Reply-To:From; b=WefBH3m7Pku8T1R9jFM6ZV3Ba1R0T25qpdoWlEKh63nFv4/+YRX+qabhEqhUIgdyF gYGEX08fdqcIEjNhCu4mh+qH/P6XK1bSVdpD3RtKq7r3T1J3uMw68VKEowEb7/okgw xjCblh3ncezXH6ylUjj7/NlsDlCUqg2cfNOPsmg1SnBmABZ9IjqhU91idj+vLbU4xV RrUXZdkfKTeQzmVMwizPsrlkTUDErfrWqk/TL19uxdlOMkCX5s0fN5dilg+qXNjI4O /a2NiTcaIgXEBqEq2DV1t0zA/C7rjtbK1Leww6Ulu3SF76TsD72yNlY8hFEBQzNd2p MI5PpmHIpKgGQ== Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 8CA7618005B for ; Mon, 22 Jan 2024 18:46:42 -0800 (PST) X-Spam-Checker-Version: SpamAssassin 4.0.0 (2022-12-13) on php-smtp4.php.net X-Spam-Level: ** X-Spam-Status: No, score=2.2 required=5.0 tests=ARC_SIGNED,ARC_VALID,BAYES_05, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,DMARC_MISSING, HTML_MESSAGE,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H4, RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_SOFTFAIL,STOX_BOUND_090909_B autolearn=no autolearn_force=no version=4.0.0 X-Spam-Virus: No X-Envelope-From: Received: from toucan.tulip.relay.mailchannels.net (toucan.tulip.relay.mailchannels.net [23.83.218.254]) (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 ; Mon, 22 Jan 2024 18:46:41 -0800 (PST) X-Sender-Id: a2hosting|x-authuser|juliette@adviesenzo.nl Received: from relay.mailchannels.net (localhost [127.0.0.1]) by relay.mailchannels.net (Postfix) with ESMTP id 66010942969 for ; Tue, 23 Jan 2024 02:45:57 +0000 (UTC) Received: from nl1-ss105.a2hosting.com (unknown [127.0.0.6]) (Authenticated sender: a2hosting) by relay.mailchannels.net (Postfix) with ESMTPA id EC2399420EE for ; Tue, 23 Jan 2024 02:45:55 +0000 (UTC) ARC-Seal: i=1; s=arc-2022; d=mailchannels.net; t=1705977956; a=rsa-sha256; cv=none; b=JHN5fIAy3AfgcgYwRpQ6hOkYVnrtOhpmCuS8YyzCoQsJyiMJJ23NK8kDZAI14/syvI9KQq pgji+QAivutUt0IVbDfoJMRu4lSaohumvNrV4avLQc0ljnZnNyYVr1Z1bwQWpyT1ol89tJ j1HiWQNaAWmYXE1oFqJgDzA6YF83vQX2w0V8s3L/x37s7EOg6qZqhgNUH/lp36Hqsbuk5t Mz8H6LpGzL58yrbFNTab2gRJalFxO+/E6EjgJbW4V0+3pbHv5Qp+DBlO5c6l3yrL3ZP1Jn MO4WWmrm8oavQLA554xdOeuZ/Moov6uDmd5O7MMr58y9F0aIt1D+d8aw/to5lA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=mailchannels.net; s=arc-2022; t=1705977956; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references:dkim-signature; bh=6UyeEYdq6dT8jKKNDtWJzoI6n+dXfgDzdjnYlV9asNY=; b=LYfYzwWxxYxnPKWxB8tA/ZvbZpiA6VhltC8QtKu1IgB0L0/Kbj+5ypbhzjz8W8w+zs9BjY knxyAd7HinA07vzXzqjHH4nRNJhVzi/ntAyX25c2r+D+FZQoAG+AYaGaKN+M5DLEJvNK7D T/H/QkevNP5EJEGMAX477PF4bqO03vv2NJ+mTcBE2fAkSHmoqXluoK7642n0mfqJqJmRXW zJVaTa1Q+eG0HuCSeGSEZ+EyI4xucCWtsKCbDfjPKFHrhMaevQgtwt6Mln9T+WKGox79vz rfsfDFtmPbhpU+xgBbz+iZ5n9nfBKAM7pavxmrsxaARDsFAwN+7uA0VqksrdDg== ARC-Authentication-Results: i=1; rspamd-5bfccdc57d-7l28b; auth=pass smtp.auth=a2hosting smtp.mailfrom=php-internals_nospam@adviesenzo.nl X-Sender-Id: a2hosting|x-authuser|juliette@adviesenzo.nl X-MC-Relay: Neutral X-MailChannels-SenderId: a2hosting|x-authuser|juliette@adviesenzo.nl X-MailChannels-Auth-Id: a2hosting X-Exultant-Grain: 39e7e64a2f158149_1705977956555_3792828275 X-MC-Loop-Signature: 1705977956555:1416668681 X-MC-Ingress-Time: 1705977956554 Received: from nl1-ss105.a2hosting.com (nl1-ss105.a2hosting.com [85.187.142.69]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384) by 100.116.174.33 (trex/6.9.2); Tue, 23 Jan 2024 02:45:56 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=adviesenzo.nl; s=default; h=Content-Type:In-Reply-To:MIME-Version:Date: Message-ID:From:References:To:Subject:Sender:Reply-To:Cc: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=6UyeEYdq6dT8jKKNDtWJzoI6n+dXfgDzdjnYlV9asNY=; b=Xkufkf/ZtTAvtY+CBP+OllFB5d k9AONxsBzFZ7rMlexwr2A2+xq4jgwfy8LKokA6GtBFPhMhq+kxonOePss6ZrDSgO69H9kRqNpfXGq NtSzW841+U4RkMTWw13mBArvACbGJjxA7UjBv6agM1GXr6jzS7U1dVAiBL4KTUJW0Sk4=; Received: from [143.178.154.86] (port=55254 helo=[192.168.1.16]) by nl1-ss105.a2hosting.com with esmtpsa (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96.2) (envelope-from ) id 1rS6nT-00CkWv-0I for internals@lists.php.net; Tue, 23 Jan 2024 03:45:53 +0100 To: internals@lists.php.net References: <344c3e06-3822-4b20-9a6f-a58fb64929a7@app.fastmail.com> Message-ID: <65AF2859.8000504@adviesenzo.nl> Date: Tue, 23 Jan 2024 03:45:45 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: multipart/alternative; boundary="------------080109060306050104070106" X-AuthUser: juliette@adviesenzo.nl Subject: Re: [PHP-DEV] [RFC] Deprecate implicitly nullable parameter type From: php-internals_nospam@adviesenzo.nl (Juliette Reinders Folmer) --------------080109060306050104070106 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit On 23-1-2024 3:18, Gina P. Banyard wrote: >> The RFC notes that PHPStan and friends have an easy flag to make the change, which is great, but still that's a minority of PHP devs that even know to use static analysis. > One does not need to use a static analyser to determine or fix this issue, indeed, I didn't even mention static analysers in the RFC as PHP_CS_FIXER is a tool for enforcing coding styles and is capable of fixing this issue. > This tool and other code formatting tools are used more widely and for longer than static analysers. While I concur that too few devs use the helpful tooling available to them, I can already tell you that PHPCompatibility for PHP_CodeSniffer will be able to detect and flag code subject to this deprecation without problems and I will make sure the sniff is available ahead of the PHP 8.4 release (providing the RFC passes). And the Slevomat Coding Standard for PHP_CodeSniffer already contains the `SlevomatCodingStandard.TypeHints.NullableTypeForNullDefaultValue` sniff to auto-fix non-nullable typed parameters with a `null` default value to be nullable typed as well, so it's not just CS-Fixer which can help with this. Smile, Juliette --------------080109060306050104070106--