FileCheck inline_closure_borrows_arg

This commit is contained in:
Ryan Mehri 2023-10-20 11:28:38 -07:00
parent de56d2d9b2
commit 9d61e6a4e4

View file

@ -1,4 +1,3 @@
// skip-filecheck
// compile-flags: -Z span_free_formats -Zunsound-mir-opts
// Tests that MIR inliner can handle closure arguments,
@ -14,5 +13,8 @@ fn foo<T: Copy>(_t: T, q: &i32) -> i32 {
let variable = &*r;
*variable
};
// CHECK-LABEL: fn foo(
// CHECK: (inlined foo::<T>::{closure#0})
x(q, q)
}