mirror of
https://github.com/girlbossceo/jemallocator.git
synced 2024-11-26 07:31:15 +00:00
13 lines
222 B
Rust
13 lines
222 B
Rust
extern crate jemallocator;
|
|
|
|
use jemallocator::Jemalloc;
|
|
|
|
#[global_allocator]
|
|
static A: Jemalloc = Jemalloc;
|
|
|
|
#[test]
|
|
fn smoke() {
|
|
let a = Box::new(3_u32);
|
|
assert!(unsafe { jemallocator::usable_size(&*a) } >= 4);
|
|
}
|