Re: Object Casting - An Alternative to Type Hinting

From: Date: Sun, 26 Feb 2012 21:05:33 +0000
Subject: Re: Object Casting - An Alternative to Type Hinting
References: 1  Groups: php.internals 
Request: Send a blank email to [email protected] to get a copy of this message
On 26/02/12 15:57, Anthony Ferrara wrote:
> I've gone back and re-read a bunch of the old posts on Type Hinting,
> and have come to the conclusion that it won't be done any time soon.
> Not because it doesn't have merit, but because there are at least a
> few fundamental difficulties that are non-trivial to figure out while
> still keeping the usefulness.
Can you provide a list?

Having clear objectives of what we are intending to fix will help to find
a good solution.
I suspect that the __cast solution is more complex than needed. And
specifically, I forsee having both __castTo() and __castFrom() as a source
of conflicts.



Thread (26 messages)

« previous php.internals (#58093) next »