You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Dates in DateTime objects can be compared only using the loose == operator, however when I switched bleeding edge on (on top of strict rules), phpstan started suggesting to compare DateTime objects via strict === comparison, which compares the objects themselves, instead of dates.
Bug report
Dates in DateTime objects can be compared only using the loose == operator, however when I switched bleeding edge on (on top of strict rules), phpstan started suggesting to compare DateTime objects via strict === comparison, which compares the objects themselves, instead of dates.
Code snippet that reproduces the problem
https://phpstan.org/r/2c276792-c7f0-41b1-bde7-2dc8de08adcb
Expected output
I think phpstan should not suggest strict comparison using === for DateTime and other date objects.
Did PHPStan help you today? Did it make you happy in any way?
No response
The text was updated successfully, but these errors were encountered: