From 6cea065bca6647930d1089843559007bfc91f873 Mon Sep 17 00:00:00 2001 From: Matthew Brown Date: Sun, 5 Apr 2020 00:10:50 -0400 Subject: [PATCH] Attempt to export file order in Linux CI --- src/Psalm/Internal/Analyzer/Statements/ExpressionAnalyzer.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Psalm/Internal/Analyzer/Statements/ExpressionAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/ExpressionAnalyzer.php index 6ee305f97..5a69942e0 100644 --- a/src/Psalm/Internal/Analyzer/Statements/ExpressionAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/ExpressionAnalyzer.php @@ -1913,7 +1913,7 @@ class ExpressionAnalyzer $context->inside_call = false; if ($var_comment_type) { - $expression_type = $var_comment_type; + $expression_type = clone $var_comment_type; } elseif ($stmt_var_type = $statements_analyzer->node_data->getType($stmt->value)) { $expression_type = clone $stmt_var_type; } else { @@ -1966,7 +1966,7 @@ class ExpressionAnalyzer $statements_analyzer->node_data->setType( $stmt, Type::combineUnionTypes( - $atomic_return_type->type_params[2], + clone $atomic_return_type->type_params[2], $expression_type, $codebase )