diff options
Diffstat (limited to '')
-rw-r--r-- | src/test/ui/suggestions/issue-52820.rs | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/test/ui/suggestions/issue-52820.rs b/src/test/ui/suggestions/issue-52820.rs new file mode 100644 index 000000000..17cd9224c --- /dev/null +++ b/src/test/ui/suggestions/issue-52820.rs @@ -0,0 +1,15 @@ +// 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 + }; +} |