mirror of
https://github.com/github/codeql.git
synced 2026-05-01 11:45:14 +02:00
Rust: Update unused value expected test result
This commit is contained in:
@@ -18,7 +18,6 @@
|
||||
| main.rs:348:5:348:39 | kind | Variable is assigned a value that is never used. |
|
||||
| main.rs:370:9:370:9 | x | Variable is assigned a value that is never used. |
|
||||
| main.rs:378:17:378:17 | x | Variable is assigned a value that is never used. |
|
||||
| main.rs:432:9:432:10 | i6 | Variable is assigned a value that is never used. |
|
||||
| more.rs:24:9:24:11 | val | Variable is assigned a value that is never used. |
|
||||
| more.rs:46:9:46:14 | a_ptr4 | Variable is assigned a value that is never used. |
|
||||
| more.rs:61:9:61:13 | d_ptr | Variable is assigned a value that is never used. |
|
||||
|
||||
@@ -429,7 +429,7 @@ fn folds_and_closures() {
|
||||
let a5 = 1..10;
|
||||
_ = a5.fold(0, | acc, val | val); // BAD: unused variable
|
||||
|
||||
let i6 = 1; // SPURIOUS: unused value
|
||||
let i6 = 1;
|
||||
let a6 = 1..10;
|
||||
_ = a6.fold(0, | acc, val | acc + val + i6);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user