Where to learn
The Rust Programming Language
About Pointers
Box<T>
Rc<T>
is enhanced with multiple ownership by a “strong counter” to count the number of pointers to the same data(only “strong” pointers)
RefCell<T>
is to allow “internal mutability” through borrow rules check in runtime instead of compile time.
Weak<T>
is to avoid memory leak caused by “reference cycle”
Things that I wanna learn more about pointers in Rust
- The implementation details of borrow rules check in runtime.
- How to convert C pointers to Rust pointers? As part of the C2Rust project.