rust/src/test/ui/impl-trait/generic-with-implicit-hrtb-without-dyn.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

13 lines
337 B
Rust
Raw Normal View History

// revisions: edition2015 edition2021
//[edition2021]edition:2021
#![allow(warnings)]
fn ice() -> impl AsRef<Fn(&())> {
2022-09-21 17:57:30 +02:00
//~^ 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]
todo!()
}
fn main() {}