Hello!
Doctrine entities contain an attribute that specifies the repository for the entity:
#[ORM\Entity(repositoryClass: UserRepository::class)]
Right now we need this @var declaration to let the PHP Tools to know which repository to use.
/** @var UserRepository */
$userRepository = $entityManager->getRepository(User::class);
It would be nice if the extension would be able to get the repository type from the entity class. If we don't specify the repository type, the extension doesn't pick up any custom methods from the repository.
Why this is an issue for me:
https://github.com/phpstan/phpstan-doctrine/issues/630
phpstan is moving forward to cut down on phpdoc usage.