analyse/types/yield-outside-function
In the analyse-essential preset and every stricter one. Report only.
Configuration
[analyse.rules]
"types/yield-outside-function" = "on"
To skip it in some files or lines, add an ignore comment.
Replaces
YieldInGeneratorRule(phpstan-classes)YieldOutsideFunction(mago-analyzer)generator.outOfFunction(phpstan)generator.returnType(phpstan)