We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
&mut
1 parent 733bdd0 commit f23003dCopy full SHA for f23003d
src/test/ui/issues/issue-20605.stderr
@@ -2,9 +2,12 @@ error[E0277]: the size for values of type `dyn Iterator<Item = &'a mut u8>` cann
2
--> $DIR/issue-20605.rs:2:17
3
|
4
LL | for item in *things { *item = 0 }
5
- | ^^^^^^^ doesn't have a size known at compile-time
+ | ^^^^^^^
6
+ | |
7
+ | expected an implementor of trait `IntoIterator`
8
+ | help: consider mutably borrowing here: `&mut *things`
9
- = help: the trait `Sized` is not implemented for `dyn Iterator<Item = &'a mut u8>`
10
+ = note: the trait bound `dyn Iterator<Item = &'a mut u8>: IntoIterator` is not satisfied
11
= note: required because of the requirements on the impl of `IntoIterator` for `dyn Iterator<Item = &'a mut u8>`
12
note: required by `into_iter`
13
--> $SRC_DIR/core/src/iter/traits/collect.rs:LL:COL
0 commit comments