...
public static function test(int $param1, int $param2) : int
{
return ($param1 + $param2);
}
Returned type int is underlined with the message:
Expected type 'int'. Found 'numeric'.intelephense(10006)
I've a simillar issue:
"Expected Type Closure. Found callable|Function" #10006

Had also issues with a return type of self which is gone now, but I don't really know why.
class A {
public function foo() : self
{
return new self();
}
}
self was underlined in red and the error message was something like the following:
Expected type
Afoundself
@damixxx @jakubjo I can report I鈥檝e encountered both of these scenarios in the last 24 hours too.
Most helpful comment
I've a simillar issue:
Had also issues with a return type of
selfwhich is gone now, but I don't really know why.selfwas underlined in red and the error message was something like the following: