]> git.lizzy.rs Git - rust.git/blob - src/test/ui/lang-item-missing-generator.rs
Rollup merge of #82259 - osa1:issue82156, r=petrochenkov
[rust.git] / src / test / ui / lang-item-missing-generator.rs
1 // error-pattern: requires `generator` lang_item
2 #![feature(no_core, lang_items, unboxed_closures)]
3 #![no_core]
4
5 #[lang = "sized"] pub trait Sized { }
6
7 #[lang = "fn_once"]
8 #[rustc_paren_sugar]
9 pub trait FnOnce<Args> {
10     type Output;
11
12     extern "rust-call" fn call_once(self, args: Args) -> Self::Output;
13 }
14
15 pub fn abc() -> impl FnOnce(f32) {
16     |_| {}
17 }
18
19 fn main() {}