rust/src/test/run-pass/nullary-or-pattern.rs
Tim Chevalier 5b028f527f Remove support for the '.' after a nullary tag in a pattern
(Commit also includes lots of changes to remove '.'s that a git
merge messed up, or else it was monkeys.)
2012-01-19 01:04:59 -08:00

11 lines
150 B
Rust

tag blah { a; b; }
fn or_alt(q: blah) -> int {
alt q { a | b { 42 } }
}
fn main() {
assert (or_alt(a) == 42);
assert (or_alt(b) == 42);
}