| Conditions | 5 |
| Paths | 6 |
| Total Lines | 29 |
| Code Lines | 16 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 26 | protected function getInvalidStartTokens(FileInfo $file) { |
||
| 27 | $collection = $file->getTokenizer()->getCollection(); |
||
| 28 | |||
| 29 | $data = []; |
||
| 30 | |||
| 31 | |||
| 32 | foreach ($collection as $tag) { |
||
| 33 | if (T_OPEN_TAG !== $tag->getType()) { |
||
| 34 | continue; |
||
| 35 | } |
||
| 36 | |||
| 37 | |||
| 38 | $value = $tag->getValue(); |
||
| 39 | $next = $collection->getNext(); |
||
| 40 | $whitespaceToken = null; |
||
| 41 | if ($next->getType() === T_WHITESPACE) { |
||
| 42 | $value = $next->getValue(); |
||
| 43 | $whitespaceToken = $next; |
||
| 44 | } |
||
| 45 | |||
| 46 | |||
| 47 | $num = count(explode("\n", $value)); |
||
| 48 | if ($num !== 2) { |
||
| 49 | $data[] = new LineTokenData($num, $tag, $whitespaceToken); |
||
| 50 | } |
||
| 51 | } |
||
| 52 | |||
| 53 | return $data; |
||
| 54 | } |
||
| 55 | |||
| 56 | } |
This check marks PHPDoc comments that could not be parsed by our parser. To see which comment annotations we can parse, please refer to our documentation on supported doc-types.