fix: don't close argument type. (#7)

ref https://github.com/vimeo/psalm/pull/8691#discussion_r1019192376
This commit is contained in:
Saif Eddin Gmati 2022-11-10 19:50:16 +01:00 committed by GitHub
parent acec87621b
commit 1c425b71c6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -28,9 +28,6 @@ final class FunctionReturnTypeProvider implements FunctionReturnTypeProviderInte
return null;
}
$clone = clone $argument_type;
$clone->possibly_undefined = true;
return $clone;
return $argument_type->setPossiblyUndefined(true);
}
}