You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
error[E0277]: `dyn Iterator<Item = &'a mut u8>` is not an iterator
2
+
--> $DIR/iter_from_mac_call.rs:6:17
3
+
|
4
+
LL | for item in deref!(iter) { *item = 0 }
5
+
| ^^^^^^^^^^^^ the trait `IntoIterator` is not implemented for `dyn Iterator<Item = &'a mut u8>`
6
+
|
7
+
= note: the trait bound `dyn Iterator<Item = &'a mut u8>: IntoIterator` is not satisfied
8
+
= note: required for `dyn Iterator<Item = &'a mut u8>` to implement `IntoIterator`
9
+
help: consider mutably borrowing here
10
+
|
11
+
LL | for item in &mut deref!(iter) { *item = 0 }
12
+
| ++++
13
+
14
+
error[E0277]: `i32` is not an iterator
15
+
--> $DIR/iter_from_mac_call.rs:11:18
16
+
|
17
+
LL | for _item in deref!(x) {}
18
+
| ^^^^^^^^^ `i32` is not an iterator
19
+
|
20
+
= help: the trait `Iterator` is not implemented for `i32`
21
+
= note: if you want to iterate between `start` until a value `end`, use the exclusive range syntax `start..end` or the inclusive range syntax `start..=end`
22
+
= note: required for `i32` to implement `IntoIterator`
23
+
24
+
error[E0308]: mismatched types
25
+
--> $DIR/iter_from_mac_call.rs:22:9
26
+
|
27
+
LL | for Wrapped(item) in borrow_deref!(iter) { *item = 0 }
28
+
| ^^^^^^^^^^^^^ ------------------- this is an iterator with items of type `&mut i32`
29
+
| |
30
+
| expected `i32`, found `Wrapped`
31
+
32
+
error: aborting due to 3 previous errors
33
+
34
+
Some errors have detailed explanations: E0277, E0308.
35
+
For more information about an error, try `rustc --explain E0277`.
0 commit comments