about summary refs log tree commit diff
path: root/tests/ui/impl-trait/in-trait/async-and-ret-ref.stderr
blob: 19ffff9d3f2bd68996431bd5c2f560e26cd4ed5c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
error[E0310]: the associated type `impl T` may not live long enough
  --> $DIR/async-and-ret-ref.rs:7:5
   |
LL |     async fn foo() -> &'static impl T;
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   |     |
   |     the associated type `impl T` must be valid for the static lifetime...
   |     ...so that the reference type `&'static impl T` does not outlive the data it points at

error: aborting due to 1 previous error

For more information about this error, try `rustc --explain E0310`.