Message324439
If it were possible that the interpreter iterating over a dictionary could cause the dictionary to change size then I suspect that this would be a rich source of bugs to mine. :-)
It would be great if we could make it a documented, enforced invariant that the interpreter reading a dictionary never produces a side effect visible to the interpreter.
Re: "this specific statement already existed before my work."
Thanks for the historical note; the first thing I thought when I read this line was "that's got to be a copy-paste left over from an earlier version of the algorithm." |
|
Date |
User |
Action |
Args |
2018-08-31 17:21:23 | Eric Lippert | set | recipients:
+ Eric Lippert, tim.peters, vstinner, serhiy.storchaka |
2018-08-31 17:21:23 | Eric Lippert | set | messageid: <1535736083.77.0.56676864532.issue34551@psf.upfronthosting.co.za> |
2018-08-31 17:21:23 | Eric Lippert | link | issue34551 messages |
2018-08-31 17:21:23 | Eric Lippert | create | |
|