mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-23 07:14:28 +00:00
14 lines
471 B
Rust
14 lines
471 B
Rust
//@ revisions: edition2015 edition2021
|
|
//@[edition2021]edition:2021
|
|
|
|
#![allow(warnings)]
|
|
|
|
fn ice() -> impl AsRef<Fn(&())> {
|
|
//[edition2015]~^ ERROR: the trait bound `(): AsRef<(dyn for<'a> Fn(&'a ()) + 'static)>` is not satisfied [E0277]
|
|
//[edition2021]~^^ ERROR: trait objects must include the `dyn` keyword [E0782]
|
|
//[edition2021]~| ERROR: the trait bound `(): AsRef<(dyn for<'a> Fn(&'a ()) + 'static)>` is not satisfied [E0277]
|
|
todo!()
|
|
}
|
|
|
|
fn main() {}
|