2017-06-11 02:34:47 +00:00
|
|
|
error: manual implementation of an assign operation
|
2017-08-01 15:54:21 +00:00
|
|
|
--> $DIR/strings.rs:10:9
|
2017-06-11 02:34:47 +00:00
|
|
|
|
|
|
|
|
10 | x = x + ".";
|
2017-07-21 08:40:23 +00:00
|
|
|
| ^^^^^^^^^^^ help: replace it with: `x += "."`
|
2017-06-11 02:34:47 +00:00
|
|
|
|
|
|
|
|
= note: `-D assign-op-pattern` implied by `-D warnings`
|
|
|
|
|
2017-02-07 20:05:30 +00:00
|
|
|
error: you added something to a string. Consider using `String::push_str()` instead
|
2017-08-01 15:54:21 +00:00
|
|
|
--> $DIR/strings.rs:10:13
|
2017-02-07 20:05:30 +00:00
|
|
|
|
|
2017-02-08 13:58:07 +00:00
|
|
|
10 | x = x + ".";
|
2017-02-07 20:05:30 +00:00
|
|
|
| ^^^^^^^
|
|
|
|
|
|
2017-05-17 12:19:44 +00:00
|
|
|
= note: `-D string-add` implied by `-D warnings`
|
2017-02-07 20:05:30 +00:00
|
|
|
|
|
|
|
error: you added something to a string. Consider using `String::push_str()` instead
|
2017-08-01 15:54:21 +00:00
|
|
|
--> $DIR/strings.rs:14:13
|
2017-02-07 20:05:30 +00:00
|
|
|
|
|
2017-02-08 13:58:07 +00:00
|
|
|
14 | let z = y + "...";
|
2017-02-07 20:05:30 +00:00
|
|
|
| ^^^^^^^^^
|
|
|
|
|
|
|
|
error: you assigned the result of adding something to this string. Consider using `String::push_str()` instead
|
2017-08-01 15:54:21 +00:00
|
|
|
--> $DIR/strings.rs:24:9
|
2017-02-07 20:05:30 +00:00
|
|
|
|
|
2017-02-08 13:58:07 +00:00
|
|
|
24 | x = x + ".";
|
2017-02-07 20:05:30 +00:00
|
|
|
| ^^^^^^^^^^^
|
|
|
|
|
|
2017-05-17 12:19:44 +00:00
|
|
|
= note: `-D string-add-assign` implied by `-D warnings`
|
2017-02-07 20:05:30 +00:00
|
|
|
|
2017-06-11 02:34:47 +00:00
|
|
|
error: manual implementation of an assign operation
|
2017-08-01 15:54:21 +00:00
|
|
|
--> $DIR/strings.rs:24:9
|
2017-06-11 02:34:47 +00:00
|
|
|
|
|
|
|
|
24 | x = x + ".";
|
2017-07-21 08:40:23 +00:00
|
|
|
| ^^^^^^^^^^^ help: replace it with: `x += "."`
|
2017-06-11 02:34:47 +00:00
|
|
|
|
2017-02-07 20:05:30 +00:00
|
|
|
error: you assigned the result of adding something to this string. Consider using `String::push_str()` instead
|
2017-08-01 15:54:21 +00:00
|
|
|
--> $DIR/strings.rs:38:9
|
2017-02-07 20:05:30 +00:00
|
|
|
|
|
2017-02-08 13:58:07 +00:00
|
|
|
38 | x = x + ".";
|
2017-02-07 20:05:30 +00:00
|
|
|
| ^^^^^^^^^^^
|
|
|
|
|
2017-06-11 02:34:47 +00:00
|
|
|
error: manual implementation of an assign operation
|
2017-08-01 15:54:21 +00:00
|
|
|
--> $DIR/strings.rs:38:9
|
2017-06-11 02:34:47 +00:00
|
|
|
|
|
|
|
|
38 | x = x + ".";
|
2017-07-21 08:40:23 +00:00
|
|
|
| ^^^^^^^^^^^ help: replace it with: `x += "."`
|
2017-06-11 02:34:47 +00:00
|
|
|
|
2017-02-07 20:05:30 +00:00
|
|
|
error: you added something to a string. Consider using `String::push_str()` instead
|
2017-08-01 15:54:21 +00:00
|
|
|
--> $DIR/strings.rs:42:13
|
2017-02-07 20:05:30 +00:00
|
|
|
|
|
2017-02-08 13:58:07 +00:00
|
|
|
42 | let z = y + "...";
|
2017-02-07 20:05:30 +00:00
|
|
|
| ^^^^^^^^^
|
|
|
|
|
|
|
|
error: calling `as_bytes()` on a string literal
|
2017-08-01 15:54:21 +00:00
|
|
|
--> $DIR/strings.rs:50:14
|
2017-02-07 20:05:30 +00:00
|
|
|
|
|
|
|
|
50 | let bs = "hello there".as_bytes();
|
2017-07-21 08:40:23 +00:00
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using a byte string literal instead: `b"hello there"`
|
2017-02-07 20:05:30 +00:00
|
|
|
|
|
2017-05-17 12:19:44 +00:00
|
|
|
= note: `-D string-lit-as-bytes` implied by `-D warnings`
|
2017-02-07 20:05:30 +00:00
|
|
|
|
2017-07-21 08:40:23 +00:00
|
|
|
error: calling `as_bytes()` on a string literal
|
2017-08-01 15:54:21 +00:00
|
|
|
--> $DIR/strings.rs:55:18
|
2017-07-21 08:40:23 +00:00
|
|
|
|
|
|
|
|
55 | let strify = stringify!(foobar).as_bytes();
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using a byte string literal instead: `bstringify!(foobar)`
|
|
|
|
|
2017-05-17 12:19:44 +00:00
|
|
|
error: manual implementation of an assign operation
|
2017-08-01 15:54:21 +00:00
|
|
|
--> $DIR/strings.rs:65:7
|
2017-02-07 20:05:30 +00:00
|
|
|
|
|
2017-05-11 14:47:31 +00:00
|
|
|
65 | ; x = x + 1;
|
2017-07-21 08:40:23 +00:00
|
|
|
| ^^^^^^^^^ help: replace it with: `x += 1`
|
2017-05-17 12:19:44 +00:00
|
|
|
|
2018-01-16 16:06:27 +00:00
|
|
|
error: aborting due to 11 previous errors
|
|
|
|
|