@@ -10,44 +10,50 @@ LL | let _ = a.count_ones() == 1;
1010error: manually reimplementing `is_power_of_two`
1111 --> tests/ui/manual_is_power_of_two.rs:21:13
1212 |
13+ LL | let _ = u64::count_ones(a) == 1;
14+ | ^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.is_power_of_two()`: `a.is_power_of_two()`
15+
16+ error: manually reimplementing `is_power_of_two`
17+ --> tests/ui/manual_is_power_of_two.rs:23:13
18+ |
1319LL | let _ = a & (a - 1) == 0;
1420 | ^^^^^^^^^^^^^^^^ help: consider using `.is_power_of_two()`: `a.is_power_of_two()`
1521
1622error: manually reimplementing `is_power_of_two`
17- --> tests/ui/manual_is_power_of_two.rs:25 :13
23+ --> tests/ui/manual_is_power_of_two.rs:27 :13
1824 |
1925LL | let _ = 1 == a.count_ones();
2026 | ^^^^^^^^^^^^^^^^^^^ help: consider using `.is_power_of_two()`: `a.is_power_of_two()`
2127
2228error: manually reimplementing `is_power_of_two`
23- --> tests/ui/manual_is_power_of_two.rs:27 :13
29+ --> tests/ui/manual_is_power_of_two.rs:29 :13
2430 |
2531LL | let _ = (a - 1) & a == 0;
2632 | ^^^^^^^^^^^^^^^^ help: consider using `.is_power_of_two()`: `a.is_power_of_two()`
2733
2834error: manually reimplementing `is_power_of_two`
29- --> tests/ui/manual_is_power_of_two.rs:29 :13
35+ --> tests/ui/manual_is_power_of_two.rs:31 :13
3036 |
3137LL | let _ = 0 == a & (a - 1);
3238 | ^^^^^^^^^^^^^^^^ help: consider using `.is_power_of_two()`: `a.is_power_of_two()`
3339
3440error: manually reimplementing `is_power_of_two`
35- --> tests/ui/manual_is_power_of_two.rs:31 :13
41+ --> tests/ui/manual_is_power_of_two.rs:33 :13
3642 |
3743LL | let _ = 0 == (a - 1) & a;
3844 | ^^^^^^^^^^^^^^^^ help: consider using `.is_power_of_two()`: `a.is_power_of_two()`
3945
4046error: manually reimplementing `is_power_of_two`
41- --> tests/ui/manual_is_power_of_two.rs:41 :13
47+ --> tests/ui/manual_is_power_of_two.rs:43 :13
4248 |
4349LL | let _ = i as u32 & (i as u32 - 1) == 0;
4450 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.is_power_of_two()`: `(i as u32).is_power_of_two()`
4551
4652error: manually reimplementing `is_power_of_two`
47- --> tests/ui/manual_is_power_of_two.rs:56 :5
53+ --> tests/ui/manual_is_power_of_two.rs:58 :5
4854 |
4955LL | a & (a - 1) == 0
5056 | ^^^^^^^^^^^^^^^^ help: consider using `.is_power_of_two()`: `a.is_power_of_two()`
5157
52- error: aborting due to 8 previous errors
58+ error: aborting due to 9 previous errors
5359
0 commit comments