We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8f703ba commit 0af5cbaCopy full SHA for 0af5cba
src/Ast/PhpDoc/PhpDocNode.php
@@ -272,6 +272,20 @@ static function (PhpDocTagValueNode $value): bool {
272
}
273
274
275
+ /**
276
+ * @return AssertTagValueNode[]
277
+ */
278
+ public function getAssertTagValues(string $tagName = '@phpstan-assert'): array
279
+ {
280
+ return array_filter(
281
+ array_column($this->getTagsByName($tagName), 'value'),
282
+ static function (PhpDocTagValueNode $value): bool {
283
+ return $value instanceof AssertTagValueNode;
284
+ }
285
+ );
286
287
+
288
289
public function __toString(): string
290
{
291
$children = array_map(
0 commit comments