This change makes error and warning annotations mandatory in UI tests. The only exception are tests that use error patterns to match compiler output and don't have any annotations.
19 lines
339 B
Rust
19 lines
339 B
Rust
// run-pass
|
|
|
|
#[derive(PartialEq, Eq, Copy, Clone)]
|
|
#[repr(packed)]
|
|
struct Foo {
|
|
field: (i64, u32, u32, u32),
|
|
}
|
|
|
|
const FOO: Foo = Foo {
|
|
field: (5, 6, 7, 8),
|
|
};
|
|
|
|
fn main() {
|
|
match FOO {
|
|
Foo { field: (5, 6, 7, 8) } => {},
|
|
FOO => unreachable!(), //~ WARNING unreachable pattern
|
|
_ => unreachable!(),
|
|
}
|
|
}
|