1 error: useless use of `format!`
2 --> $DIR/format.rs:13:5
5 | ^^^^^^^^^^^^^^^ help: consider using .to_string(): `"foo".to_string();`
7 = note: `-D clippy::useless-format` implied by `-D warnings`
9 error: useless use of `format!`
10 --> $DIR/format.rs:14:5
13 | ^^^^^^^^^^^^^^^^ help: consider using .to_string(): `"{}".to_string();`
15 error: useless use of `format!`
16 --> $DIR/format.rs:15:5
18 LL | format!("{{}} abc {{}}");
19 | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using .to_string(): `"{} abc {}".to_string();`
21 error: useless use of `format!`
22 --> $DIR/format.rs:17:5
24 LL | format!("{}", "foo");
25 | ^^^^^^^^^^^^^^^^^^^^^ help: consider using .to_string(): `"foo".to_string();`
27 error: useless use of `format!`
28 --> $DIR/format.rs:21:5
30 LL | format!("{:+}", "foo"); // Warn when the format makes no difference.
31 | ^^^^^^^^^^^^^^^^^^^^^^^ help: consider using .to_string(): `"foo".to_string();`
33 error: useless use of `format!`
34 --> $DIR/format.rs:22:5
36 LL | format!("{:<}", "foo"); // Warn when the format makes no difference.
37 | ^^^^^^^^^^^^^^^^^^^^^^^ help: consider using .to_string(): `"foo".to_string();`
39 error: useless use of `format!`
40 --> $DIR/format.rs:27:5
42 LL | format!("{}", arg);
43 | ^^^^^^^^^^^^^^^^^^^ help: consider using .to_string(): `arg.to_string();`
45 error: useless use of `format!`
46 --> $DIR/format.rs:31:5
48 LL | format!("{:+}", arg); // Warn when the format makes no difference.
49 | ^^^^^^^^^^^^^^^^^^^^^ help: consider using .to_string(): `arg.to_string();`
51 error: useless use of `format!`
52 --> $DIR/format.rs:32:5
54 LL | format!("{:<}", arg); // Warn when the format makes no difference.
55 | ^^^^^^^^^^^^^^^^^^^^^ help: consider using .to_string(): `arg.to_string();`
57 error: useless use of `format!`
58 --> $DIR/format.rs:59:5
60 LL | format!("{}", 42.to_string());
61 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: `to_string()` is enough: `42.to_string();`
63 error: useless use of `format!`
64 --> $DIR/format.rs:61:5
66 LL | format!("{}", x.display().to_string());
67 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: `to_string()` is enough: `x.display().to_string();`
69 error: aborting due to 11 previous errors