PHP7 scalar typehinting


I want to make use of the scalar typehinting of PHP7. I have the latest PS version ( but something goes wrong. When I add scalar typehintinh to my function, the PHPDoc tells me that it wrong. I have to namespace the scalartype to remove the error in my phpdoc. Considder this screenshot:

Screen Shot 2015-12-23 at 09.54.57.png
The first two functions are misunderstanding my typehinting and wants to namespacing the type. What I want is the third function, but PhpStorm cannot resolve its type and says that the PhpDoc param is not the same as the type in the function body.

For the record: These functions are written in a namespaced class.

1 comment
Comment actions Permalink

Hi there, -- it is marked as fixed -- try next EAP build once released (follow PhpStorm's blog for announcements) or wait for 10.0.3 final.


Please sign in to leave a comment.