]> git.lizzy.rs Git - rust.git/blob - tests/ui/generic-associated-types/bugs/issue-88382.stderr
Auto merge of #106458 - albertlarsan68:move-tests, r=jyn514
[rust.git] / tests / ui / generic-associated-types / bugs / issue-88382.stderr
1 error[E0631]: type mismatch in function arguments
2   --> $DIR/issue-88382.rs:26:40
3    |
4 LL |     do_something(SomeImplementation(), test);
5    |     ------------                       ^^^^ expected due to this
6    |     |
7    |     required by a bound introduced by this call
8 ...
9 LL | fn test<'a, I: Iterable>(_: &mut I::Iterator<'a>) {}
10    | ------------------------------------------------- found signature defined here
11    |
12    = note: expected function signature `for<'a> fn(&'a mut std::iter::Empty<usize>) -> _`
13               found function signature `for<'a, 'b> fn(&'b mut <_ as Iterable>::Iterator<'a>) -> _`
14 note: required by a bound in `do_something`
15   --> $DIR/issue-88382.rs:20:48
16    |
17 LL | fn do_something<I: Iterable>(i: I, mut f: impl for<'a> Fn(&mut I::Iterator<'a>)) {
18    |                                                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `do_something`
19
20 error: aborting due to previous error
21
22 For more information about this error, try `rustc --explain E0631`.