1
0
mirror of https://github.com/danog/psalm.git synced 2024-11-30 04:39:00 +01:00

Fix callable without params inference

This commit is contained in:
klimick 2023-07-11 01:01:31 +03:00
parent 5cb2557410
commit 9fccf201e3

View File

@ -235,7 +235,10 @@ class FunctionCallAnalyzer extends CallAnalyzer
$function_call_info->function_id,
);
$template_result->lower_bounds += $already_inferred_lower_bounds;
$template_result->lower_bounds = array_merge(
$template_result->lower_bounds,
$already_inferred_lower_bounds,
);
if ($function_name instanceof PhpParser\Node\Name && $function_call_info->function_id) {
$stmt_type = FunctionCallReturnTypeFetcher::fetch(