mirror of
https://github.com/rust-lang/rust.git
synced 2025-10-15 08:46:41 +00:00
8 lines
211 B
Rust
8 lines
211 B
Rust
// Regression test for #135209.
|
|
// We ensure that we don't try to access fields on a non-struct pattern type.
|
|
fn main() {
|
|
if let Iterator::Item { .. } = 1 { //~ ERROR E0223
|
|
x //~ ERROR E0425
|
|
}
|
|
}
|