Open beckend opened 5 months ago
That seems to be an interesting topic.
I've never thought about this, but I strongly feel that implementing a lock-free mt-safe version of std::collections::VecDeque is virtually impossible. However, I think I can provide something similar using Queue<T>
if the second condition - Possible to remove from any index
- can be relaxed or removed.
On the other hand, TreeIndex
offers what you want except for the third condition - push/pop front/back.
So, it maybe easier to extend TreeIndex
instead of using Queue
.
I'll think about this when I have time!