3 ms·
> Using refcounts to get around an overly aggressive borrow checker seems to be an ugly developing pattern in rust Every single large, "modern", C++ codebase I
by Manishearth 9y ago
> Using refcounts to get around an overly aggressive borrow checker seems to be an ugly developing pattern in rust
Every single large, "modern", C++ codebase I've worked with uses way more refcounts than is typical in Rust.
(and it's worse because C++ refcounting patterns involve more refcount churn due to how they're designed on the copy constructor, and shared_ptr uses atomics even when unnecessary. Though these large codebases tend to use a slightly different design that lets them decide atomicity per-type)