about summary refs log tree commit diff
path: root/tests/ui/type-alias/dummy-binder-102964.rs
blob: 6b6fa3ed5e33d2799972c965e7d7028228ca4c1f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
//! Regression test for https://github.com/rust-lang/rust/issues/102964

use std::rc::Rc;
type Foo<'a, T> = &'a dyn Fn(&T);
type RcFoo<'a, T> = Rc<Foo<'a, T>>;

fn bar_function<T>(function: Foo<T>) -> RcFoo<T> {
    //~^ ERROR mismatched types
    let rc = Rc::new(function);
}

fn main() {}