bh_alloc 0.2.4

A fuzzer friendly bump pointer allocator
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
extern crate bh_alloc;
extern crate hashbrown;

#[global_allocator]
static ALLOC: bh_alloc::BumpAlloc = bh_alloc::BumpAlloc::INIT;

#[test]
fn hello_world() {
    println!("Hello, world!");
}

#[test]
fn alloc_and_destroy() {
    for i in 0..5_000 {
        let bi = Box::new(i);
        drop(bi);
    }
}