Fix unused_variables in tests

This commit is contained in:
hkalbasi 2023-09-24 23:45:36 +03:30
parent 7834b8fadb
commit ab52ba2de7
13 changed files with 122 additions and 104 deletions

View file

@ -290,6 +290,7 @@ fn x(a: S) {
struct S { s: u32 }
fn x(a: S) {
let S { ref s } = a;
_ = s;
}
",
)
@ -626,7 +627,7 @@ struct TestStruct { one: i32, two: i64 }
fn test_fn() {
let one = 1;
let s = TestStruct{ one, two: 2 };
let _s = TestStruct{ one, two: 2 };
}
"#,
);