TsilCev
LinkedList on Vec. Add and remove O(1) amortized. It has a similar interface to LinkedList and similar to Vec.
Example
use TsilCev;
let mut tc = from;
tc.push_front;
let mut cursor = tc.cursor_front_mut;
assert_eq!;
cursor.move_next;
assert_eq!;
cursor.remove;
assert_eq!;
cursor.remove.remove.move_next_length;
assert_eq!;
cursor.move_prev;
assert_eq!;
tc.drain_filter_tsil;
assert_eq!;
Comparison with LinkedList and VecDeque (thank Criterion)
VecDeque use swap_remove_back
Current Implementation
The allocator for the elements is Vec and each
element has two indexes (next and previous element).
When delete an item, it moves to the end, and something
like pop is called. The time of addition and removal
is amortized to O(1).
Optional features
serde
When this optional dependency is enabled, TsilCev implements the
serde::Serialize and serde::Deserialize traits.