about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorRich Kadel <richkadel@google.com>2021-04-18 11:51:42 -0700
committerRich Kadel <richkadel@google.com>2021-04-18 12:09:14 -0700
commitd1d7fb1ae53a02f5073a7cf0ab1497aaa9617ebe (patch)
tree303b7985d5ad4dec212e120fe13750a1900780fc /src
parent448e52d97c9b76600fd1ec29c8159391329e48ab (diff)
downloadrust-d1d7fb1ae53a02f5073a7cf0ab1497aaa9617ebe.tar.gz
rust-d1d7fb1ae53a02f5073a7cf0ab1497aaa9617ebe.zip
Only generate dummy assign when instrumenting coverage
And make the LocalDecl internal, to avoid needing to declare storage.
(For multiple `continue` stateuemtns, it must also be mutable.)
Diffstat (limited to 'src')
-rw-r--r--src/test/mir-opt/loop_test.main.SimplifyCfg-promote-consts.after.mir4
1 files changed, 0 insertions, 4 deletions
diff --git a/src/test/mir-opt/loop_test.main.SimplifyCfg-promote-consts.after.mir b/src/test/mir-opt/loop_test.main.SimplifyCfg-promote-consts.after.mir
index f6120447017..99c7ac8d5b7 100644
--- a/src/test/mir-opt/loop_test.main.SimplifyCfg-promote-consts.after.mir
+++ b/src/test/mir-opt/loop_test.main.SimplifyCfg-promote-consts.after.mir
@@ -8,7 +8,6 @@ fn main() -> () {
     let mut _4: !;                       // in scope 0 at $DIR/loop_test.rs:13:5: 16:6
     let mut _5: ();                      // in scope 0 at $DIR/loop_test.rs:6:1: 17:2
     let _6: i32;                         // in scope 0 at $DIR/loop_test.rs:14:13: 14:14
-    let _7: ();                          // in scope 0 at $DIR/loop_test.rs:15:9: 15:17
     scope 1 {
         debug x => _6;                   // in scope 1 at $DIR/loop_test.rs:14:13: 14:14
     }
@@ -43,9 +42,6 @@ fn main() -> () {
         StorageLive(_6);                 // scope 0 at $DIR/loop_test.rs:14:13: 14:14
         _6 = const 1_i32;                // scope 0 at $DIR/loop_test.rs:14:17: 14:18
         FakeRead(ForLet(None), _6);      // scope 0 at $DIR/loop_test.rs:14:13: 14:14
-        StorageLive(_7);                 // scope 1 at $DIR/loop_test.rs:15:9: 15:17
-        _7 = const ();                   // scope 1 at $DIR/loop_test.rs:15:9: 15:17
-        StorageDead(_7);                 // scope 1 at $DIR/loop_test.rs:15:9: 15:17
         StorageDead(_6);                 // scope 0 at $DIR/loop_test.rs:16:5: 16:6
         goto -> bb3;                     // scope 0 at $DIR/loop_test.rs:1:1: 1:1
     }