Is worth noting that you don't reach for reference counting by default in Rust: your reach for references, then boxes, THEN Arc.
You can find documentation on these types here: http://doc.rust-lang.org/guide-pointers.html
You can find documentation on these types here: http://doc.rust-lang.org/guide-pointers.html
This is different from shared_ptr in C++ which is always atomic and LLVM has to try hard (in clang, no idea what GCC does) to eliminate some redundant ref-counts.
Oh and since Rc is affine, you only ref-count when you call .clone() on it or you let it fall out of scope.
Most of the time you can pass a reference to the contents, or, if you need to sometimes clone it, a reference to the Rc handle, avoiding ref-counting costs.