mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-11 16:15:03 +00:00
21 lines
334 B
Rust
21 lines
334 B
Rust
//@ known-bug: rust-lang/rust#126416
|
|
|
|
trait Output<'a, T: 'a> {
|
|
type Type;
|
|
}
|
|
|
|
struct Wrapper;
|
|
|
|
impl Wrapper {
|
|
fn do_something_wrapper<O, F>(&mut self, _: F)
|
|
where
|
|
F: for<'a> FnOnce(<F as Output<i32>>::Type),
|
|
{
|
|
}
|
|
}
|
|
|
|
fn main() {
|
|
let mut wrapper = Wrapper;
|
|
wrapper.do_something_wrapper(|value| ());
|
|
}
|