1
0
mirror of https://github.com/danog/psalm.git synced 2024-11-26 20:34:47 +01:00

Fix missing param location

This commit is contained in:
Brown 2019-02-27 14:17:11 -05:00
parent 119687f934
commit 1263a2e9a3

View File

@ -2280,7 +2280,17 @@ class ReflectorVisitor extends PhpParser\NodeVisitorAbstract implements PhpParse
$code_location->setCommentLine($docblock_param['line_number']);
if ($storage_param === null) {
$unused_docblock_params[$param_name] = $code_location;
$param_location = new CodeLocation(
$this->file_scanner,
$function,
null,
true,
CodeLocation::FUNCTION_PARAM_VAR,
$docblock_param['type']
);
$param_location->setCommentLine($docblock_param['line_number']);
$unused_docblock_params[$param_name] = $param_location;
if (!$docblock_param_variadic || $storage->params || $this->scan_deep) {
continue;