]> git.lizzy.rs Git - rust.git/blob - src/test/ui/alloc-error/alloc-error-handler-bad-signature-1.rs
Auto merge of #106143 - matthiaskrgr:rollup-3kpy1dc, r=matthiaskrgr
[rust.git] / src / test / ui / alloc-error / alloc-error-handler-bad-signature-1.rs
1 // compile-flags:-C panic=abort
2
3 #![feature(alloc_error_handler)]
4 #![no_std]
5 #![no_main]
6
7 use core::alloc::Layout;
8
9 #[alloc_error_handler]
10 fn oom(
11     info: &Layout, //~^ ERROR mismatched types
12 ) -> () //~^^ ERROR mismatched types
13 {
14     loop {}
15 }
16
17 #[panic_handler]
18 fn panic(_: &core::panic::PanicInfo) -> ! { loop {} }