blob: cb7b6b48843a5a8219e4e8523fc3e5afaaa1d034 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
error: `to_string()` called on a `&str`
--> tests/ui/str_to_string.rs:4:17
|
LL | let hello = "hello world".to_string();
| ^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `"hello world".to_owned()`
|
= note: `-D clippy::str-to-string` implied by `-D warnings`
= help: to override `-D warnings` add `#[allow(clippy::str_to_string)]`
error: `to_string()` called on a `&str`
--> tests/ui/str_to_string.rs:8:5
|
LL | msg.to_string();
| ^^^^^^^^^^^^^^^ help: try: `msg.to_owned()`
error: aborting due to 2 previous errors
|