Skip to content

Commit 3a0c6e9

Browse files
Rollup merge of #156578 - eval-exec:mir-opt-build-correct-coerce-filecheck, r=TaKO8Ki
Add FileCheck for build_correct_coerce part of #116971
2 parents 9283c8e + 61e801d commit 3a0c6e9

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
//@ skip-filecheck
2-
31
// Validate that we record the target for the `as` coercion as `for<'a> fn(&'a (), &'a ())`,
42
// and not `for<'a, 'b>(&'a (), &'b ())`. We previously did the latter due to a bug in
53
// the code that records adjustments in HIR typeck.
@@ -8,5 +6,8 @@ fn foo<'a, 'b>(_: &'a (), _: &'b ()) {}
86

97
// EMIT_MIR build_correct_coerce.main.built.after.mir
108
fn main() {
9+
// CHECK-LABEL: fn main(
10+
// CHECK: let _1: for<'a> fn(&'a (), &'a ());
11+
// CHECK: _1 = foo as for<'a> fn(&'a (), &'a ())
1112
let x = foo as for<'a> fn(&'a (), &'a ());
1213
}

0 commit comments

Comments
 (0)