| Conditions | 3 |
| Paths | 3 |
| Total Lines | 10 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 4 |
| CRAP Score | 3 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 50 | 506 | public function getAnnotations(ReflectionProperty $target, string $name): Generator |
|
| 51 | { |
||
| 52 | // @codeCoverageIgnoreStart |
||
| 53 | if (PHP_MAJOR_VERSION < 8) { |
||
| 54 | return; |
||
| 55 | } // @codeCoverageIgnoreEnd |
||
| 56 | |||
| 57 | 506 | $attributes = $target->getAttributes($name, ReflectionAttribute::IS_INSTANCEOF); |
|
| 58 | 506 | foreach ($attributes as $attribute) { |
|
| 59 | 56 | yield $attribute->newInstance(); |
|
| 60 | } |
||
| 63 |