@@ -45,50 +45,8 @@ note: the type is defined here
45
45
LL | enum T {
46
46
| ^^^^^^
47
47
48
- error: `extern` block uses type `U128`, which is not FFI-safe
49
- --> $DIR/lint-ctypes-enum.rs:90:21
50
- |
51
- LL | fn repr_u128(x: U128);
52
- | ^^^^ not FFI-safe
53
- |
54
- = note: 128-bit integers don't currently have a known stable ABI
55
- note: the type is defined here
56
- --> $DIR/lint-ctypes-enum.rs:46:1
57
- |
58
- LL | enum U128 {
59
- | ^^^^^^^^^
60
-
61
- error: `extern` block uses type `I128`, which is not FFI-safe
62
- --> $DIR/lint-ctypes-enum.rs:91:21
63
- |
64
- LL | fn repr_i128(x: I128);
65
- | ^^^^ not FFI-safe
66
- |
67
- = note: 128-bit integers don't currently have a known stable ABI
68
- note: the type is defined here
69
- --> $DIR/lint-ctypes-enum.rs:53:1
70
- |
71
- LL | enum I128 {
72
- | ^^^^^^^^^
73
-
74
- error: `extern` block uses type `u128`, which is not FFI-safe
75
- --> $DIR/lint-ctypes-enum.rs:100:31
76
- |
77
- LL | fn option_nonzero_u128(x: Option<num::NonZero<u128>>);
78
- | ^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
79
- |
80
- = note: 128-bit integers don't currently have a known stable ABI
81
-
82
- error: `extern` block uses type `i128`, which is not FFI-safe
83
- --> $DIR/lint-ctypes-enum.rs:107:31
84
- |
85
- LL | fn option_nonzero_i128(x: Option<num::NonZero<i128>>);
86
- | ^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
87
- |
88
- = note: 128-bit integers don't currently have a known stable ABI
89
-
90
48
error: `extern` block uses type `Option<TransparentUnion<NonZero<u8>>>`, which is not FFI-safe
91
- --> $DIR/lint-ctypes-enum.rs:112 :36
49
+ --> $DIR/lint-ctypes-enum.rs:110 :36
92
50
|
93
51
LL | fn option_transparent_union(x: Option<TransparentUnion<num::NonZero<u8>>>);
94
52
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -97,7 +55,7 @@ LL | fn option_transparent_union(x: Option<TransparentUnion<num::NonZero<u8>
97
55
= note: enum has no representation hint
98
56
99
57
error: `extern` block uses type `Option<Rust<NonZero<u8>>>`, which is not FFI-safe
100
- --> $DIR/lint-ctypes-enum.rs:114 :28
58
+ --> $DIR/lint-ctypes-enum.rs:112 :28
101
59
|
102
60
LL | fn option_repr_rust(x: Option<Rust<num::NonZero<u8>>>);
103
61
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -106,32 +64,16 @@ LL | fn option_repr_rust(x: Option<Rust<num::NonZero<u8>>>);
106
64
= note: enum has no representation hint
107
65
108
66
error: `extern` block uses type `Option<u8>`, which is not FFI-safe
109
- --> $DIR/lint-ctypes-enum.rs:115 :21
67
+ --> $DIR/lint-ctypes-enum.rs:113 :21
110
68
|
111
69
LL | fn option_u8(x: Option<u8>);
112
70
| ^^^^^^^^^^ not FFI-safe
113
71
|
114
72
= help: consider adding a `#[repr(C)]`, `#[repr(transparent)]`, or integer `#[repr(...)]` attribute to this enum
115
73
= note: enum has no representation hint
116
74
117
- error: `extern` block uses type `u128`, which is not FFI-safe
118
- --> $DIR/lint-ctypes-enum.rs:125:33
119
- |
120
- LL | fn result_nonzero_u128_t(x: Result<num::NonZero<u128>, ()>);
121
- | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
122
- |
123
- = note: 128-bit integers don't currently have a known stable ABI
124
-
125
- error: `extern` block uses type `i128`, which is not FFI-safe
126
- --> $DIR/lint-ctypes-enum.rs:132:33
127
- |
128
- LL | fn result_nonzero_i128_t(x: Result<num::NonZero<i128>, ()>);
129
- | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
130
- |
131
- = note: 128-bit integers don't currently have a known stable ABI
132
-
133
75
error: `extern` block uses type `Result<TransparentUnion<NonZero<u8>>, ()>`, which is not FFI-safe
134
- --> $DIR/lint-ctypes-enum.rs:137 :38
76
+ --> $DIR/lint-ctypes-enum.rs:133 :38
135
77
|
136
78
LL | fn result_transparent_union_t(x: Result<TransparentUnion<num::NonZero<u8>>, ()>);
137
79
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -140,7 +82,7 @@ LL | fn result_transparent_union_t(x: Result<TransparentUnion<num::NonZero<u
140
82
= note: enum has no representation hint
141
83
142
84
error: `extern` block uses type `Result<Rust<NonZero<u8>>, ()>`, which is not FFI-safe
143
- --> $DIR/lint-ctypes-enum.rs:139 :30
85
+ --> $DIR/lint-ctypes-enum.rs:135 :30
144
86
|
145
87
LL | fn result_repr_rust_t(x: Result<Rust<num::NonZero<u8>>, ()>);
146
88
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -149,7 +91,7 @@ LL | fn result_repr_rust_t(x: Result<Rust<num::NonZero<u8>>, ()>);
149
91
= note: enum has no representation hint
150
92
151
93
error: `extern` block uses type `Result<NonZero<u8>, U>`, which is not FFI-safe
152
- --> $DIR/lint-ctypes-enum.rs:143 :51
94
+ --> $DIR/lint-ctypes-enum.rs:139 :51
153
95
|
154
96
LL | fn result_1zst_exhaustive_single_variant_t(x: Result<num::NonZero<u8>, U>);
155
97
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -158,7 +100,7 @@ LL | fn result_1zst_exhaustive_single_variant_t(x: Result<num::NonZero<u8>,
158
100
= note: enum has no representation hint
159
101
160
102
error: `extern` block uses type `Result<NonZero<u8>, B>`, which is not FFI-safe
161
- --> $DIR/lint-ctypes-enum.rs:145 :53
103
+ --> $DIR/lint-ctypes-enum.rs:141 :53
162
104
|
163
105
LL | fn result_1zst_exhaustive_multiple_variant_t(x: Result<num::NonZero<u8>, B>);
164
106
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -167,7 +109,7 @@ LL | fn result_1zst_exhaustive_multiple_variant_t(x: Result<num::NonZero<u8>
167
109
= note: enum has no representation hint
168
110
169
111
error: `extern` block uses type `Result<NonZero<u8>, NonExhaustive>`, which is not FFI-safe
170
- --> $DIR/lint-ctypes-enum.rs:147 :51
112
+ --> $DIR/lint-ctypes-enum.rs:143 :51
171
113
|
172
114
LL | fn result_1zst_non_exhaustive_no_variant_t(x: Result<num::NonZero<u8>, NonExhaustive>);
173
115
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -176,7 +118,7 @@ LL | fn result_1zst_non_exhaustive_no_variant_t(x: Result<num::NonZero<u8>,
176
118
= note: enum has no representation hint
177
119
178
120
error: `extern` block uses type `Result<NonZero<u8>, Field>`, which is not FFI-safe
179
- --> $DIR/lint-ctypes-enum.rs:150 :49
121
+ --> $DIR/lint-ctypes-enum.rs:146 :49
180
122
|
181
123
LL | fn result_1zst_exhaustive_single_field_t(x: Result<num::NonZero<u8>, Field>);
182
124
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -185,32 +127,16 @@ LL | fn result_1zst_exhaustive_single_field_t(x: Result<num::NonZero<u8>, Fi
185
127
= note: enum has no representation hint
186
128
187
129
error: `extern` block uses type `Result<Result<(), NonZero<u8>>, ()>`, which is not FFI-safe
188
- --> $DIR/lint-ctypes-enum.rs:152 :30
130
+ --> $DIR/lint-ctypes-enum.rs:148 :30
189
131
|
190
132
LL | fn result_cascading_t(x: Result<Result<(), num::NonZero<u8>>, ()>);
191
133
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
192
134
|
193
135
= help: consider adding a `#[repr(C)]`, `#[repr(transparent)]`, or integer `#[repr(...)]` attribute to this enum
194
136
= note: enum has no representation hint
195
137
196
- error: `extern` block uses type `u128`, which is not FFI-safe
197
- --> $DIR/lint-ctypes-enum.rs:163:33
198
- |
199
- LL | fn result_nonzero_u128_e(x: Result<(), num::NonZero<u128>>);
200
- | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
201
- |
202
- = note: 128-bit integers don't currently have a known stable ABI
203
-
204
- error: `extern` block uses type `i128`, which is not FFI-safe
205
- --> $DIR/lint-ctypes-enum.rs:170:33
206
- |
207
- LL | fn result_nonzero_i128_e(x: Result<(), num::NonZero<i128>>);
208
- | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
209
- |
210
- = note: 128-bit integers don't currently have a known stable ABI
211
-
212
138
error: `extern` block uses type `Result<(), TransparentUnion<NonZero<u8>>>`, which is not FFI-safe
213
- --> $DIR/lint-ctypes-enum.rs:175 :38
139
+ --> $DIR/lint-ctypes-enum.rs:169 :38
214
140
|
215
141
LL | fn result_transparent_union_e(x: Result<(), TransparentUnion<num::NonZero<u8>>>);
216
142
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -219,7 +145,7 @@ LL | fn result_transparent_union_e(x: Result<(), TransparentUnion<num::NonZe
219
145
= note: enum has no representation hint
220
146
221
147
error: `extern` block uses type `Result<(), Rust<NonZero<u8>>>`, which is not FFI-safe
222
- --> $DIR/lint-ctypes-enum.rs:177 :30
148
+ --> $DIR/lint-ctypes-enum.rs:171 :30
223
149
|
224
150
LL | fn result_repr_rust_e(x: Result<(), Rust<num::NonZero<u8>>>);
225
151
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -228,7 +154,7 @@ LL | fn result_repr_rust_e(x: Result<(), Rust<num::NonZero<u8>>>);
228
154
= note: enum has no representation hint
229
155
230
156
error: `extern` block uses type `Result<U, NonZero<u8>>`, which is not FFI-safe
231
- --> $DIR/lint-ctypes-enum.rs:181 :51
157
+ --> $DIR/lint-ctypes-enum.rs:175 :51
232
158
|
233
159
LL | fn result_1zst_exhaustive_single_variant_e(x: Result<U, num::NonZero<u8>>);
234
160
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -237,7 +163,7 @@ LL | fn result_1zst_exhaustive_single_variant_e(x: Result<U, num::NonZero<u8
237
163
= note: enum has no representation hint
238
164
239
165
error: `extern` block uses type `Result<B, NonZero<u8>>`, which is not FFI-safe
240
- --> $DIR/lint-ctypes-enum.rs:183 :53
166
+ --> $DIR/lint-ctypes-enum.rs:177 :53
241
167
|
242
168
LL | fn result_1zst_exhaustive_multiple_variant_e(x: Result<B, num::NonZero<u8>>);
243
169
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -246,7 +172,7 @@ LL | fn result_1zst_exhaustive_multiple_variant_e(x: Result<B, num::NonZero<
246
172
= note: enum has no representation hint
247
173
248
174
error: `extern` block uses type `Result<NonExhaustive, NonZero<u8>>`, which is not FFI-safe
249
- --> $DIR/lint-ctypes-enum.rs:185 :51
175
+ --> $DIR/lint-ctypes-enum.rs:179 :51
250
176
|
251
177
LL | fn result_1zst_non_exhaustive_no_variant_e(x: Result<NonExhaustive, num::NonZero<u8>>);
252
178
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -255,7 +181,7 @@ LL | fn result_1zst_non_exhaustive_no_variant_e(x: Result<NonExhaustive, num
255
181
= note: enum has no representation hint
256
182
257
183
error: `extern` block uses type `Result<Field, NonZero<u8>>`, which is not FFI-safe
258
- --> $DIR/lint-ctypes-enum.rs:188 :49
184
+ --> $DIR/lint-ctypes-enum.rs:182 :49
259
185
|
260
186
LL | fn result_1zst_exhaustive_single_field_e(x: Result<Field, num::NonZero<u8>>);
261
187
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -264,7 +190,7 @@ LL | fn result_1zst_exhaustive_single_field_e(x: Result<Field, num::NonZero<
264
190
= note: enum has no representation hint
265
191
266
192
error: `extern` block uses type `Result<(), Result<(), NonZero<u8>>>`, which is not FFI-safe
267
- --> $DIR/lint-ctypes-enum.rs:190 :30
193
+ --> $DIR/lint-ctypes-enum.rs:184 :30
268
194
|
269
195
LL | fn result_cascading_e(x: Result<(), Result<(), num::NonZero<u8>>>);
270
196
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -273,13 +199,13 @@ LL | fn result_cascading_e(x: Result<(), Result<(), num::NonZero<u8>>>);
273
199
= note: enum has no representation hint
274
200
275
201
error: `extern` block uses type `Result<(), ()>`, which is not FFI-safe
276
- --> $DIR/lint-ctypes-enum.rs:192 :27
202
+ --> $DIR/lint-ctypes-enum.rs:186 :27
277
203
|
278
204
LL | fn result_unit_t_e(x: Result<(), ()>);
279
205
| ^^^^^^^^^^^^^^ not FFI-safe
280
206
|
281
207
= help: consider adding a `#[repr(C)]`, `#[repr(transparent)]`, or integer `#[repr(...)]` attribute to this enum
282
208
= note: enum has no representation hint
283
209
284
- error: aborting due to 29 previous errors
210
+ error: aborting due to 21 previous errors
285
211
0 commit comments