Phan 6.0.1
New features:
- Allow a
&before the method name in@methodannotations, to declare that the method returns by reference (#5430) - New
PhanTypeComparisonObjectOrderingissue type to detect when ordering operators (<,<=,>,>=,<=>) are used to compare an object with a non-object value, which throws TypeError in PHP 8.0+
Bug fixes:
- Fixed analysis of
array_mapwith ternary expression as array argument (#5424) - Skip redundant/impossible condition detection on static properties (#5423)
- Fixed
value-of<T>andkey-of<T>not evaluating to the expected types (#5421) - Fixed more inconsistencies in type inference for
ifstatement vs?:ternary expression (#5408) - Fixed templated subtypes of
arraynot being treated as array-like (#5433) - Treat readonly classes as such when read from Reflection (#5436)
Miscellaneous:
- Replace TysonAndre/var_representation_polyfill with the phan/ fork for PHP 8.5 support (#5420)