@@ -79,24 +79,33 @@ LL | fn option_repr_rust(x: Option<Rust<num::NonZero<u8>>>);
79
79
= help: consider adding a `#[repr(C)]`, `#[repr(transparent)]`, or integer `#[repr(...)]` attribute to this enum
80
80
= note: enum has no representation hint
81
81
82
+ error: `extern` block uses type `Option<u8>`, which is not FFI-safe
83
+ --> $DIR/lint-ctypes-enum.rs:97:21
84
+ |
85
+ LL | fn option_u8(x: Option<u8>);
86
+ | ^^^^^^^^^^ not FFI-safe
87
+ |
88
+ = help: consider adding a `#[repr(C)]`, `#[repr(transparent)]`, or integer `#[repr(...)]` attribute to this enum
89
+ = note: enum has no representation hint
90
+
82
91
error: `extern` block uses type `u128`, which is not FFI-safe
83
- --> $DIR/lint-ctypes-enum.rs:106 :33
92
+ --> $DIR/lint-ctypes-enum.rs:107 :33
84
93
|
85
94
LL | fn result_nonzero_u128_t(x: Result<num::NonZero<u128>, ()>);
86
95
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
87
96
|
88
97
= note: 128-bit integers don't currently have a known stable ABI
89
98
90
99
error: `extern` block uses type `i128`, which is not FFI-safe
91
- --> $DIR/lint-ctypes-enum.rs:113 :33
100
+ --> $DIR/lint-ctypes-enum.rs:114 :33
92
101
|
93
102
LL | fn result_nonzero_i128_t(x: Result<num::NonZero<i128>, ()>);
94
103
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
95
104
|
96
105
= note: 128-bit integers don't currently have a known stable ABI
97
106
98
107
error: `extern` block uses type `Result<TransparentUnion<NonZero<u8>>, ()>`, which is not FFI-safe
99
- --> $DIR/lint-ctypes-enum.rs:118 :38
108
+ --> $DIR/lint-ctypes-enum.rs:119 :38
100
109
|
101
110
LL | fn result_transparent_union_t(x: Result<TransparentUnion<num::NonZero<u8>>, ()>);
102
111
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -105,7 +114,7 @@ LL | fn result_transparent_union_t(x: Result<TransparentUnion<num::NonZero<u
105
114
= note: enum has no representation hint
106
115
107
116
error: `extern` block uses type `Result<Rust<NonZero<u8>>, ()>`, which is not FFI-safe
108
- --> $DIR/lint-ctypes-enum.rs:120 :30
117
+ --> $DIR/lint-ctypes-enum.rs:121 :30
109
118
|
110
119
LL | fn result_repr_rust_t(x: Result<Rust<num::NonZero<u8>>, ()>);
111
120
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -114,7 +123,7 @@ LL | fn result_repr_rust_t(x: Result<Rust<num::NonZero<u8>>, ()>);
114
123
= note: enum has no representation hint
115
124
116
125
error: `extern` block uses type `Result<NonZero<u8>, U>`, which is not FFI-safe
117
- --> $DIR/lint-ctypes-enum.rs:124 :51
126
+ --> $DIR/lint-ctypes-enum.rs:125 :51
118
127
|
119
128
LL | fn result_1zst_exhaustive_single_variant_t(x: Result<num::NonZero<u8>, U>);
120
129
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -123,7 +132,7 @@ LL | fn result_1zst_exhaustive_single_variant_t(x: Result<num::NonZero<u8>,
123
132
= note: enum has no representation hint
124
133
125
134
error: `extern` block uses type `Result<NonZero<u8>, B>`, which is not FFI-safe
126
- --> $DIR/lint-ctypes-enum.rs:126 :53
135
+ --> $DIR/lint-ctypes-enum.rs:127 :53
127
136
|
128
137
LL | fn result_1zst_exhaustive_multiple_variant_t(x: Result<num::NonZero<u8>, B>);
129
138
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -132,7 +141,7 @@ LL | fn result_1zst_exhaustive_multiple_variant_t(x: Result<num::NonZero<u8>
132
141
= note: enum has no representation hint
133
142
134
143
error: `extern` block uses type `Result<NonZero<u8>, NonExhaustive>`, which is not FFI-safe
135
- --> $DIR/lint-ctypes-enum.rs:128 :51
144
+ --> $DIR/lint-ctypes-enum.rs:129 :51
136
145
|
137
146
LL | fn result_1zst_non_exhaustive_no_variant_t(x: Result<num::NonZero<u8>, NonExhaustive>);
138
147
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -141,7 +150,7 @@ LL | fn result_1zst_non_exhaustive_no_variant_t(x: Result<num::NonZero<u8>,
141
150
= note: enum has no representation hint
142
151
143
152
error: `extern` block uses type `Result<NonZero<u8>, Field>`, which is not FFI-safe
144
- --> $DIR/lint-ctypes-enum.rs:131 :49
153
+ --> $DIR/lint-ctypes-enum.rs:132 :49
145
154
|
146
155
LL | fn result_1zst_exhaustive_single_field_t(x: Result<num::NonZero<u8>, Field>);
147
156
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -150,7 +159,7 @@ LL | fn result_1zst_exhaustive_single_field_t(x: Result<num::NonZero<u8>, Fi
150
159
= note: enum has no representation hint
151
160
152
161
error: `extern` block uses type `Result<Result<(), NonZero<u8>>, ()>`, which is not FFI-safe
153
- --> $DIR/lint-ctypes-enum.rs:133 :30
162
+ --> $DIR/lint-ctypes-enum.rs:134 :30
154
163
|
155
164
LL | fn result_cascading_t(x: Result<Result<(), num::NonZero<u8>>, ()>);
156
165
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -159,23 +168,23 @@ LL | fn result_cascading_t(x: Result<Result<(), num::NonZero<u8>>, ()>);
159
168
= note: enum has no representation hint
160
169
161
170
error: `extern` block uses type `u128`, which is not FFI-safe
162
- --> $DIR/lint-ctypes-enum.rs:144 :33
171
+ --> $DIR/lint-ctypes-enum.rs:145 :33
163
172
|
164
173
LL | fn result_nonzero_u128_e(x: Result<(), num::NonZero<u128>>);
165
174
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
166
175
|
167
176
= note: 128-bit integers don't currently have a known stable ABI
168
177
169
178
error: `extern` block uses type `i128`, which is not FFI-safe
170
- --> $DIR/lint-ctypes-enum.rs:151 :33
179
+ --> $DIR/lint-ctypes-enum.rs:152 :33
171
180
|
172
181
LL | fn result_nonzero_i128_e(x: Result<(), num::NonZero<i128>>);
173
182
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
174
183
|
175
184
= note: 128-bit integers don't currently have a known stable ABI
176
185
177
186
error: `extern` block uses type `Result<(), TransparentUnion<NonZero<u8>>>`, which is not FFI-safe
178
- --> $DIR/lint-ctypes-enum.rs:156 :38
187
+ --> $DIR/lint-ctypes-enum.rs:157 :38
179
188
|
180
189
LL | fn result_transparent_union_e(x: Result<(), TransparentUnion<num::NonZero<u8>>>);
181
190
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -184,7 +193,7 @@ LL | fn result_transparent_union_e(x: Result<(), TransparentUnion<num::NonZe
184
193
= note: enum has no representation hint
185
194
186
195
error: `extern` block uses type `Result<(), Rust<NonZero<u8>>>`, which is not FFI-safe
187
- --> $DIR/lint-ctypes-enum.rs:158 :30
196
+ --> $DIR/lint-ctypes-enum.rs:159 :30
188
197
|
189
198
LL | fn result_repr_rust_e(x: Result<(), Rust<num::NonZero<u8>>>);
190
199
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -193,7 +202,7 @@ LL | fn result_repr_rust_e(x: Result<(), Rust<num::NonZero<u8>>>);
193
202
= note: enum has no representation hint
194
203
195
204
error: `extern` block uses type `Result<U, NonZero<u8>>`, which is not FFI-safe
196
- --> $DIR/lint-ctypes-enum.rs:162 :51
205
+ --> $DIR/lint-ctypes-enum.rs:163 :51
197
206
|
198
207
LL | fn result_1zst_exhaustive_single_variant_e(x: Result<U, num::NonZero<u8>>);
199
208
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -202,7 +211,7 @@ LL | fn result_1zst_exhaustive_single_variant_e(x: Result<U, num::NonZero<u8
202
211
= note: enum has no representation hint
203
212
204
213
error: `extern` block uses type `Result<B, NonZero<u8>>`, which is not FFI-safe
205
- --> $DIR/lint-ctypes-enum.rs:164 :53
214
+ --> $DIR/lint-ctypes-enum.rs:165 :53
206
215
|
207
216
LL | fn result_1zst_exhaustive_multiple_variant_e(x: Result<B, num::NonZero<u8>>);
208
217
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -211,7 +220,7 @@ LL | fn result_1zst_exhaustive_multiple_variant_e(x: Result<B, num::NonZero<
211
220
= note: enum has no representation hint
212
221
213
222
error: `extern` block uses type `Result<NonExhaustive, NonZero<u8>>`, which is not FFI-safe
214
- --> $DIR/lint-ctypes-enum.rs:166 :51
223
+ --> $DIR/lint-ctypes-enum.rs:167 :51
215
224
|
216
225
LL | fn result_1zst_non_exhaustive_no_variant_e(x: Result<NonExhaustive, num::NonZero<u8>>);
217
226
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -220,7 +229,7 @@ LL | fn result_1zst_non_exhaustive_no_variant_e(x: Result<NonExhaustive, num
220
229
= note: enum has no representation hint
221
230
222
231
error: `extern` block uses type `Result<Field, NonZero<u8>>`, which is not FFI-safe
223
- --> $DIR/lint-ctypes-enum.rs:169 :49
232
+ --> $DIR/lint-ctypes-enum.rs:170 :49
224
233
|
225
234
LL | fn result_1zst_exhaustive_single_field_e(x: Result<Field, num::NonZero<u8>>);
226
235
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -229,7 +238,7 @@ LL | fn result_1zst_exhaustive_single_field_e(x: Result<Field, num::NonZero<
229
238
= note: enum has no representation hint
230
239
231
240
error: `extern` block uses type `Result<(), Result<(), NonZero<u8>>>`, which is not FFI-safe
232
- --> $DIR/lint-ctypes-enum.rs:171 :30
241
+ --> $DIR/lint-ctypes-enum.rs:172 :30
233
242
|
234
243
LL | fn result_cascading_e(x: Result<(), Result<(), num::NonZero<u8>>>);
235
244
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not FFI-safe
@@ -238,13 +247,13 @@ LL | fn result_cascading_e(x: Result<(), Result<(), num::NonZero<u8>>>);
238
247
= note: enum has no representation hint
239
248
240
249
error: `extern` block uses type `Result<(), ()>`, which is not FFI-safe
241
- --> $DIR/lint-ctypes-enum.rs:173 :27
250
+ --> $DIR/lint-ctypes-enum.rs:174 :27
242
251
|
243
252
LL | fn result_unit_t_e(x: Result<(), ()>);
244
253
| ^^^^^^^^^^^^^^ not FFI-safe
245
254
|
246
255
= help: consider adding a `#[repr(C)]`, `#[repr(transparent)]`, or integer `#[repr(...)]` attribute to this enum
247
256
= note: enum has no representation hint
248
257
249
- error: aborting due to 26 previous errors
258
+ error: aborting due to 27 previous errors
250
259
0 commit comments