Skip to content

After modifying array inside foreach phpstan no longer considers it iterable #13270

@carloscz

Description

@carloscz

Bug report

afaik affects 2.1.18(+) version only

Code snippet that reproduces the problem

https://phpstan.org/r/8ab68296-f8bd-4f7d-baa5-fed88f66ba88

Expected output

no issues

Did PHPStan help you today? Did it make you happy in any way?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions