commit | 446a4f23302ed3c33f32e6bd074b6752dc917b7a | [log] [tgz] |
---|---|---|
author | Raymond Hettinger <python@rcn.com> | Wed Apr 08 08:28:28 2009 +0000 |
committer | Raymond Hettinger <python@rcn.com> | Wed Apr 08 08:28:28 2009 +0000 |
tree | d1b64db9f9847e1d15e5640a6f2d8a10a61e7287 | |
parent | 238018c5c47499f4e0edef681bded41b20bcb53a [diff] [blame] |
Minor factoring.
diff --git a/Lib/collections.py b/Lib/collections.py index 3c1b78a..a90915a 100644 --- a/Lib/collections.py +++ b/Lib/collections.py
@@ -122,7 +122,7 @@ ''' if not self: raise KeyError('dictionary is empty') - key = next(reversed(self)) if last else next(iter(self)) + key = next(reversed(self) if last else iter(self)) value = self.pop(key) return key, value