]> git.lizzy.rs Git - rust.git/blob - src/test/ui/half-open-range-patterns/exclusive_range_pattern_syntax_collision2.stderr
Rollup merge of #105674 - estebank:iterator-chains, r=oli-obk
[rust.git] / src / test / ui / half-open-range-patterns / exclusive_range_pattern_syntax_collision2.stderr
1 error[E0527]: pattern requires 2 elements but array has 3
2   --> $DIR/exclusive_range_pattern_syntax_collision2.rs:6:9
3    |
4 LL |         [_, 99..] => {},
5    |         ^^^^^^^^^ expected 3 elements
6
7 error[E0308]: mismatched types
8   --> $DIR/exclusive_range_pattern_syntax_collision2.rs:6:13
9    |
10 LL |     match [5..4, 99..105, 43..44] {
11    |           ----------------------- this expression has type `[std::ops::Range<{integer}>; 3]`
12 LL |         [_, 99..] => {},
13    |             ^^ expected struct `Range`, found integer
14    |
15    = note: expected struct `std::ops::Range<{integer}>`
16                 found type `{integer}`
17
18 error: aborting due to 2 previous errors
19
20 Some errors have detailed explanations: E0308, E0527.
21 For more information about an error, try `rustc --explain E0308`.