2 releases
0.1.1 | May 15, 2022 |
---|---|
0.1.0 | Nov 28, 2021 |
#462 in Concurrency
5,536 downloads per month
29KB
730 lines
atomic-arena
crates.io | docs
atomic-arena
is a generational arena that uses a reservation system to allow getting valid keys from different threads.
License
This project is licensed under either of
- Apache License, Version 2.0 (LICENSE-APACHE)
- MIT license (LICENSE-MIT)
at your option.
Contribution
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in atomic-arena
by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.
lib.rs
:
atomic_arena
provides a generational Arena
that you can reserve
a [Key
] for ahead of time using a Controller
. Controller
s
are backed by atomics, so they can be cloned and used across threads
and still have consistent state.
This is useful when you want to insert an item into an Arena
on
a different thread, but you want to have a valid [Key
] for that
item immediately on the current thread.