rust-clippy/clippy_tests/examples/arithmetic.stderr

94 lines
2 KiB
Text

error: integer arithmetic detected
--> arithmetic.rs:8:5
|
8 | 1 + i;
| ^^^^^
|
= note: `-D integer-arithmetic` implied by `-D warnings`
error: integer arithmetic detected
--> arithmetic.rs:9:5
|
9 | i * 2;
| ^^^^^
|
= note: `-D integer-arithmetic` implied by `-D warnings`
error: integer arithmetic detected
--> arithmetic.rs:10:5
|
10 | / 1 %
11 | | i / 2; // no error, this is part of the expression in the preceding line
| |_________^
|
= note: `-D integer-arithmetic` implied by `-D warnings`
error: integer arithmetic detected
--> arithmetic.rs:12:5
|
12 | i - 2 + 2 - i;
| ^^^^^^^^^^^^^
|
= note: `-D integer-arithmetic` implied by `-D warnings`
error: integer arithmetic detected
--> arithmetic.rs:13:5
|
13 | -i;
| ^^
|
= note: `-D integer-arithmetic` implied by `-D warnings`
error: floating-point arithmetic detected
--> arithmetic.rs:23:5
|
23 | f * 2.0;
| ^^^^^^^
|
= note: `-D float-arithmetic` implied by `-D warnings`
error: floating-point arithmetic detected
--> arithmetic.rs:25:5
|
25 | 1.0 + f;
| ^^^^^^^
|
= note: `-D float-arithmetic` implied by `-D warnings`
error: floating-point arithmetic detected
--> arithmetic.rs:26:5
|
26 | f * 2.0;
| ^^^^^^^
|
= note: `-D float-arithmetic` implied by `-D warnings`
error: floating-point arithmetic detected
--> arithmetic.rs:27:5
|
27 | f / 2.0;
| ^^^^^^^
|
= note: `-D float-arithmetic` implied by `-D warnings`
error: floating-point arithmetic detected
--> arithmetic.rs:28:5
|
28 | f - 2.0 * 4.2;
| ^^^^^^^^^^^^^
|
= note: `-D float-arithmetic` implied by `-D warnings`
error: floating-point arithmetic detected
--> arithmetic.rs:29:5
|
29 | -f;
| ^^
|
= note: `-D float-arithmetic` implied by `-D warnings`
error: aborting due to 11 previous errors
error: Could not compile `clippy_tests`.
To learn more, run the command again with --verbose.