This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author turepalsson
Recipients docs@python, turepalsson
Date 2021-12-16.09:48:01
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1639648081.19.0.0569018631816.issue46095@roundup.psfhosted.org>
In-reply-to
Content
The language reference about the 'for' statement (https://docs.python.org/3/reference/compound_stmts.html#the-for-statement) has a "Note" box that states that the for statement uses an "internal counter" which is "incremented", and goes into detail about what happens when modifications happen before or after the current loop position. Surely this depends on the underlying iterator? For example, with a balanced tree an insert or a delete could completely re-jigger the tree with hard-to-predict results on an iterator.
History
Date User Action Args
2021-12-16 09:48:01turepalssonsetrecipients: + turepalsson, docs@python
2021-12-16 09:48:01turepalssonsetmessageid: <1639648081.19.0.0569018631816.issue46095@roundup.psfhosted.org>
2021-12-16 09:48:01turepalssonlinkissue46095 messages
2021-12-16 09:48:01turepalssoncreate