Mypy incorrectly requires __next__()
on the iterable of a for
loop (regression from 0.942).
#16733
Labels
bug
mypy got something wrong
Bug Report
For loops in Python require only an iterable, for which an iterator is subsequently created. However, in the code below, Mypy incorrectly requires
__next__
to be available on the iterable.To Reproduce
Actual Behavior
Your Environment
mypy.ini
(and other config files): None.This is a regression from version 0.942.
1.8.0 Playground
0.942 Playground
The text was updated successfully, but these errors were encountered: