1 | <?php |
||
17 | class Parser |
||
18 | { |
||
19 | /** |
||
20 | * @param string $body |
||
21 | * @return ProcessedBody |
||
22 | */ |
||
23 | public function parse(string $body): ProcessedBody |
||
39 | |||
40 | /** |
||
41 | * @param string $title |
||
42 | * @return string |
||
43 | */ |
||
44 | private function createAnchorName(string $title): string |
||
48 | |||
49 | /** |
||
50 | * @param string $tag |
||
51 | * @param string $id |
||
52 | * @param string $header |
||
53 | * @return string |
||
54 | */ |
||
55 | private function render(string $tag, string $id, string $header): string |
||
61 | } |
||
62 |
This checks looks for assignemnts to variables using the
list(...)
function, where not all assigned variables are subsequently used.Consider the following code example.
Only the variables
$a
and$c
are used. There was no need to assign$b
.Instead, the list call could have been.