Message7334
Referring to http://docs.python.org/library/collections.html#collections.deque , deque() should take a maxlen keyword arg to enable a ringbuffer / bounded length deque.
Jython:
Jython 2.7a2 (default:9c148a201233, May 24 2012, 15:49:00)
[Java HotSpot(TM) 64-Bit Server VM (Apple Inc.)] on java1.6.0_33
Type "help", "copyright", "credits" or "license" for more information.
>>> from collections import deque
>>> deque(maxlen=10)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: deque() does not take keyword arguments
>>>
CPython:
Python 2.7.3 (default, Jul 9 2012, 10:36:52)
[GCC 4.2.1 Compatible Apple Clang 4.0 (tags/Apple/clang-418.0.60)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> from collections import deque
>>> deque(maxlen=10)
deque([], maxlen=10)
>>> |
|
Date |
User |
Action |
Args |
2012-07-23 22:10:02 | duffy151 | set | recipients:
+ duffy151 |
2012-07-23 22:10:02 | duffy151 | set | messageid: <1343081402.26.0.458938606331.issue1949@psf.upfronthosting.co.za> |
2012-07-23 22:10:02 | duffy151 | link | issue1949 messages |
2012-07-23 22:10:02 | duffy151 | create | |
|