error: the type `&dyn Fn(i32) -> _` is not well-formed (chalk) --> $DIR/trait-objects.rs:11:12 | LL | let f: &dyn Fn(i32) -> _ = &|x| x + x; | ^^^^^^^^^^^^^^^^^ error[E0277]: `(i32,)` is not a tuple --> $DIR/trait-objects.rs:12:5 | LL | f(2); | ^^^^ the trait `Tuple` is not implemented for `(i32,)` | help: consider introducing a `where` clause, but there might be an alternative better way to express this requirement | LL | fn main() where (i32,): Tuple { | +++++++++++++++++++ error[E0277]: expected a `Fn<(i32,)>` closure, found `dyn Fn(i32) -> i32` --> $DIR/trait-objects.rs:12:5 | LL | f(2); | ^^^^ expected an `Fn<(i32,)>` closure, found `dyn Fn(i32) -> i32` | = help: the trait `Fn<(i32,)>` is not implemented for `dyn Fn(i32) -> i32` error: aborting due to 3 previous errors For more information about this error, try `rustc --explain E0277`.