airbender_rt/allocator/
mod.rs1#[cfg(not(any(
4 feature = "allocator-bump",
5 feature = "allocator-talc",
6 feature = "allocator-custom"
7)))]
8compile_error!(
9 "enable one allocator feature: `allocator-bump`, `allocator-talc`, or `allocator-custom`"
10);
11
12#[cfg(any(
13 all(feature = "allocator-bump", feature = "allocator-talc"),
14 all(feature = "allocator-bump", feature = "allocator-custom"),
15 all(feature = "allocator-talc", feature = "allocator-custom"),
16))]
17compile_error!(
18 "allocator features are mutually exclusive; enable only one of `allocator-bump`, `allocator-talc`, `allocator-custom`"
19);
20
21#[cfg(feature = "allocator-bump")]
22mod bump_allocator;
23#[cfg(feature = "allocator-bump")]
24pub use bump_allocator::{init, BumpAllocator};
25
26#[cfg(feature = "allocator-talc")]
27mod talc_allocator;
28#[cfg(feature = "allocator-talc")]
29pub use talc_allocator::{init, TalcAllocator};