Commit 0dd4bfa
authored
Rollup merge of rust-lang#57302 - sinkuu:unused_assignments_fp, r=estebank
Fix unused_assignments false positive
Fixes rust-lang#22630.
In liveness analysis, make `continue` jump to the loop condition's `LiveNode` (`cond` as in comment) instead of the loop's one (`expr`).
https://github.com/rust-lang/rust/blob/069b0c410808c1d1d33b495e048b1186e9f8d57f/src/librustc/middle/liveness.rs#L1358-L1370File tree
2 files changed
+15
-23
lines changed- src
- librustc/middle
- test/ui/liveness
2 files changed
+15
-23
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
911 | 911 | | |
912 | 912 | | |
913 | 913 | | |
914 | | - | |
915 | | - | |
916 | | - | |
917 | | - | |
918 | 914 | | |
919 | 915 | | |
920 | | - | |
921 | | - | |
922 | | - | |
923 | | - | |
924 | | - | |
925 | 916 | | |
926 | 917 | | |
927 | 918 | | |
| |||
1024 | 1015 | | |
1025 | 1016 | | |
1026 | 1017 | | |
1027 | | - | |
| 1018 | + | |
1028 | 1019 | | |
1029 | 1020 | | |
1030 | 1021 | | |
1031 | | - | |
1032 | | - | |
1033 | | - | |
1034 | | - | |
1035 | | - | |
1036 | | - | |
1037 | | - | |
1038 | | - | |
1039 | | - | |
1040 | 1022 | | |
1041 | 1023 | | |
1042 | 1024 | | |
| |||
1407 | 1389 | | |
1408 | 1390 | | |
1409 | 1391 | | |
1410 | | - | |
1411 | | - | |
1412 | | - | |
1413 | | - | |
| 1392 | + | |
| 1393 | + | |
1414 | 1394 | | |
1415 | 1395 | | |
1416 | 1396 | | |
1417 | 1397 | | |
1418 | 1398 | | |
| 1399 | + | |
| 1400 | + | |
| 1401 | + | |
1419 | 1402 | | |
1420 | 1403 | | |
1421 | 1404 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
30 | 39 | | |
0 commit comments