counting_pointer - Rust
Description: API documentation for the Rust `counting_pointer` crate.
Keywords: rust, rustlang, rust-lang, counting_pointer

# [−][src]Crate counting_pointer

`counting-pointer` provides structs `Sc` and `Asc` . They behave like `std::rc::Rc` and `std::sync::Arc` except for the followings.

- `Sc` and `Asc` treats only strong reference but not weak reference.
- `Sc` and `Asc` takes `GlobalAlloc` type as a template parameter.

It is difficult for `Rc` and `Arc` to achieve both good performance and small memory usage at the same time. This crate gives up supporting weak reference to do it.

## Structs

Asc | A thread-safe strong reference-counting pointer. 'Asc' stands for 'Atomic Strong Counted.'
Sc | A single-threaded strong reference-counting pointer. 'Sc' stands for 'Strong Counted.'