diff options
| author | Eduard-Mihai Burtescu <edy.burt@gmail.com> | 2020-02-09 03:38:22 +0200 |
|---|---|---|
| committer | Eduard-Mihai Burtescu <edy.burt@gmail.com> | 2020-10-21 04:43:56 +0300 |
| commit | 2bfb462b58db63aaa0a43bacde39687928fe901e (patch) | |
| tree | 6a68d1a861181f383233fb4e44b0a7677fd26b04 /src/test/mir-opt/inline | |
| parent | 387e31c9a7e6f7df3da513e2241a03e0b738ea4d (diff) | |
| download | rust-2bfb462b58db63aaa0a43bacde39687928fe901e.tar.gz rust-2bfb462b58db63aaa0a43bacde39687928fe901e.zip | |
rustc_mir: don't throw away inlined locals' spans.
Diffstat (limited to 'src/test/mir-opt/inline')
8 files changed, 11 insertions, 11 deletions
diff --git a/src/test/mir-opt/inline/inline_any_operand.bar.Inline.after.mir b/src/test/mir-opt/inline/inline_any_operand.bar.Inline.after.mir index 1ced3fe5d15..2d97f4e6d6f 100644 --- a/src/test/mir-opt/inline/inline_any_operand.bar.Inline.after.mir +++ b/src/test/mir-opt/inline/inline_any_operand.bar.Inline.after.mir @@ -11,8 +11,8 @@ fn bar() -> bool { scope 2 (inlined foo) { // at $DIR/inline-any-operand.rs:12:5: 12:13 debug x => _5; // in scope 2 at $DIR/inline-any-operand.rs:16:8: 16:9 debug y => _6; // in scope 2 at $DIR/inline-any-operand.rs:16:16: 16:17 - let mut _3: i32; // in scope 2 at $DIR/inline-any-operand.rs:12:5: 12:13 - let mut _4: i32; // in scope 2 at $DIR/inline-any-operand.rs:12:5: 12:13 + let mut _3: i32; // in scope 2 at $DIR/inline-any-operand.rs:17:5: 17:6 + let mut _4: i32; // in scope 2 at $DIR/inline-any-operand.rs:17:10: 17:11 } } diff --git a/src/test/mir-opt/inline/inline_closure_borrows_arg.foo.Inline.after.mir b/src/test/mir-opt/inline/inline_closure_borrows_arg.foo.Inline.after.mir index cb2cd785b48..92399ebaf9d 100644 --- a/src/test/mir-opt/inline/inline_closure_borrows_arg.foo.Inline.after.mir +++ b/src/test/mir-opt/inline/inline_closure_borrows_arg.foo.Inline.after.mir @@ -16,7 +16,7 @@ fn foo(_1: T, _2: &i32) -> i32 { scope 2 (inlined foo::<T>::{closure#0}) { // at $DIR/inline-closure-borrows-arg.rs:16:5: 16:12 debug r => _9; // in scope 2 at $DIR/inline-closure-borrows-arg.rs:12:14: 12:15 debug _s => _10; // in scope 2 at $DIR/inline-closure-borrows-arg.rs:12:23: 12:25 - let _8: &i32; // in scope 2 at $DIR/inline-closure-borrows-arg.rs:16:5: 16:12 + let _8: &i32; // in scope 2 at $DIR/inline-closure-borrows-arg.rs:13:13: 13:21 scope 3 { debug variable => _8; // in scope 3 at $DIR/inline-closure-borrows-arg.rs:13:13: 13:21 } diff --git a/src/test/mir-opt/inline/inline_closure_captures.foo.Inline.after.mir b/src/test/mir-opt/inline/inline_closure_captures.foo.Inline.after.mir index c6d1e8147a3..ffdc7f3ffe6 100644 --- a/src/test/mir-opt/inline/inline_closure_captures.foo.Inline.after.mir +++ b/src/test/mir-opt/inline/inline_closure_captures.foo.Inline.after.mir @@ -17,7 +17,7 @@ fn foo(_1: T, _2: i32) -> (i32, T) { debug _q => _10; // in scope 2 at $DIR/inline-closure-captures.rs:11:14: 11:16 debug q => (*((*_6).0: &i32)); // in scope 2 at $DIR/inline-closure-captures.rs:10:23: 10:24 debug t => (*((*_6).1: &T)); // in scope 2 at $DIR/inline-closure-captures.rs:10:17: 10:18 - let mut _9: T; // in scope 2 at $DIR/inline-closure-captures.rs:12:5: 12:9 + let mut _9: T; // in scope 2 at $DIR/inline-closure-captures.rs:11:22: 11:23 } } diff --git a/src/test/mir-opt/inline/inline_retag.bar.Inline.after.mir b/src/test/mir-opt/inline/inline_retag.bar.Inline.after.mir index cdcfeec98f9..0cace4e32c4 100644 --- a/src/test/mir-opt/inline/inline_retag.bar.Inline.after.mir +++ b/src/test/mir-opt/inline/inline_retag.bar.Inline.after.mir @@ -17,8 +17,8 @@ fn bar() -> bool { scope 2 (inlined foo) { // at $DIR/inline-retag.rs:12:5: 12:15 debug x => _3; // in scope 2 at $DIR/inline-retag.rs:16:8: 16:9 debug y => _6; // in scope 2 at $DIR/inline-retag.rs:16:17: 16:18 - let mut _11: i32; // in scope 2 at $DIR/inline-retag.rs:12:5: 12:15 - let mut _12: i32; // in scope 2 at $DIR/inline-retag.rs:12:5: 12:15 + let mut _11: i32; // in scope 2 at $DIR/inline-retag.rs:17:5: 17:7 + let mut _12: i32; // in scope 2 at $DIR/inline-retag.rs:17:11: 17:13 } } diff --git a/src/test/mir-opt/inline/inline_trait_method_2.test2.Inline.after.mir b/src/test/mir-opt/inline/inline_trait_method_2.test2.Inline.after.mir index 8c7eb753cc0..907a56d6a0e 100644 --- a/src/test/mir-opt/inline/inline_trait_method_2.test2.Inline.after.mir +++ b/src/test/mir-opt/inline/inline_trait_method_2.test2.Inline.after.mir @@ -7,7 +7,7 @@ fn test2(_1: &dyn X) -> bool { let mut _3: &dyn X; // in scope 0 at $DIR/inline-trait-method_2.rs:5:10: 5:11 scope 1 (inlined test) { // at $DIR/inline-trait-method_2.rs:5:5: 5:12 debug x => _2; // in scope 1 at $DIR/inline-trait-method_2.rs:9:9: 9:10 - let mut _4: &dyn X; // in scope 1 at $DIR/inline-trait-method_2.rs:5:5: 5:12 + let mut _4: &dyn X; // in scope 1 at $DIR/inline-trait-method_2.rs:10:5: 10:6 } bb0: { diff --git a/src/test/mir-opt/inline/issue_58867_inline_as_ref_as_mut.a.Inline.after.mir b/src/test/mir-opt/inline/issue_58867_inline_as_ref_as_mut.a.Inline.after.mir index e91b79b8db5..08f0dac2e9d 100644 --- a/src/test/mir-opt/inline/issue_58867_inline_as_ref_as_mut.a.Inline.after.mir +++ b/src/test/mir-opt/inline/issue_58867_inline_as_ref_as_mut.a.Inline.after.mir @@ -8,7 +8,7 @@ fn a(_1: &mut [T]) -> &mut [T] { let mut _4: &mut [T]; // in scope 0 at $DIR/issue-58867-inline-as-ref-as-mut.rs:3:5: 3:6 scope 1 (inlined <[T] as AsMut<[T]>>::as_mut) { // at $DIR/issue-58867-inline-as-ref-as-mut.rs:3:5: 3:15 debug self => _4; // in scope 1 at $SRC_DIR/core/src/convert/mod.rs:LL:COL - let mut _5: &mut [T]; // in scope 1 at $DIR/issue-58867-inline-as-ref-as-mut.rs:3:5: 3:15 + let mut _5: &mut [T]; // in scope 1 at $SRC_DIR/core/src/convert/mod.rs:LL:COL } bb0: { diff --git a/src/test/mir-opt/inline/issue_58867_inline_as_ref_as_mut.b.Inline.after.mir b/src/test/mir-opt/inline/issue_58867_inline_as_ref_as_mut.b.Inline.after.mir index 9378489faba..af97434f629 100644 --- a/src/test/mir-opt/inline/issue_58867_inline_as_ref_as_mut.b.Inline.after.mir +++ b/src/test/mir-opt/inline/issue_58867_inline_as_ref_as_mut.b.Inline.after.mir @@ -8,8 +8,8 @@ fn b(_1: &mut Box<T>) -> &mut T { let mut _4: &mut std::boxed::Box<T>; // in scope 0 at $DIR/issue-58867-inline-as-ref-as-mut.rs:8:5: 8:6 scope 1 (inlined <Box<T> as AsMut<T>>::as_mut) { // at $DIR/issue-58867-inline-as-ref-as-mut.rs:8:5: 8:15 debug self => _4; // in scope 1 at $SRC_DIR/alloc/src/boxed.rs:LL:COL - let mut _5: &mut T; // in scope 1 at $DIR/issue-58867-inline-as-ref-as-mut.rs:8:5: 8:15 - let mut _6: &mut T; // in scope 1 at $DIR/issue-58867-inline-as-ref-as-mut.rs:8:5: 8:15 + let mut _5: &mut T; // in scope 1 at $SRC_DIR/alloc/src/boxed.rs:LL:COL + let mut _6: &mut T; // in scope 1 at $SRC_DIR/alloc/src/boxed.rs:LL:COL } bb0: { diff --git a/src/test/mir-opt/inline/issue_76997_inline_scopes_parenting.main.Inline.after.mir b/src/test/mir-opt/inline/issue_76997_inline_scopes_parenting.main.Inline.after.mir index 9d1e8aca408..cdd27ff1036 100644 --- a/src/test/mir-opt/inline/issue_76997_inline_scopes_parenting.main.Inline.after.mir +++ b/src/test/mir-opt/inline/issue_76997_inline_scopes_parenting.main.Inline.after.mir @@ -11,7 +11,7 @@ fn main() -> () { debug f => _1; // in scope 1 at $DIR/issue-76997-inline-scopes-parenting.rs:5:9: 5:10 scope 2 (inlined main::{closure#0}) { // at $DIR/issue-76997-inline-scopes-parenting.rs:6:5: 6:10 debug x => _6; // in scope 2 at $DIR/issue-76997-inline-scopes-parenting.rs:5:14: 5:15 - let _5: (); // in scope 2 at $DIR/issue-76997-inline-scopes-parenting.rs:6:5: 6:10 + let _5: (); // in scope 2 at $DIR/issue-76997-inline-scopes-parenting.rs:5:23: 5:24 scope 3 { debug y => _5; // in scope 3 at $DIR/issue-76997-inline-scopes-parenting.rs:5:23: 5:24 } |
