about summary refs log tree commit diff
path: root/tests/ui/impl-trait/precise-capturing/redundant.rpitit.stderr
blob: 9aa73353126cd550d7e884be936aeb24f4d037fc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
error: `use<...>` precise capturing syntax is currently not allowed in return-position `impl Trait` in traits
  --> $DIR/redundant.rs:18:35
   |
LL |     fn in_trait() -> impl Sized + use<'a, Self>;
   |                                   ^^^^^^^^^^^^^
   |
   = note: currently, return-position `impl Trait` in traits and trait implementations capture all lifetimes in scope

error: `use<...>` precise capturing syntax is currently not allowed in return-position `impl Trait` in traits
  --> $DIR/redundant.rs:23:35
   |
LL |     fn in_trait() -> impl Sized + use<'a> {}
   |                                   ^^^^^^^
   |
   = note: currently, return-position `impl Trait` in traits and trait implementations capture all lifetimes in scope

error: aborting due to 2 previous errors