]> git.lizzy.rs Git - rust.git/blob - src/test/ui/suggestions/issue-83943.stderr
Rollup merge of #90420 - GuillaumeGomez:rustdoc-internals-feature, r=camelid
[rust.git] / src / test / ui / suggestions / issue-83943.stderr
1 error[E0308]: `if` and `else` have incompatible types
2   --> $DIR/issue-83943.rs:7:9
3    |
4 LL | /     if true {
5 LL | |         "A".to_string()
6    | |         --------------- expected because of this
7 LL | |     } else {
8 LL | |         "B"
9    | |         ^^^- help: try using a conversion method: `.to_string()`
10    | |         |
11    | |         expected struct `String`, found `&str`
12 LL | |     };
13    | |_____- `if` and `else` have incompatible types
14
15 error: aborting due to previous error
16
17 For more information about this error, try `rustc --explain E0308`.