]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-47380.stderr
Auto merge of #96711 - emilio:inline-slice-clone, r=nikic
[rust.git] / src / test / ui / issues / issue-47380.stderr
1 error[E0369]: cannot add `&str` to `&str`
2   --> $DIR/issue-47380.rs:3:35
3    |
4 LL |     println!("🦀🦀🦀🦀🦀"); let _a = b + ", World!";
5    |                                      - ^ ---------- &str
6    |                                      | |
7    |                                      | `+` cannot be used to concatenate two `&str` strings
8    |                                      &str
9    |
10    = note: string concatenation requires an owned `String` on the left
11 help: create an owned `String` from a string reference
12    |
13 LL |     println!("🦀🦀🦀🦀🦀"); let _a = b.to_owned() + ", World!";
14    |                                       +++++++++++
15
16 error: aborting due to previous error
17
18 For more information about this error, try `rustc --explain E0369`.