File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed
rust/ql/test/query-tests/unusedentities Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change 1
- | main.rs:23 :9:23 :9 | a | Variable is not used. |
2
- | main.rs:88 :13:88 :13 | d | Variable is not used. |
3
- | main.rs:112 :9:112 :9 | k | Variable is not used. |
4
- | main.rs:139 :5:139 :5 | y | Variable is not used. |
1
+ | main.rs:25 :9:25 :9 | a | Variable is not used. |
2
+ | main.rs:90 :13:90 :13 | d | Variable is not used. |
3
+ | main.rs:114 :9:114 :9 | k | Variable is not used. |
4
+ | main.rs:141 :5:141 :5 | y | Variable is not used. |
Original file line number Diff line number Diff line change @@ -8,6 +8,7 @@ fn locals_1() {
8
8
let c = 1 ;
9
9
let d = String :: from ( "a" ) ; // BAD: unused value [NOT DETECTED]
10
10
let e = String :: from ( "b" ) ;
11
+
11
12
let _ = 1 ; // (deliberately unused)
12
13
13
14
println ! ( "use {}" , b) ;
@@ -17,6 +18,7 @@ fn locals_1() {
17
18
}
18
19
19
20
println ! ( "use {}" , e) ;
21
+
20
22
}
21
23
22
24
fn locals_2 ( ) {
You can’t perform that action at this time.
0 commit comments