]> git.lizzy.rs Git - rust.git/blob - tests/ui/block-result/issue-22645.stderr
Merge commit '598f0909568a51de8a2d1148f55a644fd8dffad0' into sync_cg_clif-2023-01-24
[rust.git] / tests / ui / block-result / issue-22645.stderr
1 error[E0277]: the trait bound `{integer}: Scalar` is not satisfied
2   --> $DIR/issue-22645.rs:15:5
3    |
4 LL |   b + 3
5    |     ^ the trait `Scalar` is not implemented for `{integer}`
6    |
7    = help: the trait `Scalar` is implemented for `f64`
8 note: required for `Bob` to implement `Add<{integer}>`
9   --> $DIR/issue-22645.rs:8:19
10    |
11 LL | impl<RHS: Scalar> Add <RHS> for Bob {
12    |           ------  ^^^^^^^^^     ^^^
13    |           |
14    |           unsatisfied trait bound introduced here
15
16 error[E0308]: mismatched types
17   --> $DIR/issue-22645.rs:15:3
18    |
19 LL | fn main() {
20    |           - expected `()` because of default return type
21 LL |   let b = Bob + 3.5;
22 LL |   b + 3
23    |   ^^^^^ expected `()`, found struct `Bob`
24
25 error: aborting due to 2 previous errors
26
27 Some errors have detailed explanations: E0277, E0308.
28 For more information about an error, try `rustc --explain E0277`.