analyse/types/foreach-on-empty-array
In the analyse-recommended preset and every stricter one. Report only.
Configuration
[analyse.rules]
"types/foreach-on-empty-array" = "on"
To skip it in some files or lines, add an ignore comment.
Replaces
DeadForeachRule(phpstan-classes)foreach.emptyArray(phpstan)