Re: Deprecate b-prefix for strings

From: Date: Mon, 05 Oct 2026 21:22:44 +0000
Subject: Re: Deprecate b-prefix for strings
References: 1  Groups: php.internals 
Request: Send a blank email to internals+get-132800@lists.php.net to get a copy of this message
On 25-9-2026 13:32, Juliette Reinders Folmer wrote:
All, The b string prefix and the (binary) cast were both introduced in PHP 5.2.1 for forward compatibility with PHP 6. In 2016, there was an RFC [1] targeting PHP 7.x to deprecate both, which was declined. Since then, the (binary) type cast has now been deprecated in PHP 8.5.0 [2], but as far as I can see, the b-prefix for strings is still supported. I can't remember ever coming across this in the wild, so I wonder if it might be a good idea to deprecate the b-prefix now as well. I'll happily create an RFC for this if the you all think it's a good idea. Opinions ? Smile, Juliette 1: https://wiki.php.net/rfc/binary_string_deprecation 2: https://wiki.php.net/rfc/deprecations_php_8_5#deprecate_non-standard_cast_names
Just in case you missed it in the avalanche of proposals being discussed on the list at this moment. So far, this suggestion has had one response, which is not enough to make it worth the effort for me to write an RFC and find someone to collaborate with for the C-code. Unless there are more people who respond to indicate interest in this proposal, I will not pursue it. Smile, Juliette

« previous php.internals (#132800) next »