vimeo/psalm
View on GitHubDifferent results between `DateTime` and `DateTimeImmutable`
Open
#5,220 opened on Feb 14, 2021
Help wantedbuginternal stubs/callmap
Repository metrics
- Stars
- (5,369 stars)
- PR merge metrics
- (Avg merge 3d 12h) (5 merged PRs in 30d)
Description
I noticed that DateTime and DateTimeImmutable works different way, but those should work as the same.
I first noticed this with PHP 8 named parameters and DateTimeImmutable usage, and I made fix for that part - https://github.com/vimeo/psalm/pull/5218
But now I'm still seeing different handling on DateTime class - and I cannot find the code where that is done.
https://psalm.dev/r/129b9fce2b https://psalm.dev/r/ee31f26136