[−][src]Crate servo_arc
Fork of Arc for Servo. This has the following advantages over std::sync::Arc:
- We don't waste storage on the weak reference count.
- We don't do extra RMU operations to handle the possibility of weak references.
- We can experiment with arena allocation (todo).
- We can add methods to support our custom use cases 1.
- We have support for dynamically-sized types (see from_header_and_iter).
- We have support for thin arcs to unsized types (see ThinArc).
Structs
| Arc | An atomically reference counted shared pointer |
| ArcBorrow | A "borrowed |
| ArcInner | The object allocated by an Arc |
| ArcUnion | A tagged union that can represent |
| HeaderSlice | Structure to allow Arc-managing some fixed-sized data and a variably-sized slice in a single allocation. |
| HeaderWithLength | Header data with an inline length. Consumers that use HeaderWithLength as the Header type in HeaderSlice can take advantage of ThinArc. |
| RawOffsetArc | An |
| ThinArc | A "thin" |
| UniqueArc | An |
Enums
| ArcUnionBorrow | This represents a borrow of an |
Constants
| MAX_REFCOUNT | A soft limit on the amount of references that may be made to an |
Functions
| divide_rounding_up | |
| thin_to_thick |
Type Definitions
| HeaderSliceWithLength |