#smart-pointers #reference-counting #allocation #shared #arc #portion #refer

maprc

Rc and Arc alternatives that allow the smart pointer to refer to just a portion of a reference-counted allocation

5 releases (3 breaking)

0.4.0 Sep 3, 2024
0.3.1 Aug 30, 2024
0.3.0 Aug 30, 2024
0.2.0 Aug 25, 2024
0.1.0 Aug 25, 2024

#1 in #portion

Download history 242/week @ 2024-08-23 365/week @ 2024-08-30 22/week @ 2024-09-06 23/week @ 2024-09-13 6/week @ 2024-09-20 4/week @ 2024-09-27 1/week @ 2024-10-04 1/week @ 2024-10-11

251 downloads per month

Custom license

32KB
537 lines

alloc::rc::Rc and alloc::sync::Arc alternatives that allow the smart pointer to refer to just a portion of a reference-counted allocation.

This allows storing a pointer that comes from a reference-counted allocation without having to know the type of the allocation it came from. For example, if you've allocated storage for an entire struct then you can derive a pointer to just one of its fields while still keeping the entire allocation live.

No runtime deps

Features