rust/tests/ui/erasing_op.stderr
Yury Krivopalov 033c99b1ba Add erasing_op lint
For expressions that can be replaced by a zero.
2017-10-14 12:34:37 +03:00

21 lines
446 B
Plaintext

error: the operation is ineffective. Consider reducing it to `0`
--> $DIR/erasing_op.rs:9:5
|
9 | x * 0;
| ^^^^^
|
= note: `-D erasing-op` implied by `-D warnings`
error: the operation is ineffective. Consider reducing it to `0`
--> $DIR/erasing_op.rs:10:5
|
10 | 0 & x;
| ^^^^^
error: the operation is ineffective. Consider reducing it to `0`
--> $DIR/erasing_op.rs:11:5
|
11 | 0 / x;
| ^^^^^