PHPantom version
c733048
Installation method
Built from source
Operating system
Linux x86_64
Editor
Neovim
Bug description
Hello!
See example below---it should detect $filePath as non-empty-string and $paths as LazyCollection<int, string>
/**
* @param string|list<string> $path
* @return LazyCollection<int, string>
*/
function discover(string|array $path): LazyCollection
{
$paths = LazyCollection::make(function () use ($path) {
$files = Finder::create()->files()->name('*.php')->path($path);
foreach ($files as $filePath => $file) {
\PHPStan\dumpType($filePath);
yield (string) $file->getRealPath();
}
});
\PHPStan\dumpType($paths);
return $paths;
}
Steps to reproduce
see above
Error output or panic trace
.phpantom.toml
Additional context
No response
PHPantom version
c733048
Installation method
Built from source
Operating system
Linux x86_64
Editor
Neovim
Bug description
Hello!
See example below---it should detect
$filePathasnon-empty-stringand$pathsasLazyCollection<int, string>Steps to reproduce
see above
Error output or panic trace
.phpantom.toml
Additional context
No response