rust/tests/ui/missing/missing-allocator.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

19 lines
301 B
Rust
Raw Normal View History

// compile-flags: -C panic=abort
// no-prefer-dynamic
#![no_std]
#![crate_type = "staticlib"]
2022-01-19 15:24:49 +00:00
#![feature(alloc_error_handler)]
#[panic_handler]
fn panic(_: &core::panic::PanicInfo) -> ! {
loop {}
}
#[alloc_error_handler]
fn oom(_: core::alloc::Layout) -> ! {
loop {}
}
extern crate alloc;