fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #66089 - Mark-Simulacrum:stable-next, r=Mark-Simulacrum4560ea788cb

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