Re: weak and strict type checking RFC
| From: | Jordi Boggiano | Date: | Sat, 04 Jul 2009 07:38:51 +0000 |
| Subject: | Re: weak and strict type checking RFC | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-44691@lists.php.net to get a copy of this message | ||
On 7/4/09, Lukas Kahwe Smith <mls@pooteeweet.org> wrote:
> Last evening I put together a quick proposal for a weak and strict checking
> approach, since I felt that things were being concluded a bit prematurely.
> More importantly I detailed the issues I see with a pure strict type
> checking only approach.
Thanks for the effort, I just wanted to add one thing though.
I'm not sure how this would work with php internals really but you
didn't mention arrays at all in your examples. The way I see it, with
the current conversion code, a weak bool type check would take array()
as a valid false value, and while I agree that it's a useful behavior
in conditionals sometimes, in the case of type checks it feels
horribly wrong.
So I hope it's just not mentionned because it's not a problem,
otherwise I think it should be clarified.
Cheers,
Jordi