diff --git a/src/test/ui/issues/issue-19982-2.rs b/src/test/ui/issues/issue-19982-2.rs deleted file mode 100644 index 8c3462dcf45d..000000000000 --- a/src/test/ui/issues/issue-19982-2.rs +++ /dev/null @@ -1,33 +0,0 @@ -// Copyright 2015 The Rust Project Developers. See the COPYRIGHT -// file at the top-level directory of this distribution and at -// http://rust-lang.org/COPYRIGHT. -// -// Licensed under the Apache License, Version 2.0 or the MIT license -// , at your -// option. This file may not be copied, modified, or distributed -// except according to those terms. - -// compile-pass -// pretty-expanded FIXME #23616 - -#![feature(fn_traits, unboxed_closures)] - -#[allow(dead_code)] -struct Foo; - -impl<'a> Fn<(&'a (),)> for Foo { - extern "rust-call" fn call(&self, (_,): (&(),)) {} -} - -impl<'a> FnMut<(&'a (),)> for Foo { - extern "rust-call" fn call_mut(&mut self, (_,): (&(),)) {} -} - -impl<'a> FnOnce<(&'a (),)> for Foo { - type Output = (); - - extern "rust-call" fn call_once(self, (_,): (&(),)) {} -} - -fn main() {} diff --git a/src/test/ui/issues/issue-19982.rs b/src/test/ui/issues/issue-19982.rs index 9dbca997341f..3de817c28a85 100644 --- a/src/test/ui/issues/issue-19982.rs +++ b/src/test/ui/issues/issue-19982.rs @@ -8,10 +8,25 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#![feature(unboxed_closures)] +// compile-pass +#![feature(fn_traits, unboxed_closures)] + +#[allow(dead_code)] struct Foo; -impl Fn<(&(),)> for Foo { } //~ ERROR missing lifetime specifier +impl Fn<(&(),)> for Foo { + extern "rust-call" fn call(&self, (_,): (&(),)) {} +} + +impl FnMut<(&(),)> for Foo { + extern "rust-call" fn call_mut(&mut self, (_,): (&(),)) {} +} + +impl FnOnce<(&(),)> for Foo { + type Output = (); + + extern "rust-call" fn call_once(self, (_,): (&(),)) {} +} fn main() {} diff --git a/src/test/ui/issues/issue-19982.stderr b/src/test/ui/issues/issue-19982.stderr deleted file mode 100644 index 9f13ba640a95..000000000000 --- a/src/test/ui/issues/issue-19982.stderr +++ /dev/null @@ -1,9 +0,0 @@ -error[E0106]: missing lifetime specifier - --> $DIR/issue-19982.rs:15:10 - | -LL | impl Fn<(&(),)> for Foo { } //~ ERROR missing lifetime specifier - | ^ expected lifetime parameter - -error: aborting due to previous error - -For more information about this error, try `rustc --explain E0106`.