2022-09-06 00:58:12 +00:00
|
|
|
//@ revisions: edition2015 edition2021
|
|
|
|
//@[edition2021]edition:2021
|
|
|
|
|
|
|
|
#![allow(warnings)]
|
|
|
|
|
|
|
|
fn ice() -> impl AsRef<Fn(&())> {
|
2022-11-11 10:29:27 +00:00
|
|
|
//[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]
|
2023-10-31 13:45:26 +00:00
|
|
|
//[edition2021]~| ERROR: the trait bound `(): AsRef<(dyn for<'a> Fn(&'a ()) + 'static)>` is not satisfied [E0277]
|
2022-09-06 00:58:12 +00:00
|
|
|
todo!()
|
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {}
|