Files
posthog/rust/common/alloc/src/lib.rs
2024-09-05 06:19:25 +00:00

13 lines
328 B
Rust

#[cfg(target_env = "msvc")]
pub use std::alloc::System as DefaultAllocator;
#[cfg(not(target_env = "msvc"))]
pub use tikv_jemallocator::Jemalloc as DefaultAllocator;
#[macro_export]
macro_rules! used {
() => {
#[global_allocator]
static GLOBAL: $crate::DefaultAllocator = $crate::DefaultAllocator;
};
}