False positive Strict comparison using ===
when treatPhpDocTypesAsCertain
is false
#5698
Labels
Milestone
Strict comparison using ===
when treatPhpDocTypesAsCertain
is false
#5698
Bug report
Code snippet that reproduces the problem
When
treatPhpDocTypesAsCertain
istrue
there is no error reported for the above code: https://phpstan.org/r/df01e23e-636a-4d09-b106-806a14fd46edBut when
treatPhpDocTypesAsCertain
isfalse
, there isStrict comparison using === between array<int, int> and array() will always evaluate to false.
: https://phpstan.org/r/16b5347b-fd04-4ae9-be7a-366f87918cacCalling
foo
with no arguments is valid: https://3v4l.org/lmbDDExpected output
No error in both cases.
The text was updated successfully, but these errors were encountered: