vscode-wordpress-hooks icon indicating copy to clipboard operation
vscode-wordpress-hooks copied to clipboard

Additional type declarations in PHP 8

Open johnbillion opened this issue 4 years ago • 0 comments

PHP 8 allows unions in type declarations, eg:

function my_function( Foo|Bar $param )

It also introduces false as a type (although not true because ¯\_(ツ)_/¯).

For anyone writing code for PHP 8 only, it would be useful to allow union types and false to be expressed in the type declarations.

More info: https://php.watch/versions/8.0/union-types

johnbillion avatar Jan 05 '21 18:01 johnbillion