summaryrefslogtreecommitdiffstats
path: root/tests/ui/mismatched_types/issue-74918-missing-lifetime.stderr
blob: 9ddea16294450b38afc98f196a1c780caf3d8661 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
error[E0106]: missing lifetime specifier
  --> $DIR/issue-74918-missing-lifetime.rs:9:30
   |
LL |     type Item = IteratorChunk<T, S>;
   |                              ^ expected named lifetime parameter
   |
help: consider introducing a named lifetime parameter
   |
LL |     type Item<'a> = IteratorChunk<'a, T, S>;
   |              ++++                 +++

error: `impl` item signature doesn't match `trait` item signature
  --> $DIR/issue-74918-missing-lifetime.rs:11:5
   |
LL |     fn next(&mut self) -> Option<IteratorChunk<T, S>> {
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ found `fn(&'1 mut ChunkingIterator<T, S>) -> Option<IteratorChunk<'1, T, S>>`
  --> $SRC_DIR/core/src/iter/traits/iterator.rs:LL:COL
   |
   = note: expected `fn(&'1 mut ChunkingIterator<T, S>) -> Option<IteratorChunk<'static, T, S>>`
   |
   = note: expected signature `fn(&'1 mut ChunkingIterator<T, S>) -> Option<IteratorChunk<'static, T, S>>`
              found signature `fn(&'1 mut ChunkingIterator<T, S>) -> Option<IteratorChunk<'1, T, S>>`
   = help: the lifetime requirements from the `impl` do not correspond to the requirements in the `trait`
   = help: verify the lifetime relationships in the `trait` and `impl` between the `self` argument, the other inputs and its output

error: aborting due to 2 previous errors

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