mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-16 21:15:18 +03:00
18 lines
343 B
Rust
18 lines
343 B
Rust
// Make sure that invalid ranges generate an error during HIR lowering, not an ICE
|
|
|
|
pub fn main() {
|
|
..;
|
|
0..;
|
|
..1;
|
|
0..1;
|
|
..=; //~ERROR inclusive range with no end
|
|
//~^HELP bounded at the end
|
|
}
|
|
|
|
fn _foo1() {
|
|
..=1;
|
|
0..=1;
|
|
0..=; //~ERROR inclusive range with no end
|
|
//~^HELP bounded at the end
|
|
}
|