Fix dumbdbm and test_dumbdbm to work with dict views. Bug in dumbdbm was from

dict views not being iterators but just iterables.
This commit is contained in:
Brett Cannon 2007-02-22 05:04:32 +00:00
parent f0c82f9842
commit c1b22a07c3
2 changed files with 6 additions and 10 deletions

View file

@ -202,7 +202,7 @@ class _Database(UserDict.DictMixin):
return key in self._index
def iterkeys(self):
return self._index.keys()
return iter(self._index.keys())
__iter__ = iterkeys
def __len__(self):