Re: [RFC] Type hints

From: Date: Sun, 09 May 2004 17:24:20 +0000
Subject: Re: [RFC] Type hints
References: 1 2 3 4 5 6  Groups: php.internals 
Request: Send a blank email to internals+get-9768@lists.php.net to get a copy of this message
On Sun, 9 May 2004, Andi Gutmans wrote: > >null or MyClass $a = 5 ? > > I don't like this. I think it's too long and ugly. > > >I've no idea what nullable is supposed to mean... (well, I do :) I thought about this a bit more, but couldn't actually see why something like "nullable" is needed at all. Simple solution: If you expect an object of a specific class; if it also might be NULL, don't use a class hint at all. So *why* do we even need "bloat" like "nullable" or something similar. regards, Derick

« previous php.internals (#9768) next »