fork/rust
git clone https://git.julia.blue/fork/rust
3bcad65fbf6
master
1#![feature(async_closure)] 2 3// edition:2021 4// run-rustfix 5 6fn foo<T>(_: Box<T>) {} 7fn bar<T>(_: impl Fn() -> Box<T>) {} 8 9fn main() { 10 foo(Box::new(())); //~ ERROR mismatched types 11 bar(|| Box::new(())); //~ ERROR mismatched types 12}