Hi,

On Thu, Mar 17, 2016 at 1:02 PM, Matt Prelude <m...@mprelu.de> wrote:

I'd support borrowing the "?" nullable annotation from HackLang for
> people who want a less strict behavior:
>
> public ?string $name;
>
> This means that $name can either be a string or the NULL value.
>

Or, do it like with parameter type hinting:

     public string $name = null;

Although I'm all for limiting NULL to only being the default value:

    $this->name = null; // this should throw a TypeError


Cheers,
Andrey.

Reply via email to