mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-12-24 11:42:52 +01:00
Forgot to actually enqueue in MaxLengthQueue.enqueue.
This commit is contained in:
parent
9295254ccb
commit
5da85d4f2f
@ -232,9 +232,11 @@ class MaxLengthQueue(queue):
|
||||
queue.__setstate__(self, q)
|
||||
|
||||
def enqueue(self, elt):
|
||||
queue.enqueue(self, elt)
|
||||
if len(self) > self.length:
|
||||
self.dequeue()
|
||||
|
||||
|
||||
class IterableMap(object):
|
||||
"""Define .iteritems() in a class and subclass this to get the other iters.
|
||||
"""
|
||||
|
Loading…
Reference in New Issue
Block a user