]> git.proxmox.com Git - rustc.git/blame - src/test/ui/iterators/string.stderr
New upstream version 1.55.0+dfsg1
[rustc.git] / src / test / ui / iterators / string.stderr
CommitLineData
1b1a35ee 1error[E0277]: `String` is not an iterator
0bf4aa26
XL
2 --> $DIR/string.rs:2:14
3 |
4LL | for _ in "".to_owned() {}
cdc7bbd5 5 | ^^^^^^^^^^^^^ `String` is not an iterator; try calling `.chars()` or `.bytes()`
0bf4aa26 6 |
1b1a35ee 7 = help: the trait `Iterator` is not implemented for `String`
29967ef6 8 = note: required because of the requirements on the impl of `IntoIterator` for `String`
136023e0
XL
9note: required by `into_iter`
10 --> $SRC_DIR/core/src/iter/traits/collect.rs:LL:COL
11 |
12LL | fn into_iter(self) -> Self::IntoIter;
13 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
0bf4aa26
XL
14
15error[E0277]: `&str` is not an iterator
16 --> $DIR/string.rs:4:14
17 |
18LL | for _ in "" {}
19 | ^^ `&str` is not an iterator; try calling `.chars()` or `.bytes()`
20 |
1b1a35ee 21 = help: the trait `Iterator` is not implemented for `&str`
29967ef6 22 = note: required because of the requirements on the impl of `IntoIterator` for `&str`
136023e0
XL
23note: required by `into_iter`
24 --> $SRC_DIR/core/src/iter/traits/collect.rs:LL:COL
25 |
26LL | fn into_iter(self) -> Self::IntoIter;
27 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
0bf4aa26
XL
28
29error: aborting due to 2 previous errors
30
31For more information about this error, try `rustc --explain E0277`.