> My main concern about the RFC the way it stands right now is that the
> current direction involves E_RECOVERABLE_ERROR instead of E_STRICT or E_CAST
> for data loss.  This results in both consistency issues with casting as well
> as incompatibility with the dynamic nature of PHP scalars.  I know the RFC
> author (Andrea) disagrees with me about it, but I think we need to find a
> way to put this into a much wider decision.  Probably the most practical
> thing to do is to put it as a secondary question in the RFC, although those
> can be tricky.
>
> Zeev


Hi, all

I looked again at the RFC ..

Can someone please update the description at the section "Conversion Rules"?

This is quoted from the document:

> Conversion is allowed only if data-loss does not happen. There are a few 
> exceptions (objects using __toString, strings containing leading numerics, 
> etc). Here's a table of examples.

But if you look at the table, strings containing leading numbers are
not allowed.

And just as a thought: What about objects where the __toString method
returns a string like "42"? Would that also be accepted as an
argument, that just accepts integers? Sounds crazy, but as strings,
only containing numbers, are accepted as integer, we have to take a
decision here and write it down.

Bye
Simon

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

Reply via email to