1
Fork 0
rust/src/test/compile-fail/match-struct.rs

12 lines
154 B
Rust
Raw Normal View History

// error-pattern: mismatched types
struct S { a: int }
enum E { C(int) }
fn main() {
match S { a: 1 } {
C(_) => (),
_ => ()
}
}