rust/tests/ui/suggestions/issue-52820.rs
2024-02-16 20:02:50 +00:00

16 lines
262 B
Rust

//@ run-rustfix
#![allow(dead_code)]
struct Bravery {
guts: String,
brains: String,
}
fn main() {
let guts = "mettle";
let _ = Bravery {
guts, //~ ERROR mismatched types
brains: guts.clone(), //~ ERROR mismatched types
};
}