]> git.lizzy.rs Git - rust.git/blob - src/test/ui/alloc-error/alloc-error-handler-bad-signature-2.rs
Auto merge of #100845 - timvermeulen:iter_compare, r=scottmcm
[rust.git] / src / test / ui / alloc-error / alloc-error-handler-bad-signature-2.rs
1 // compile-flags:-C panic=abort
2
3 #![feature(alloc_error_handler)]
4 #![no_std]
5 #![no_main]
6
7 struct Layout;
8
9 #[alloc_error_handler]
10 fn oom(
11     info: Layout, //~ ERROR argument should be `Layout`
12 ) { //~ ERROR return type should be `!`
13     loop {}
14 }
15
16 #[panic_handler]
17 fn panic(_: &core::panic::PanicInfo) -> ! { loop {} }