I think that weak type-hinting defeats the whole purpose of the
feature and I would rather not have it than have a non-obvious
implementation.

-1

On Wed, Aug 11, 2010 at 2:03 AM, Zeev Suraski <z...@zend.com> wrote:
> At 01:47 11/08/2010, Stas Malyshev wrote:
>>
>> Hi!
>>
>>> For the record: I consider the current implementation as (one of) the
>>> biggest mistakes in the last ten years.
>>
>> I agree completely. The fact that obvious absence of consensus is ignored
>> and we are releasing feature that clearly has no consensus behind it as a
>> part of an official release - when we have killed much lesser things for
>> much lesser reasons - I think it is a very bad development.
>
> I agree completely too.
>
> We've also had quite a lengthy discussion on this topic, and there was more
> support for 'weak' typing then there was for strict typing.
>
> The response to Johannes's blog also don't leave much room for speculation
> regarding what the community at large thinks.
>
> Facts:
> - When we introduced type hints, one of the 'conditions' were that we'll
> never, ever have type hints for scalars - for many different reasons - the
> strongest of which it simply doesn't fit PHP's theme.
> - We managed to come up with an alternative solution, in the form of
> auto-converting type hints for scalars, which does in fact fit PHP's theme
> perfectly.
> - I suggested we actually take the opportunity to slightly modify PHP's
> conversion rules in esoteric cases, where our historical decision is
> probably not the right one (e.g., silently converting "abc" into 0 in case
> of integer context - instead emit a new E_TYPE warning that would be off by
> default).
>
> My view in terms of preferences:
> #1 - Auto-converting type hints + minor changes to PHP's conversion rules
> #2 - Auto-converting type hints
> #3 - Doing nothing
> #inf - Introducing strict typing into PHP (current trunk status)
>
> As Stas said - there's clearly anything but consensus around strict typing,
> so our 'default' in case we can't reach agreement is #3 - the status quo.
>  As everyone told me when this feature was committed to trunk - "it doesn't
> mean anything, it's just trunk".  Let's stand behind that statement and
> revert it.
>
> Strict typing should go away before any 'official' package comes out of
> php.net.
>
> Zeev
>
> --
> PHP Internals - PHP Runtime Development Mailing List
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to