Psalm is an awesome tool for code quality. What I didn't get for a while was how
to annotate Doctrine collections. First I used the array syntax, but then I
found a better way.
/**
* @var User[]
*/
private $users;
The first solution/**
* @return User[]
* @psalm-return array
*/
public function getUsers(): array
{
return