]> git.proxmox.com Git - rustc.git/blame - src/test/ui/inference/cannot-infer-partial-try-return.stderr
New upstream version 1.52.0~beta.3+dfsg1
[rustc.git] / src / test / ui / inference / cannot-infer-partial-try-return.stderr
CommitLineData
6a06907d 1error[E0282]: type annotations needed for the closure `fn() -> Result<(), QualifiedError<_>>`
5869c6ff
XL
2 --> $DIR/cannot-infer-partial-try-return.rs:19:9
3 |
4LL | infallible()?;
5 | ^^^^^^^^^^^^^ cannot infer type of error for `?` operator
6 |
7 = note: `?` implicitly converts the error value into `QualifiedError<_>` using its implementation of `From<Infallible>`
8help: give this closure an explicit return type without `_` placeholders
9 |
6a06907d
XL
10LL | let x = || -> Result<(), QualifiedError<_>> {
11 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
5869c6ff
XL
12
13error: aborting due to previous error
14
15For more information about this error, try `rustc --explain E0282`.