Re: [PHP-DEV] Re: Removal of ${} string interpolation in PHP 9

2022-05-24 Thread Rowan Tommins
On 24/05/2022 21:36, Michael Morris wrote: I can understand removing this feature since it is a bit confusing, but are there any plans to replace it - say with the template literal syntax of JavaScript? For those needing to refactor having something to switch to would be preferable than having

Re: [PHP-DEV] Re: Removal of ${} string interpolation in PHP 9

2022-05-24 Thread Michael Morris
I can understand removing this feature since it is a bit confusing, but are there any plans to replace it - say with the template literal syntax of JavaScript? For those needing to refactor having something to switch to would be preferable than having the feature dropped. Or does PHP have some

Re: [PHP-DEV] [Discussion] Stricter implicit boolean coercions

2022-05-24 Thread Andreas Leathley
On 24.05.22 15:33, Dan Ackroyd wrote: "When discussion ends, and a minimum period of two weeks has passed" Fyi, the two weeks is a minimum, and almost certainly not enough time for subtle BC breaking RFCs like this. I explicitely stated that to make it clear that this should be considered a

Re: [PHP-DEV] [Discussion] Stricter implicit boolean coercions

2022-05-24 Thread Mel Dafert
>> In one application recently I actually had the string "false" (coming >> from a form transmission) being passed to a boolean argument and leading >> to true, which definitely was unintended. > >But "false" is a perfectly sensible thing to pass as a string in an >API (as HTTP is a string based

Re: [PHP-DEV] [Discussion] Stricter implicit boolean coercions

2022-05-24 Thread Dan Ackroyd
On Mon, 16 May 2022 at 16:06, Andreas Leathley wrote: > I have created a preliminary > implementation and an RFC for making implicit boolean type coercions > more strict: > > https://wiki.php.net/rfc/stricter_implicit_boolean_coercions > > With this email I'm starting the two week discussion

Re: [PHP-DEV] [Discussion] Stricter implicit boolean coercions

2022-05-24 Thread Andreas Leathley
On 23.05.22 20:58, Juliette Reinders Folmer wrote: All in all, I largely agree with the flaws in this proposal as previously pointed out by Christian Schneider in the preliminary discussion. And I don't see those concerns addressed in the RFC (other than making it more explicit what the actual

Re: [PHP-DEV] [RFC] Body-less methods

2022-05-24 Thread Dan Ackroyd
Hi Rox, On Mon, 23 May 2022 at 15:49, ROX wrote: > > I focus on Developer eXperience and language consistency. When you have karma to write the RFC, you should probably include in the text why having an extra piece of capability in the language (i.e. one more thing to learn), that only saves

Re: [PHP-DEV] Re: NULL Coercion Consistency

2022-05-24 Thread Rowan Tommins
On 23/05/2022 19:45, Craig Francis wrote: For those against my RFC, can you take a quick look at this patch for Laravel: https://github.com/laravel/framework/pull/36262/files#diff-15b0a3e2eb2d683222d19dfacc04c616a3db4e3d3b3517e96e196ccbf838f59eR118