RE: [PHP-DEV] Scalar Type Hints v0.4
| From: | François Laupretre | Date: | Wed, 18 Feb 2015 16:51:43 +0000 |
| Subject: | RE: [PHP-DEV] Scalar Type Hints v0.4 | ||
| References: | 1 2 3 4 5 6 7 8 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-83092@lists.php.net to get a copy of this message | ||
> De : Pádraic Brady [mailto:padraic.brady@gmail.com]
>
> Careful, it helps not to call folk "radicals" if you intend to pursue
> a compromise with them ;).
Sorry, english is not my native language, and 'radical' may be offensive.
I was just looking for a word for people who consider providing two modes is a pre-requisite to any
discussion.
> I wouldn't necessarily mind int->float - it's lossless assuming one way only.
It's lossless but it kills the 'strict' position. It can be claimed, one hand on the
heart, this will be the only exception but, as use cases and side effects accumulate, we all know it
will finish as a bunch of exceptions to a no-more strict mode, adding confusion where it is not
needed. I guess the next one would be (int -> bool), and the rest would follow.
I am taking the problem the other way round, determining from scratch the filtering/conversions I
want to enable and disable. The result will probably be the same, but not with the same wasted
energy and not in the same time.
Regards
François