phpantom_lsp 0.7.0

Fast PHP language server with deep type intelligence. Generics, Laravel, PHPStan annotations. Ready in an instant.
Documentation
// test: generic interface extending Traversable resolves template in foreach
// feature: completion
// Adapted from phpactor generics/interface.test
// expect: getCode(
---
<?php
class Violation {
    public function getCode(): string {}
}
/**
 * @extends \ArrayAccess<int, Violation>
 * @extends \Traversable<int, Violation>
 */
interface ViolationListInterface extends \Traversable, \Countable, \ArrayAccess
{
}
function foo(ViolationListInterface $list) {
    foreach ($list as $violation) {
        $violation-><>
    }
}