Re: [POC - Patch] Scalar Type Hinting - A-La zend_parse_parameters

From: Date: Mon, 12 Mar 2012 14:00:56 +0000
Subject: Re: [POC - Patch] Scalar Type Hinting - A-La zend_parse_parameters
References: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16  Groups: php.internals 
Request: Send a blank email to internals+get-58876@lists.php.net to get a copy of this message
2012/3/12 Lazare Inepologlou <linepogl@gmail.com> > > I'm not sure about you, but I don't wanna see that kind of thing > eventually making it's way into the language > > Me neither. All I am saying is that, since int|null is already here from > the back door, I think it should be properly supported. > There is no int|null at the moment, and should not be. You can pass anything - object, array, string, bool, int, float resource, callable - they all are accepted and are checked in function body if it's writer wrote that code. Hint should provide a hint for a single type, or hint doesn't belong there.

« previous php.internals (#58876) next »