1 error[E0282]: type annotations needed for the closure `fn((), ()) -> std::result::Result<(), _>`
2 --> $DIR/cannot-infer-closure.rs:3:9
5 | ^^^^^^^ cannot infer type
6 help: give this closure an explicit return type without `_` placeholders
8 LL | let x = |a: (), b: ()| -> std::result::Result<(), _> {
9 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
11 error: aborting due to previous error
13 For more information about this error, try `rustc --explain E0282`.