| Conditions | 1 |
| Paths | 1 |
| Total Lines | 17 |
| Code Lines | 11 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 10 |
| CRAP Score | 1 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 47 | 1 | private function parseNode(AttributeNodeInterface $parent, Node ...$astNodes): NodeInterface |
|
| 48 | { |
||
| 49 | 1 | return array_reduce( |
|
| 50 | 1 | $astNodes, |
|
| 51 | function (AttributeNodeInterface $carry, Node $astNode): NodeInterface { |
||
| 52 | return $carry |
||
| 53 | 1 | ->add( |
|
| 54 | 1 | $this->parseNode( |
|
| 55 | 1 | $this->createNode([ |
|
| 56 | 1 | 'label' => $astNode->getNodeKindName(), |
|
| 57 | 1 | 'astNode' => $astNode, |
|
| 58 | ]), |
||
| 59 | 1 | ...$astNode->getChildNodes() |
|
| 60 | ) |
||
| 61 | ); |
||
| 62 | 1 | }, |
|
| 63 | $parent |
||
| 64 | ); |
||
| 67 |