On 14 Jul 2014, at 17:04, Zeev Suraski <z...@zend.com> wrote: > 1. It saves a bit of code and improves readability for a *very* common use > case.
Sure. > 2. It encourages developers to get the types straight instead of relying > on implicit casts. Your proposal is to just use implicit casts with no real failure cases; isn’t that encouraging developers not to care about using the correct types? This RFC’s proposal is quite strict, what you are suggesting is very loose and will not encourage anyone to use the correct types, as it is very tolerant. > 3. It reuses syntax we already use for type hinting so it doesn't drive > complexity up significantly. As does this RFC. > 4. It allows people to go extra strict very easily, by turning E_CASE into > errors. My guesstimate is that the majority of people won't, but it'll be > possible and easy to do nonetheless. I really don’t like that idea. If someone writes a function with type hints, people shouldn’t be able to make those type hints go away or become more or less strict. They should be consistent across environments and contexts. -- Andrea Faulds http://ajf.me/ -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php