rust/tests/ui/issues/issue-14541.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

11 lines
195 B
Rust
Raw Normal View History

struct Vec2 { y: f32 }
struct Vec3 { y: f32, z: f32 }
fn make(v: Vec2) {
let Vec3 { y: _, z: _ } = v;
2015-01-12 06:01:44 +00:00
//~^ ERROR mismatched types
//~| expected `Vec2`, found `Vec3`
}
fn main() { }