]> git.lizzy.rs Git - rust.git/blob - src/test/ui/generator/yield-outside-generator-issue-78653.stderr
Auto merge of #87284 - Aaron1011:remove-paren-special, r=petrochenkov
[rust.git] / src / test / ui / generator / yield-outside-generator-issue-78653.stderr
1 error[E0627]: yield expression outside of generator literal
2   --> $DIR/yield-outside-generator-issue-78653.rs:4:5
3    |
4 LL |     yield || for i in 0 { }
5    |     ^^^^^^^^^^^^^^^^^^^^^^^
6
7 error[E0277]: `{integer}` is not an iterator
8   --> $DIR/yield-outside-generator-issue-78653.rs:4:23
9    |
10 LL |     yield || for i in 0 { }
11    |                       ^ `{integer}` is not an iterator
12    |
13    = help: the trait `Iterator` is not implemented for `{integer}`
14    = 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`
15    = note: required because of the requirements on the impl of `IntoIterator` for `{integer}`
16 note: required by `into_iter`
17   --> $SRC_DIR/core/src/iter/traits/collect.rs:LL:COL
18    |
19 LL |     fn into_iter(self) -> Self::IntoIter;
20    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
21
22 error: aborting due to 2 previous errors
23
24 Some errors have detailed explanations: E0277, E0627.
25 For more information about an error, try `rustc --explain E0277`.