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 210e23d commit 5f9b9ddCopy full SHA for 5f9b9dd
src/PhpDoc/PhpDocNodeResolver.php
@@ -423,12 +423,8 @@ public function resolveParamImmediatelyInvokedCallable(PhpDocNode $phpDocNode):
423
public function resolveParamPureUnlessCallableIsImpure(PhpDocNode $phpDocNode): array
424
{
425
$parameters = [];
426
- // TODO: implement phpstan/phpdoc-parser
427
- foreach ($phpDocNode->getTagsByName('@pure-unless-callable-impure') as $tag) {
428
- $value = preg_split('/\s/u', (string)$tag->value)[0] ?? null;
429
- if ($value !== null && str_starts_with($value, '$')) {
430
- $parameters[substr($value, 1)] = true;
431
- }
+ foreach ($phpDocNode->getPureUnlessCallableIsImpureTagValues() as $tag) {
+ $parameters[$tag->parameterName] = true;
432
}
433
434
return $parameters;
0 commit comments