1 error: lifetime may not live long enough
2 --> $DIR/dyn-trait-underscore.rs:8:5
4 LL | fn a<T>(items: &[T]) -> Box<dyn Iterator<Item=&T>> {
5 | - let's call the lifetime of this reference `'1`
6 LL | // ^^^^^^^^^^^^^^^^^^^^^ bound *here* defaults to `'static`
7 LL | Box::new(items.iter())
8 | ^^^^^^^^^^^^^^^^^^^^^^ returning this value requires that `'1` must outlive `'static`
10 help: to declare that the trait object captures data from argument `items`, you can add an explicit `'_` lifetime bound
12 LL | fn a<T>(items: &[T]) -> Box<dyn Iterator<Item=&T> + '_> {
15 error: aborting due to previous error