about summary refs log tree commit diff
path: root/tests/crashes/125841.rs
blob: e2e61071f1df99d719ca7e08893923363c1f69cb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
//@ known-bug: rust-lang/rust#125841
#![feature(non_lifetime_binders)]
fn take(id: impl for<T> Fn(T) -> T) {
    id(0);
    id("");
}

fn take2() -> impl for<T> Fn(T) -> T {
    |x| x
}

fn main() {
    take(|x| take2)
}