diff options
Diffstat (limited to 'tests/ui/issues/issue-33687.rs')
-rw-r--r-- | tests/ui/issues/issue-33687.rs | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/ui/issues/issue-33687.rs b/tests/ui/issues/issue-33687.rs new file mode 100644 index 000000000..ac802ed86 --- /dev/null +++ b/tests/ui/issues/issue-33687.rs @@ -0,0 +1,17 @@ +// run-pass +#![feature(unboxed_closures)] +#![feature(fn_traits)] + +struct Test; + +impl FnOnce<(u32, u32)> for Test { + type Output = u32; + + extern "rust-call" fn call_once(self, (a, b): (u32, u32)) -> u32 { + a + b + } +} + +fn main() { + assert_eq!(Test(1u32, 2u32), 3u32); +} |