Skip to main content

imbl/
shared_ptr.rs

1//! About shared pointers. Re-export the [`archery`] crate.
2//!
3//! [`archery`]: https://docs.rs/archery/latest/
4
5pub use archery::{ArcK, RcK, SharedPointer, SharedPointerKind};
6
7#[cfg(feature = "triomphe")]
8pub use archery::ArcTK;
9
10#[cfg(not(feature = "triomphe"))]
11/// Default shared pointer used in data structures like [`vector::Vector`] in this crate. This alias points to [`ArcK`] if `triomphe` is disabled, [`ArcTK`] otherwise.
12///
13/// [`vector::Vector`]: ./type.Vector.html
14/// [`ArcK`]: https://docs.rs/archery/latest/archery/shared_pointer/kind/struct.ArcK.html
15/// [`ArcTK`]: https://docs.rs/archery/latest/archery/shared_pointer/kind/struct.ArcTK.html
16pub type DefaultSharedPtr = ArcK;
17
18#[cfg(feature = "triomphe")]
19/// Default shared pointer used in data structures like [`vector::Vector`] in this crate. This alias points to [`ArcK`] if `triomphe` is disabled, [`ArcTK`] otherwise.
20///
21/// [`vector::Vector`]: ./type.Vector.html
22/// [`ArcK`]: https://docs.rs/archery/latest/archery/shared_pointer/kind/struct.ArcK.html
23/// [`ArcTK`]: https://docs.rs/archery/latest/archery/shared_pointer/kind/struct.ArcTK.html
24pub type DefaultSharedPtr = ArcTK;