Closed
Description
This code compiles after #95565 although it shouldn't: (playground)
fn assert_static<T>() where for<'a> T: 'a, {}
fn test<T>() {
|| {
assert_static::<T>();
};
}
This is similar to #98095 in that we're not taking into account placeholder regions when "promoting" type-tests from the closure to its caller:
@rustbot label T-types regression-from-stable-to-beta C-bug A-NLL I-unsound