| error[E0310]: the associated type `impl Fn()` may not live long enough |
| --> $DIR/missing-static-bound-from-impl.rs:11:9 |
| | |
| LL | fn f(&self) -> Box<dyn Fn()> { |
| | -------- this `dyn Trait` has an implicit `'static` lifetime bound |
| LL | Box::new(<T as Original>::f()) |
| | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| | | |
| | the associated type `impl Fn()` must be valid for the static lifetime... |
| | ...so that the type `impl Fn()` will meet its required lifetime bounds |
| |
| error: aborting due to 1 previous error |
| |
| For more information about this error, try `rustc --explain E0310`. |