]> git.proxmox.com Git - rustc.git/blame - src/tools/clippy/tests/ui/float_equality_without_abs.stderr
New upstream version 1.52.1+dfsg1
[rustc.git] / src / tools / clippy / tests / ui / float_equality_without_abs.stderr
CommitLineData
f20569fa
XL
1error: float equality check without `.abs()`
2 --> $DIR/float_equality_without_abs.rs:4:5
3 |
4LL | (a - b) < f32::EPSILON
5 | -------^^^^^^^^^^^^^^^
6 | |
7 | help: add `.abs()`: `(a - b).abs()`
8 |
9 = note: `-D clippy::float-equality-without-abs` implied by `-D warnings`
10
11error: float equality check without `.abs()`
12 --> $DIR/float_equality_without_abs.rs:13:13
13 |
14LL | let _ = (a - b) < f32::EPSILON;
15 | -------^^^^^^^^^^^^^^^
16 | |
17 | help: add `.abs()`: `(a - b).abs()`
18
19error: float equality check without `.abs()`
20 --> $DIR/float_equality_without_abs.rs:14:13
21 |
22LL | let _ = a - b < f32::EPSILON;
23 | -----^^^^^^^^^^^^^^^
24 | |
25 | help: add `.abs()`: `(a - b).abs()`
26
27error: float equality check without `.abs()`
28 --> $DIR/float_equality_without_abs.rs:15:13
29 |
30LL | let _ = a - b.abs() < f32::EPSILON;
31 | -----------^^^^^^^^^^^^^^^
32 | |
33 | help: add `.abs()`: `(a - b.abs()).abs()`
34
35error: float equality check without `.abs()`
36 --> $DIR/float_equality_without_abs.rs:16:13
37 |
38LL | let _ = (a as f64 - b as f64) < f64::EPSILON;
39 | ---------------------^^^^^^^^^^^^^^^
40 | |
41 | help: add `.abs()`: `(a as f64 - b as f64).abs()`
42
43error: float equality check without `.abs()`
44 --> $DIR/float_equality_without_abs.rs:17:13
45 |
46LL | let _ = 1.0 - 2.0 < f32::EPSILON;
47 | ---------^^^^^^^^^^^^^^^
48 | |
49 | help: add `.abs()`: `(1.0 - 2.0).abs()`
50
51error: float equality check without `.abs()`
52 --> $DIR/float_equality_without_abs.rs:19:13
53 |
54LL | let _ = f32::EPSILON > (a - b);
55 | ^^^^^^^^^^^^^^^-------
56 | |
57 | help: add `.abs()`: `(a - b).abs()`
58
59error: float equality check without `.abs()`
60 --> $DIR/float_equality_without_abs.rs:20:13
61 |
62LL | let _ = f32::EPSILON > a - b;
63 | ^^^^^^^^^^^^^^^-----
64 | |
65 | help: add `.abs()`: `(a - b).abs()`
66
67error: float equality check without `.abs()`
68 --> $DIR/float_equality_without_abs.rs:21:13
69 |
70LL | let _ = f32::EPSILON > a - b.abs();
71 | ^^^^^^^^^^^^^^^-----------
72 | |
73 | help: add `.abs()`: `(a - b.abs()).abs()`
74
75error: float equality check without `.abs()`
76 --> $DIR/float_equality_without_abs.rs:22:13
77 |
78LL | let _ = f64::EPSILON > (a as f64 - b as f64);
79 | ^^^^^^^^^^^^^^^---------------------
80 | |
81 | help: add `.abs()`: `(a as f64 - b as f64).abs()`
82
83error: float equality check without `.abs()`
84 --> $DIR/float_equality_without_abs.rs:23:13
85 |
86LL | let _ = f32::EPSILON > 1.0 - 2.0;
87 | ^^^^^^^^^^^^^^^---------
88 | |
89 | help: add `.abs()`: `(1.0 - 2.0).abs()`
90
91error: aborting due to 11 previous errors
92