mirror of
https://github.com/danog/psalm.git
synced 2025-01-22 05:41:20 +01:00
fabcda16b4
Fixes #7478 As discussed in the upstream issue, `trait_exists()` always returns `bool`: while it can return `null` when the arguments passed to it do not match (either no arguments, or 3 or more arguments), we do not support that scenario, as that already doesn't respect the type signature of this function. We cut to the point: always make it `bool`, which is the scenario that works under healthy operational conditions. Ref: https://github.com/Roave/BetterReflection/pull/983#discussion_r790908170 Ref: https://psalm.dev/r/c41a43805d Ref: https://github.com/vimeo/psalm/issues/7478#issuecomment-1020330351 Ref: https://github.com/vimeo/psalm/issues/7478#issuecomment-1020337712 Ref: https://3v4l.org/XpHmh