When converting iterable to array, psalm returns an error: https://psalm.dev/r/496d9d1084 To me it sounds that this shouldn't be a problem because it is equivalent to a foreach, which doesn't throw an error: https://psalm.dev/r/cc83c4dc5d