Re: Nullable cast (?int)

From: Date: Tue, 31 Jul 2018 19:07:30 +0000
Subject: Re: Nullable cast (?int)
References: 1  Groups: php.internals 
Request: Send a blank email to internals+get-102998@lists.php.net to get a copy of this message
On Tue, Jul 31, 2018 at 2:23 PM, David Rodrigues <david.proweb@gmail.com> wrote: > Currently we have support to (int) cast (and similar). But I do think that > we too need a possibility to do a nullable cast. In terms, it will cast to > (int) only if value is not null, else it should be kept as null. > I like this proposal. Short, simple, and consistent with other parts of PHP syntax. Write up an RFC for it? -Sara

« previous php.internals (#102998) next »