X-Git-Url: https://git.lizzy.rs/?a=blobdiff_plain;f=src%2Ftest%2Fmir-opt%2Fconst_prop%2Fref_deref_project.main.PromoteTemps.diff;h=6f3a060a1260a87281f8b73dbed98d1c80ffdb99;hb=75b7089d1efbb80c810ce906ff96a9da8bdd9a9c;hp=2df963556a9eec6dd5319d44b92167ba0f3b0d55;hpb=591b0563763955b6e666a3b010dc379e3ec3afe9;p=rust.git diff --git a/src/test/mir-opt/const_prop/ref_deref_project.main.PromoteTemps.diff b/src/test/mir-opt/const_prop/ref_deref_project.main.PromoteTemps.diff index 2df963556a9..6f3a060a126 100644 --- a/src/test/mir-opt/const_prop/ref_deref_project.main.PromoteTemps.diff +++ b/src/test/mir-opt/const_prop/ref_deref_project.main.PromoteTemps.diff @@ -2,29 +2,29 @@ + // MIR for `main` after PromoteTemps fn main() -> () { - let mut _0: (); // return place in scope 0 at $DIR/ref_deref_project.rs:4:11: 4:11 - let _1: i32; // in scope 0 at $DIR/ref_deref_project.rs:5:5: 5:17 - let mut _2: &i32; // in scope 0 at $DIR/ref_deref_project.rs:5:6: 5:17 - let _3: (i32, i32); // in scope 0 at $DIR/ref_deref_project.rs:5:8: 5:14 -+ let mut _4: &(i32, i32); // in scope 0 at $DIR/ref_deref_project.rs:5:6: 5:17 + let mut _0: (); // return place in scope 0 at $DIR/ref_deref_project.rs:+0:11: +0:11 + let _1: i32; // in scope 0 at $DIR/ref_deref_project.rs:+1:5: +1:17 + let mut _2: &i32; // in scope 0 at $DIR/ref_deref_project.rs:+1:6: +1:17 + let _3: (i32, i32); // in scope 0 at $DIR/ref_deref_project.rs:+1:8: +1:14 ++ let mut _4: &(i32, i32); // in scope 0 at $DIR/ref_deref_project.rs:+1:6: +1:17 bb0: { - StorageLive(_1); // scope 0 at $DIR/ref_deref_project.rs:5:5: 5:17 - StorageLive(_2); // scope 0 at $DIR/ref_deref_project.rs:5:6: 5:17 -- StorageLive(_3); // scope 0 at $DIR/ref_deref_project.rs:5:8: 5:14 -- _3 = (const 4_i32, const 5_i32); // scope 0 at $DIR/ref_deref_project.rs:5:8: 5:14 -- _2 = &(_3.1: i32); // scope 0 at $DIR/ref_deref_project.rs:5:6: 5:17 -+ _4 = const main::promoted[0]; // scope 0 at $DIR/ref_deref_project.rs:5:6: 5:17 + StorageLive(_1); // scope 0 at $DIR/ref_deref_project.rs:+1:5: +1:17 + StorageLive(_2); // scope 0 at $DIR/ref_deref_project.rs:+1:6: +1:17 +- StorageLive(_3); // scope 0 at $DIR/ref_deref_project.rs:+1:8: +1:14 +- _3 = (const 4_i32, const 5_i32); // scope 0 at $DIR/ref_deref_project.rs:+1:8: +1:14 +- _2 = &(_3.1: i32); // scope 0 at $DIR/ref_deref_project.rs:+1:6: +1:17 ++ _4 = const main::promoted[0]; // scope 0 at $DIR/ref_deref_project.rs:+1:6: +1:17 + // mir::Constant -+ // + span: $DIR/ref_deref_project.rs:5:6: 5:17 ++ // + span: $DIR/ref_deref_project.rs:6:6: 6:17 + // + literal: Const { ty: &(i32, i32), val: Unevaluated(main, [], Some(promoted[0])) } -+ _2 = &((*_4).1: i32); // scope 0 at $DIR/ref_deref_project.rs:5:6: 5:17 - _1 = (*_2); // scope 0 at $DIR/ref_deref_project.rs:5:5: 5:17 -- StorageDead(_3); // scope 0 at $DIR/ref_deref_project.rs:5:17: 5:18 - StorageDead(_2); // scope 0 at $DIR/ref_deref_project.rs:5:17: 5:18 - StorageDead(_1); // scope 0 at $DIR/ref_deref_project.rs:5:17: 5:18 - _0 = const (); // scope 0 at $DIR/ref_deref_project.rs:4:11: 6:2 - return; // scope 0 at $DIR/ref_deref_project.rs:6:2: 6:2 ++ _2 = &((*_4).1: i32); // scope 0 at $DIR/ref_deref_project.rs:+1:6: +1:17 + _1 = (*_2); // scope 0 at $DIR/ref_deref_project.rs:+1:5: +1:17 +- StorageDead(_3); // scope 0 at $DIR/ref_deref_project.rs:+1:17: +1:18 + StorageDead(_2); // scope 0 at $DIR/ref_deref_project.rs:+1:17: +1:18 + StorageDead(_1); // scope 0 at $DIR/ref_deref_project.rs:+1:17: +1:18 + _0 = const (); // scope 0 at $DIR/ref_deref_project.rs:+0:11: +2:2 + return; // scope 0 at $DIR/ref_deref_project.rs:+2:2: +2:2 } }