r/rust • • Jul 26 '19

Is this comment about the reference counting performance in Rust accurate?

/r/ProgrammerHumor/comments/b274zp/oof/eirvecs?context=3
50 Upvotes

52 comments sorted by

View all comments

Show parent comment

2

u/simonask_ Jul 27 '19

std::shared_ptr also have some very interesting (or "interesting" if you like) features, where for example instances std::shared_ptr<T> and std::shared_ptr<U> can share the same control block (if T has unique ownership of an instance of U). These are clever, but can also introduce some very interesting debugging scenarios...