Amaury Forgeot d'Arc <amaur...@gmail.com> added the comment:

> I wrote this patch with the assumption that it shouldn't hurt
> if multiple threads call deque.extend() at the same time.

By looking at the implementation, I found that if multiple threads call 
dequeue.extend() at the same time, all items will be added, but the order is 
not deterministic.
It probably does not matter for tests.

In any case, I think we should not rely on this specific implementation.  We 
should document which functions are safe to use in a multithreading environment.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue15320>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to