Foreach variable autocompletion seems broken when import is involved
Foreach autocompletion seems to be broken if an import is involved:
<?php
namespace Serenata\Blah;
use PhpSpec\Wrapper\Subject\Expectation;
class Foo
{
public function bar()
{
/** @var Expectation[] $item */
$item = [];
foreach ($item as $it) {
$it-> // No autocompletion
}
}
}
It works fine if you use the FQCN in the @var type override, though, so it seems like the type is not properly resolved based on import statements here.