blob: 6b99a9d0a74221778a5075b2fd0e01fbe9380881 [file] [log] [blame]
// Test old and new syntax for inclusive range patterns.
fn main() {
assert!(match 42 { 0 ... 100 => true, _ => false });
assert!(match 42 { 0 ..= 100 => true, _ => false });
assert!(match 'x' { 'a' ... 'z' => true, _ => false });
assert!(match 'x' { 'a' ..= 'z' => true, _ => false });
}