]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-20605.stderr
point at private fields in struct literal
[rust.git] / src / test / ui / issues / issue-20605.stderr
1 error[E0277]: the size for values of type `dyn Iterator<Item = &'a mut u8>` cannot be known at compilation time
2   --> $DIR/issue-20605.rs:2:17
3    |
4 LL |     for item in *things { *item = 0 }
5    |                 ^^^^^^^ expected an implementor of trait `IntoIterator`
6    |
7    = note: the trait bound `dyn Iterator<Item = &'a mut u8>: IntoIterator` is not satisfied
8    = note: required because of the requirements on the impl of `IntoIterator` for `dyn Iterator<Item = &'a mut u8>`
9 help: consider mutably borrowing here
10    |
11 LL |     for item in &mut *things { *item = 0 }
12    |                 ++++
13
14 error: aborting due to previous error
15
16 For more information about this error, try `rustc --explain E0277`.