|
1 | | -error: this type has already been used as a bound predicate |
2 | | - --> $DIR/float_cmp.rs:12:5 |
3 | | - | |
4 | | -LL | T: Copy, |
5 | | - | ^^^^^^^ |
6 | | - | |
7 | | - = note: `-D clippy::type-repetition-in-bounds` implied by `-D warnings` |
8 | | - = help: consider combining the bounds: `T: Add<T, Output = T>, Copy` |
9 | | - |
10 | 1 | error: strict comparison of f32 or f64 |
11 | | - --> $DIR/float_cmp.rs:60:5 |
| 2 | + --> $DIR/float_cmp.rs:59:5 |
12 | 3 | | |
13 | 4 | LL | ONE as f64 != 2.0; |
14 | 5 | | ^^^^^^^^^^^^^^^^^ help: consider comparing them within some error: `(ONE as f64 - 2.0).abs() > error` |
15 | 6 | | |
16 | 7 | = note: `-D clippy::float-cmp` implied by `-D warnings` |
17 | 8 | note: std::f32::EPSILON and std::f64::EPSILON are available. |
18 | | - --> $DIR/float_cmp.rs:60:5 |
| 9 | + --> $DIR/float_cmp.rs:59:5 |
19 | 10 | | |
20 | 11 | LL | ONE as f64 != 2.0; |
21 | 12 | | ^^^^^^^^^^^^^^^^^ |
22 | 13 |
|
23 | 14 | error: strict comparison of f32 or f64 |
24 | | - --> $DIR/float_cmp.rs:65:5 |
| 15 | + --> $DIR/float_cmp.rs:64:5 |
25 | 16 | | |
26 | 17 | LL | x == 1.0; |
27 | 18 | | ^^^^^^^^ help: consider comparing them within some error: `(x - 1.0).abs() < error` |
28 | 19 | | |
29 | 20 | note: std::f32::EPSILON and std::f64::EPSILON are available. |
30 | | - --> $DIR/float_cmp.rs:65:5 |
| 21 | + --> $DIR/float_cmp.rs:64:5 |
31 | 22 | | |
32 | 23 | LL | x == 1.0; |
33 | 24 | | ^^^^^^^^ |
34 | 25 |
|
35 | 26 | error: strict comparison of f32 or f64 |
36 | | - --> $DIR/float_cmp.rs:68:5 |
| 27 | + --> $DIR/float_cmp.rs:67:5 |
37 | 28 | | |
38 | 29 | LL | twice(x) != twice(ONE as f64); |
39 | 30 | | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider comparing them within some error: `(twice(x) - twice(ONE as f64)).abs() > error` |
40 | 31 | | |
41 | 32 | note: std::f32::EPSILON and std::f64::EPSILON are available. |
42 | | - --> $DIR/float_cmp.rs:68:5 |
| 33 | + --> $DIR/float_cmp.rs:67:5 |
43 | 34 | | |
44 | 35 | LL | twice(x) != twice(ONE as f64); |
45 | 36 | | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
46 | 37 |
|
47 | | -error: aborting due to 4 previous errors |
| 38 | +error: aborting due to 3 previous errors |
48 | 39 |
|
0 commit comments