diff options
| author | Albert Larsan <74931857+albertlarsan68@users.noreply.github.com> | 2023-01-05 09:13:28 +0100 |
|---|---|---|
| committer | Albert Larsan <74931857+albertlarsan68@users.noreply.github.com> | 2023-01-11 09:32:08 +0000 |
| commit | cf2dff2b1e3fa55fa5415d524200070d0d7aacfe (patch) | |
| tree | 40a88d9a46aaf3e8870676eb2538378b75a263eb /tests/mir-opt/const_prop_miscompile.foo.ConstProp.diff | |
| parent | ca855e6e42787ecd062d81d53336fe6788ef51a9 (diff) | |
| download | rust-cf2dff2b1e3fa55fa5415d524200070d0d7aacfe.tar.gz rust-cf2dff2b1e3fa55fa5415d524200070d0d7aacfe.zip | |
Move /src/test to /tests
Diffstat (limited to 'tests/mir-opt/const_prop_miscompile.foo.ConstProp.diff')
| -rw-r--r-- | tests/mir-opt/const_prop_miscompile.foo.ConstProp.diff | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/tests/mir-opt/const_prop_miscompile.foo.ConstProp.diff b/tests/mir-opt/const_prop_miscompile.foo.ConstProp.diff new file mode 100644 index 00000000000..043f4047417 --- /dev/null +++ b/tests/mir-opt/const_prop_miscompile.foo.ConstProp.diff @@ -0,0 +1,35 @@ +- // MIR for `foo` before ConstProp ++ // MIR for `foo` after ConstProp + + fn foo() -> () { + let mut _0: (); // return place in scope 0 at $DIR/const_prop_miscompile.rs:+0:10: +0:10 + let mut _1: (i32,); // in scope 0 at $DIR/const_prop_miscompile.rs:+1:9: +1:14 + let mut _2: &mut i32; // in scope 0 at $DIR/const_prop_miscompile.rs:+2:6: +2:14 + let mut _4: i32; // in scope 0 at $DIR/const_prop_miscompile.rs:+3:13: +3:20 + scope 1 { + debug u => _1; // in scope 1 at $DIR/const_prop_miscompile.rs:+1:9: +1:14 + let _3: bool; // in scope 1 at $DIR/const_prop_miscompile.rs:+3:9: +3:10 + scope 2 { + debug y => _3; // in scope 2 at $DIR/const_prop_miscompile.rs:+3:9: +3:10 + } + } + + bb0: { + StorageLive(_1); // scope 0 at $DIR/const_prop_miscompile.rs:+1:9: +1:14 + Deinit(_1); // scope 0 at $DIR/const_prop_miscompile.rs:+1:17: +1:21 + (_1.0: i32) = const 1_i32; // scope 0 at $DIR/const_prop_miscompile.rs:+1:17: +1:21 + StorageLive(_2); // scope 1 at $DIR/const_prop_miscompile.rs:+2:6: +2:14 + _2 = &mut (_1.0: i32); // scope 1 at $DIR/const_prop_miscompile.rs:+2:6: +2:14 + (*_2) = const 5_i32; // scope 1 at $DIR/const_prop_miscompile.rs:+2:5: +2:18 + StorageDead(_2); // scope 1 at $DIR/const_prop_miscompile.rs:+2:18: +2:19 + StorageLive(_3); // scope 1 at $DIR/const_prop_miscompile.rs:+3:9: +3:10 + StorageLive(_4); // scope 1 at $DIR/const_prop_miscompile.rs:+3:13: +3:20 + _4 = (_1.0: i32); // scope 1 at $DIR/const_prop_miscompile.rs:+3:15: +3:18 + _3 = Eq(move _4, const 5_i32); // scope 1 at $DIR/const_prop_miscompile.rs:+3:13: +3:25 + StorageDead(_4); // scope 1 at $DIR/const_prop_miscompile.rs:+3:24: +3:25 + StorageDead(_3); // scope 1 at $DIR/const_prop_miscompile.rs:+4:1: +4:2 + StorageDead(_1); // scope 0 at $DIR/const_prop_miscompile.rs:+4:1: +4:2 + return; // scope 0 at $DIR/const_prop_miscompile.rs:+4:2: +4:2 + } + } + |
