Message173007
> > It will be nice somewhere in deep clarify
> > for experts what happens with list iterator if the list changed.
Resist the urge to over-specify. Unless the behavior is tested and known to be consistent across all implementations, I'm content with the current docs:
"Note There is a subtlety when the sequence is being modified by the loop...."
Chris's currently patch seems reasonable to me and I don't think anything further is a good idea.
With nearly any data structure in any language, most programmers learn to be cautious about and generally avoid looping over a structure while mutating it. Adding yet more documentation details won't make the issue go away.
I recommend posting the current patch and closing this issue to be done with it. |
|
Date |
User |
Action |
Args |
2012-10-16 01:24:42 | rhettinger | set | recipients:
+ rhettinger, georg.brandl, jcea, chris.jerdonek, docs@python, serhiy.storchaka, Ian |
2012-10-16 01:24:42 | rhettinger | set | messageid: <1350350682.22.0.557455053444.issue16225@psf.upfronthosting.co.za> |
2012-10-16 01:24:42 | rhettinger | link | issue16225 messages |
2012-10-16 01:24:41 | rhettinger | create | |
|