Bug report
While $array[$key][] works fine, array_push/array_unshift with count($array[$key]) returns a fixed value in a loop. As a result, it gets an error: Comparison operation ">" between 1 and 1 is always false.
Code snippet that reproduces the problem
https://phpstan.org/r/dae26e88-0e7c-4b0e-bb31-e58cea1de089
Expected output
No error