Message 277586 - Python tracker
Message277586
| Author | rhettinger |
|---|---|
| Recipients | rhettinger, serhiy.storchaka, xiang.zhang |
| Date | 2016-09-28.05:46:45 |
| SpamBayes Score | -1.0 |
| Marked as misclassified | Yes |
| Message-id | <1475041606.1.0.871468758915.issue28293@psf.upfronthosting.co.za> |
| In-reply-to |
| Content | |
|---|---|
Perhaps: _cache.pop(next(iter(_cache))) The for-loop version indirect about what it is trying to do and relies on an obscure quirk of exactly when it is an error to mutate while iterating. I do like that the side-effect of the compact dict is that is lets us choose the oldest entry to evict. |
|
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2016-09-28 05:46:46 | rhettinger | set | recipients: + rhettinger, serhiy.storchaka, xiang.zhang |
| 2016-09-28 05:46:46 | rhettinger | set | messageid: <1475041606.1.0.871468758915.issue28293@psf.upfronthosting.co.za> |
| 2016-09-28 05:46:46 | rhettinger | link | issue28293 messages |
| 2016-09-28 05:46:45 | rhettinger | create | |