We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9e31bbf commit 6aa0179Copy full SHA for 6aa0179
src/Parser/CleaningVisitor.php
@@ -51,7 +51,11 @@ private function keepVariadicsAndYieldsAndInlineVars(array $stmts): array
51
return in_array($node->name->toLowerString(), ParametersAcceptor::VARIADIC_FUNCTIONS, true);
52
}
53
if ($node instanceof Node\Stmt && $node->getDocComment() !== null) {
54
- return strpos($node->getDocComment()->getText(), '@var') !== false;
+ foreach (['phpstan-', 'psalm-', ''] as $tagPrefix) {
55
+ if (strpos($node->getDocComment()->getText(), '@' . $tagPrefix . 'var') !== false) {
56
+ return true;
57
+ }
58
59
60
61
return false;
0 commit comments