summaryrefslogtreecommitdiffstats
path: root/tests/ui/missing/missing-allocator.rs
blob: 2dc509f2c632da0b599b2be0beacc1a39c0f4594 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// compile-flags: -C panic=abort
// no-prefer-dynamic

#![no_std]
#![crate_type = "staticlib"]
#![feature(alloc_error_handler)]

#[panic_handler]
fn panic(_: &core::panic::PanicInfo) -> ! {
    loop {}
}

#[alloc_error_handler]
fn oom(_: core::alloc::Layout) -> ! {
    loop {}
}

extern crate alloc;