]> git.lizzy.rs Git - rust.git/blob - src/test/ui/feature-gates/feature-gate-unboxed-closures.rs
Rollup merge of #94359 - tmiasko:legacy-verbose-const, r=petrochenkov
[rust.git] / src / test / ui / feature-gates / feature-gate-unboxed-closures.rs
1 #![feature(fn_traits)]
2
3 struct Test;
4
5 impl FnOnce<(u32, u32)> for Test {
6 //~^ ERROR the precise format of `Fn`-family traits' type parameters is subject to change
7 //~| ERROR manual implementations of `FnOnce` are experimental
8     type Output = u32;
9
10     extern "rust-call" fn call_once(self, (a, b): (u32, u32)) -> u32 {
11         a + b
12     }
13     //~^^^ ERROR rust-call ABI is subject to change
14 }
15
16 fn main() {
17     assert_eq!(Test(1u32, 2u32), 3u32);
18 }