Skip to content

Binary Musings

  • Privacy Policy
  • Connect
  • Terms and Conditions

Interior-Mutability

Rust Rc, Arc, RefCell: Shared Ownership & Concurrency

November 9, 2025August 11, 2025 by Garry Chen 101
Rust reference counting

Master Rust’s shared ownership and runtime checks. Use Rc/Arc for multiple owners, RefCell for interior mutability, and Mutex/RwLock for thread-safe state. Includes a DAG example and a clear look at Box::leak, plus when to prefer static checks vs dynamic checks.

Categories rust Tags Concurrency, Interior-Mutability, Multithreading, Rust, Smart-Pointers Leave a comment

Recent Posts

  • 3 Ultimate Secrets of Rust HashMap: Swiss Tables, SIMD, and Memory Layout
  • Rust Collections Guide: Mastering Vec, &str, Box<[T]>, and Iterators
  • Linus Torvalds on AI, Linux, and Life in Korea
  • Rust Error Handling 101: Option, Result, and Panic
  • Makefile Tutorial Part 1: Basic make Rules, Targets & Clean

Recent Comments

No comments to show.

Archives

  • December 2025
  • November 2025
  • September 2025
  • August 2025
  • July 2025
  • June 2025

Categories

  • c++
  • cpp
  • golang
  • javascript
  • rust
  • talks
© 2026 Binary Musings • Built with GeneratePress