diff --git a/psalm-baseline.xml b/psalm-baseline.xml index b8dacf52dee..c8dee018001 100644 --- a/psalm-baseline.xml +++ b/psalm-baseline.xml @@ -56,17 +56,17 @@ $source_parts[1] + + + $stmt->cond + + if (AtomicTypeComparator::isContainedBy( if (AtomicTypeComparator::isContainedBy( - - - $pre_conditions[0] - - $context->assigned_var_ids += $switch_scope->new_assigned_var_ids diff --git a/src/Psalm/Internal/Analyzer/Statements/Block/LoopAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Block/LoopAnalyzer.php index 79ac5bda923..985d73c3c3b 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Block/LoopAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Block/LoopAnalyzer.php @@ -33,8 +33,8 @@ class LoopAnalyzer /** * Checks an array of statements in a loop * - * @param array $stmts - * @param PhpParser\Node\Expr[] $pre_conditions + * @param list $stmts + * @param list $pre_conditions * @param PhpParser\Node\Expr[] $post_expressions * @return false|null */ diff --git a/tests/ArrayFunctionCallTest.php b/tests/ArrayFunctionCallTest.php index 768d8d4dd9a..f82b4bf9788 100644 --- a/tests/ArrayFunctionCallTest.php +++ b/tests/ArrayFunctionCallTest.php @@ -2133,7 +2133,7 @@ function makeAList(int $ofThisInteger): array { 'arrayMapWithEmptyArrayReturn' => [ 'code' => '> $elements + * @param array> $elements * @return list */ function resolvePossibleFilePaths($elements) : array