1+ error: integer type suffix should not be separated by an underscore
2+ --> $DIR/literals.rs:12:15
3+ |
4+ LL | let ok4 = 0xab_cd_i32;
5+ | ^^^^^^^^^^^ help: remove the underscore: `0xab_cdi32`
6+ |
7+ = note: `-D clippy::separated-literal-suffix` implied by `-D warnings`
8+
9+ error: integer type suffix should not be separated by an underscore
10+ --> $DIR/literals.rs:13:15
11+ |
12+ LL | let ok5 = 0xAB_CD_u32;
13+ | ^^^^^^^^^^^ help: remove the underscore: `0xAB_CDu32`
14+
15+ error: integer type suffix should not be separated by an underscore
16+ --> $DIR/literals.rs:14:15
17+ |
18+ LL | let ok5 = 0xAB_CD_isize;
19+ | ^^^^^^^^^^^^^ help: remove the underscore: `0xAB_CDisize`
20+
121error: inconsistent casing in hexadecimal literal
2- --> $DIR/literals.rs:14 :17
22+ --> $DIR/literals.rs:15 :17
323 |
424LL | let fail1 = 0xabCD;
525 | ^^^^^^
626 |
727 = note: `-D clippy::mixed-case-hex-literals` implied by `-D warnings`
828
29+ error: integer type suffix should not be separated by an underscore
30+ --> $DIR/literals.rs:16:17
31+ |
32+ LL | let fail2 = 0xabCD_u32;
33+ | ^^^^^^^^^^ help: remove the underscore: `0xabCDu32`
34+
935error: inconsistent casing in hexadecimal literal
10- --> $DIR/literals.rs:15 :17
36+ --> $DIR/literals.rs:16 :17
1137 |
1238LL | let fail2 = 0xabCD_u32;
1339 | ^^^^^^^^^^
1440
41+ error: integer type suffix should not be separated by an underscore
42+ --> $DIR/literals.rs:17:17
43+ |
44+ LL | let fail2 = 0xabCD_isize;
45+ | ^^^^^^^^^^^^ help: remove the underscore: `0xabCDisize`
46+
1547error: inconsistent casing in hexadecimal literal
16- --> $DIR/literals.rs:16 :17
48+ --> $DIR/literals.rs:17 :17
1749 |
1850LL | let fail2 = 0xabCD_isize;
1951 | ^^^^^^^^^^^^
2052
53+ error: integer type suffix should be separated by an underscore
54+ --> $DIR/literals.rs:18:27
55+ |
56+ LL | let fail_multi_zero = 000_123usize;
57+ | ^^^^^^^^^^^^ help: add an underscore: `000_123_usize`
58+ |
59+ = note: `-D clippy::unseparated-literal-suffix` implied by `-D warnings`
60+
2161error: this is a decimal constant
22- --> $DIR/literals.rs:17 :27
62+ --> $DIR/literals.rs:18 :27
2363 |
2464LL | let fail_multi_zero = 000_123usize;
2565 | ^^^^^^^^^^^^
@@ -34,8 +74,14 @@ help: if you mean to use an octal constant, use `0o`
3474LL | let fail_multi_zero = 0o123usize;
3575 | ~~~~~~~~~~
3676
77+ error: integer type suffix should not be separated by an underscore
78+ --> $DIR/literals.rs:21:16
79+ |
80+ LL | let ok10 = 0_i64;
81+ | ^^^^^ help: remove the underscore: `0i64`
82+
3783error: this is a decimal constant
38- --> $DIR/literals.rs:21 :17
84+ --> $DIR/literals.rs:22 :17
3985 |
4086LL | let fail8 = 0123;
4187 | ^^^^
@@ -49,39 +95,45 @@ help: if you mean to use an octal constant, use `0o`
4995LL | let fail8 = 0o123;
5096 | ~~~~~
5197
98+ error: integer type suffix should not be separated by an underscore
99+ --> $DIR/literals.rs:31:16
100+ |
101+ LL | let ok17 = 0x123_4567_8901_usize;
102+ | ^^^^^^^^^^^^^^^^^^^^^ help: remove the underscore: `0x123_4567_8901usize`
103+
52104error: digits grouped inconsistently by underscores
53- --> $DIR/literals.rs:33 :18
105+ --> $DIR/literals.rs:34 :18
54106 |
55107LL | let fail19 = 12_3456_21;
56108 | ^^^^^^^^^^ help: consider: `12_345_621`
57109 |
58110 = note: `-D clippy::inconsistent-digit-grouping` implied by `-D warnings`
59111
60112error: digits grouped inconsistently by underscores
61- --> $DIR/literals.rs:34 :18
113+ --> $DIR/literals.rs:35 :18
62114 |
63115LL | let fail22 = 3__4___23;
64116 | ^^^^^^^^^ help: consider: `3_423`
65117
66118error: digits grouped inconsistently by underscores
67- --> $DIR/literals.rs:35 :18
119+ --> $DIR/literals.rs:36 :18
68120 |
69121LL | let fail23 = 3__16___23;
70122 | ^^^^^^^^^^ help: consider: `31_623`
71123
72124error: digits of hex or binary literal not grouped by four
73- --> $DIR/literals.rs:37 :18
125+ --> $DIR/literals.rs:38 :18
74126 |
75127LL | let fail24 = 0xAB_ABC_AB;
76128 | ^^^^^^^^^^^ help: consider: `0x0ABA_BCAB`
77129 |
78130 = note: `-D clippy::unusual-byte-groupings` implied by `-D warnings`
79131
80132error: digits of hex or binary literal not grouped by four
81- --> $DIR/literals.rs:38 :18
133+ --> $DIR/literals.rs:39 :18
82134 |
83135LL | let fail25 = 0b01_100_101;
84136 | ^^^^^^^^^^^^ help: consider: `0b0110_0101`
85137
86- error: aborting due to 10 previous errors
138+ error: aborting due to 18 previous errors
87139
0 commit comments