]> git.lizzy.rs Git - rust.git/blob - tests/ui/suggestions/issue-89333.rs
Rollup merge of #106670 - albertlarsan68:check-docs-in-pr-ci, r=Mark-Simulacrum
[rust.git] / tests / ui / suggestions / issue-89333.rs
1 // check-fail
2 // Ensure we don't error when emitting trait bound not satisfied when self type
3 // has late bound var
4
5 fn main() {
6     test(&|| 0); //~ ERROR the trait bound
7 }
8
9 trait Trait {}
10
11 fn test<T>(arg: &impl Fn() -> T) where for<'a> &'a T: Trait {}