Bug report
I just upgraded from PHPStan 1.8.10 to 1.9.0 (missed 1.8.11) and noticed that casting using (array) $var or using !is_array($var) ? [$var] : $var on a string does not produce the same type results.
Code snippet that reproduces the problem
https://phpstan.org/r/ce88f445-141e-4f63-8e71-8c815e1f5033
Expected output
Both lines should do the same thing type-wise.
Did PHPStan help you today? Did it make you happy in any way?
<3