Total Complexity | 8 |
Total Lines | 48 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
7 | final class FakeController |
||
8 | { |
||
9 | public function basicAction(): string |
||
12 | } |
||
13 | |||
14 | public function stringParamAction(string $param): string |
||
18 | } |
||
19 | |||
20 | public function intParamAction(int $param): string |
||
21 | { |
||
22 | $type = get_debug_type($param); |
||
23 | return "The '{$type}' param is '{$param}'!"; |
||
24 | } |
||
25 | |||
26 | public function floatParamAction(float $param): string |
||
27 | { |
||
28 | $type = get_debug_type($param); |
||
29 | return "The '{$type}' param is '{$param}'!"; |
||
30 | } |
||
31 | |||
32 | public function boolParamAction(bool $param): string |
||
37 | } |
||
38 | |||
39 | public function manyParamsAction(string $firstParam, string $secondParam, string $thirdParam): string |
||
42 | } |
||
43 | |||
44 | /** |
||
45 | * @param mixed $param |
||
46 | */ |
||
47 | public function nonTypedParam($param): string |
||
|
|||
48 | { |
||
49 | return 'I AM ERROR!'; |
||
50 | } |
||
51 | |||
52 | public function nonScalarParam(array $param): string |
||
55 | } |
||
56 | } |
||
57 |
This check looks for parameters that have been defined for a function or method, but which are not used in the method body.