Bug report
When using constant enums on function parameters, variables that are declared inside an exhaustive if statement are reported as might not be defined, even though it's certainly defined.
Code snippet that reproduces the problem
https://phpstan.org/r/4a1aeeb3-758f-4dc9-99ab-dee8055071c6
Expected output
There should be no error reported, as every case of the constant enum is covered by the if statement, and every branch of the if statement declares the $message variable