auto_vec-0.1.0 has been yanked.
AutoVec
Vec that automatically remove the child that is droped This crate is still in development. Many method of the default vec is still to be implemented for it.
Note that AutoVec stores the raw pointer of the child, meaning dereferencing is unsafe, which also means that you can freely mutate the child's field.
However, mutating the child it self, e.g. child1 = child2 will cause child1 to be dropped thus removing it from the vec.
Also, as using mem::swap does not drop the child, but changes the child's parent, which is not memory safe, the child is pinned to prevent from being swapped.
Examples
use *;
let mut t1 = new;
let mut t2 = new;
let mut v = new;
v.add;
v.add;
println!;
drop;
println!;
// t1 has been automatically removed from the vector