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

2022-04-26 Thread Andreas Leathley
On 26.04.22 12:02, Mark Randall wrote: On 26/04/2022 10:54, Andreas Leathley wrote: Any non-empty string (except "0") is converted to true and any non-zero integer or float is converted to true. If we could get rid of "0" being false, that alone would be a huge benefit for the language in the

[PHP-DEV] Re: Stricter implicit boolean coercions

2022-04-26 Thread Mark Randall
On 26/04/2022 10:54, Andreas Leathley wrote: Any non-empty string (except "0") is converted to true and any non-zero integer or float is converted to true. If we could get rid of "0" being false, that alone would be a huge benefit for the language in the long run. I know why it exists, but I