3 ms·
Sure it does: `Arc::new(thing)`
by dcow 5y ago
Sure it does: `Arc::new(thing)`
- steveklabnik 5y agoThat is atomic reference counting, not automatic reference counting. With automatic reference counting, you do not need to wrap the variables, and you do not need to increment or decrement the counter. Rust requires that you actively make your values reference counted by wrapping them explicitly, and makes you bump the count explicitly. It uses RAII to decrement the count automatically though.