1 | <?php |
||
20 | trait StringLastNameTrait { |
||
21 | |||
22 | /** |
||
23 | * Last name. |
||
24 | * |
||
25 | * @var string |
||
26 | */ |
||
27 | private $lastName; |
||
28 | |||
29 | /** |
||
30 | * Get the last name. |
||
31 | * |
||
32 | * @return string Returns the last name. |
||
33 | */ |
||
34 | public function getLastName() { |
||
37 | |||
38 | /** |
||
39 | * Set the last name. |
||
40 | * |
||
41 | * @param string $last name The last name. |
||
|
|||
42 | */ |
||
43 | public function setLastName($lastName) { |
||
47 | } |
||
48 |
This check looks for PHPDoc comments describing methods or function parameters that do not exist on the corresponding method or function.
Consider the following example. The parameter
$italy
is not defined by the methodfinale(...)
.The most likely cause is that the parameter was removed, but the annotation was not.