1#![allow(non_upper_case_globals)]
2#![allow(non_camel_case_types)]
3#![allow(non_snake_case)]
4#![allow(dead_code)]
5
6pub type size_t = ::std::os::raw::c_ulong;
9pub type __uint8_t = ::std::os::raw::c_uchar;
10pub type __uint16_t = ::std::os::raw::c_ushort;
11pub type __int32_t = ::std::os::raw::c_int;
12pub type __uint32_t = ::std::os::raw::c_uint;
13pub type __int64_t = ::std::os::raw::c_longlong;
14pub type __uint64_t = ::std::os::raw::c_ulonglong;
15pub type __darwin_natural_t = ::std::os::raw::c_uint;
16pub type __darwin_socklen_t = __uint32_t;
17pub type __darwin_ssize_t = ::std::os::raw::c_long;
18pub type __darwin_gid_t = __uint32_t;
19pub type __darwin_mach_port_name_t = __darwin_natural_t;
20pub type __darwin_mach_port_t = __darwin_mach_port_name_t;
21pub type __darwin_mode_t = __uint16_t;
22pub type __darwin_off_t = __int64_t;
23pub type __darwin_pid_t = __int32_t;
24pub type __darwin_uid_t = __uint32_t;
25#[repr(C)]
26#[derive(Debug, Copy, Clone)]
27pub struct __darwin_pthread_handler_rec {
28 pub __routine: ::std::option::Option<unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void)>,
29 pub __arg: *mut ::std::os::raw::c_void,
30 pub __next: *mut __darwin_pthread_handler_rec,
31}
32#[test]
33fn bindgen_test_layout___darwin_pthread_handler_rec() {
34 assert_eq!(
35 ::std::mem::size_of::<__darwin_pthread_handler_rec>(),
36 24usize,
37 concat!("Size of: ", stringify!(__darwin_pthread_handler_rec))
38 );
39 assert_eq!(
40 ::std::mem::align_of::<__darwin_pthread_handler_rec>(),
41 8usize,
42 concat!("Alignment of ", stringify!(__darwin_pthread_handler_rec))
43 );
44 assert_eq!(
45 unsafe {
46 &(*(::std::ptr::null::<__darwin_pthread_handler_rec>())).__routine as *const _ as usize
47 },
48 0usize,
49 concat!(
50 "Offset of field: ",
51 stringify!(__darwin_pthread_handler_rec),
52 "::",
53 stringify!(__routine)
54 )
55 );
56 assert_eq!(
57 unsafe {
58 &(*(::std::ptr::null::<__darwin_pthread_handler_rec>())).__arg as *const _ as usize
59 },
60 8usize,
61 concat!(
62 "Offset of field: ",
63 stringify!(__darwin_pthread_handler_rec),
64 "::",
65 stringify!(__arg)
66 )
67 );
68 assert_eq!(
69 unsafe {
70 &(*(::std::ptr::null::<__darwin_pthread_handler_rec>())).__next as *const _ as usize
71 },
72 16usize,
73 concat!(
74 "Offset of field: ",
75 stringify!(__darwin_pthread_handler_rec),
76 "::",
77 stringify!(__next)
78 )
79 );
80}
81impl Default for __darwin_pthread_handler_rec {
82 fn default() -> Self {
83 unsafe { ::std::mem::zeroed() }
84 }
85}
86#[repr(C)]
87#[derive(Copy, Clone)]
88pub struct _opaque_pthread_cond_t {
89 pub __sig: ::std::os::raw::c_long,
90 pub __opaque: [::std::os::raw::c_char; 40usize],
91}
92#[test]
93fn bindgen_test_layout__opaque_pthread_cond_t() {
94 assert_eq!(
95 ::std::mem::size_of::<_opaque_pthread_cond_t>(),
96 48usize,
97 concat!("Size of: ", stringify!(_opaque_pthread_cond_t))
98 );
99 assert_eq!(
100 ::std::mem::align_of::<_opaque_pthread_cond_t>(),
101 8usize,
102 concat!("Alignment of ", stringify!(_opaque_pthread_cond_t))
103 );
104 assert_eq!(
105 unsafe { &(*(::std::ptr::null::<_opaque_pthread_cond_t>())).__sig as *const _ as usize },
106 0usize,
107 concat!(
108 "Offset of field: ",
109 stringify!(_opaque_pthread_cond_t),
110 "::",
111 stringify!(__sig)
112 )
113 );
114 assert_eq!(
115 unsafe { &(*(::std::ptr::null::<_opaque_pthread_cond_t>())).__opaque as *const _ as usize },
116 8usize,
117 concat!(
118 "Offset of field: ",
119 stringify!(_opaque_pthread_cond_t),
120 "::",
121 stringify!(__opaque)
122 )
123 );
124}
125impl Default for _opaque_pthread_cond_t {
126 fn default() -> Self {
127 unsafe { ::std::mem::zeroed() }
128 }
129}
130#[repr(C)]
131#[derive(Copy, Clone)]
132pub struct _opaque_pthread_mutex_t {
133 pub __sig: ::std::os::raw::c_long,
134 pub __opaque: [::std::os::raw::c_char; 56usize],
135}
136#[test]
137fn bindgen_test_layout__opaque_pthread_mutex_t() {
138 assert_eq!(
139 ::std::mem::size_of::<_opaque_pthread_mutex_t>(),
140 64usize,
141 concat!("Size of: ", stringify!(_opaque_pthread_mutex_t))
142 );
143 assert_eq!(
144 ::std::mem::align_of::<_opaque_pthread_mutex_t>(),
145 8usize,
146 concat!("Alignment of ", stringify!(_opaque_pthread_mutex_t))
147 );
148 assert_eq!(
149 unsafe { &(*(::std::ptr::null::<_opaque_pthread_mutex_t>())).__sig as *const _ as usize },
150 0usize,
151 concat!(
152 "Offset of field: ",
153 stringify!(_opaque_pthread_mutex_t),
154 "::",
155 stringify!(__sig)
156 )
157 );
158 assert_eq!(
159 unsafe {
160 &(*(::std::ptr::null::<_opaque_pthread_mutex_t>())).__opaque as *const _ as usize
161 },
162 8usize,
163 concat!(
164 "Offset of field: ",
165 stringify!(_opaque_pthread_mutex_t),
166 "::",
167 stringify!(__opaque)
168 )
169 );
170}
171impl Default for _opaque_pthread_mutex_t {
172 fn default() -> Self {
173 unsafe { ::std::mem::zeroed() }
174 }
175}
176#[repr(C)]
177#[derive(Debug, Default, Copy, Clone)]
178pub struct _opaque_pthread_once_t {
179 pub __sig: ::std::os::raw::c_long,
180 pub __opaque: [::std::os::raw::c_char; 8usize],
181}
182#[test]
183fn bindgen_test_layout__opaque_pthread_once_t() {
184 assert_eq!(
185 ::std::mem::size_of::<_opaque_pthread_once_t>(),
186 16usize,
187 concat!("Size of: ", stringify!(_opaque_pthread_once_t))
188 );
189 assert_eq!(
190 ::std::mem::align_of::<_opaque_pthread_once_t>(),
191 8usize,
192 concat!("Alignment of ", stringify!(_opaque_pthread_once_t))
193 );
194 assert_eq!(
195 unsafe { &(*(::std::ptr::null::<_opaque_pthread_once_t>())).__sig as *const _ as usize },
196 0usize,
197 concat!(
198 "Offset of field: ",
199 stringify!(_opaque_pthread_once_t),
200 "::",
201 stringify!(__sig)
202 )
203 );
204 assert_eq!(
205 unsafe { &(*(::std::ptr::null::<_opaque_pthread_once_t>())).__opaque as *const _ as usize },
206 8usize,
207 concat!(
208 "Offset of field: ",
209 stringify!(_opaque_pthread_once_t),
210 "::",
211 stringify!(__opaque)
212 )
213 );
214}
215#[repr(C)]
216#[derive(Copy, Clone)]
217pub struct _opaque_pthread_rwlock_t {
218 pub __sig: ::std::os::raw::c_long,
219 pub __opaque: [::std::os::raw::c_char; 192usize],
220}
221#[test]
222fn bindgen_test_layout__opaque_pthread_rwlock_t() {
223 assert_eq!(
224 ::std::mem::size_of::<_opaque_pthread_rwlock_t>(),
225 200usize,
226 concat!("Size of: ", stringify!(_opaque_pthread_rwlock_t))
227 );
228 assert_eq!(
229 ::std::mem::align_of::<_opaque_pthread_rwlock_t>(),
230 8usize,
231 concat!("Alignment of ", stringify!(_opaque_pthread_rwlock_t))
232 );
233 assert_eq!(
234 unsafe { &(*(::std::ptr::null::<_opaque_pthread_rwlock_t>())).__sig as *const _ as usize },
235 0usize,
236 concat!(
237 "Offset of field: ",
238 stringify!(_opaque_pthread_rwlock_t),
239 "::",
240 stringify!(__sig)
241 )
242 );
243 assert_eq!(
244 unsafe {
245 &(*(::std::ptr::null::<_opaque_pthread_rwlock_t>())).__opaque as *const _ as usize
246 },
247 8usize,
248 concat!(
249 "Offset of field: ",
250 stringify!(_opaque_pthread_rwlock_t),
251 "::",
252 stringify!(__opaque)
253 )
254 );
255}
256impl Default for _opaque_pthread_rwlock_t {
257 fn default() -> Self {
258 unsafe { ::std::mem::zeroed() }
259 }
260}
261#[repr(C)]
262#[derive(Copy, Clone)]
263pub struct _opaque_pthread_t {
264 pub __sig: ::std::os::raw::c_long,
265 pub __cleanup_stack: *mut __darwin_pthread_handler_rec,
266 pub __opaque: [::std::os::raw::c_char; 8176usize],
267}
268#[test]
269fn bindgen_test_layout__opaque_pthread_t() {
270 assert_eq!(
271 ::std::mem::size_of::<_opaque_pthread_t>(),
272 8192usize,
273 concat!("Size of: ", stringify!(_opaque_pthread_t))
274 );
275 assert_eq!(
276 ::std::mem::align_of::<_opaque_pthread_t>(),
277 8usize,
278 concat!("Alignment of ", stringify!(_opaque_pthread_t))
279 );
280 assert_eq!(
281 unsafe { &(*(::std::ptr::null::<_opaque_pthread_t>())).__sig as *const _ as usize },
282 0usize,
283 concat!(
284 "Offset of field: ",
285 stringify!(_opaque_pthread_t),
286 "::",
287 stringify!(__sig)
288 )
289 );
290 assert_eq!(
291 unsafe {
292 &(*(::std::ptr::null::<_opaque_pthread_t>())).__cleanup_stack as *const _ as usize
293 },
294 8usize,
295 concat!(
296 "Offset of field: ",
297 stringify!(_opaque_pthread_t),
298 "::",
299 stringify!(__cleanup_stack)
300 )
301 );
302 assert_eq!(
303 unsafe { &(*(::std::ptr::null::<_opaque_pthread_t>())).__opaque as *const _ as usize },
304 16usize,
305 concat!(
306 "Offset of field: ",
307 stringify!(_opaque_pthread_t),
308 "::",
309 stringify!(__opaque)
310 )
311 );
312}
313impl Default for _opaque_pthread_t {
314 fn default() -> Self {
315 unsafe { ::std::mem::zeroed() }
316 }
317}
318pub type __darwin_pthread_cond_t = _opaque_pthread_cond_t;
319pub type __darwin_pthread_key_t = ::std::os::raw::c_ulong;
320pub type __darwin_pthread_mutex_t = _opaque_pthread_mutex_t;
321pub type __darwin_pthread_once_t = _opaque_pthread_once_t;
322pub type __darwin_pthread_rwlock_t = _opaque_pthread_rwlock_t;
323pub type __darwin_pthread_t = *mut _opaque_pthread_t;
324pub type char16_t = u16;
325#[repr(C)]
326#[derive(Debug, Copy, Clone)]
327pub struct napi_env__ {
328 _unused: [u8; 0],
329}
330pub type napi_env = *mut napi_env__;
331#[repr(C)]
332#[derive(Debug, Copy, Clone)]
333pub struct napi_value__ {
334 _unused: [u8; 0],
335}
336pub type napi_value = *mut napi_value__;
337#[repr(C)]
338#[derive(Debug, Copy, Clone)]
339pub struct napi_ref__ {
340 _unused: [u8; 0],
341}
342pub type napi_ref = *mut napi_ref__;
343#[repr(C)]
344#[derive(Debug, Copy, Clone)]
345pub struct napi_handle_scope__ {
346 _unused: [u8; 0],
347}
348pub type napi_handle_scope = *mut napi_handle_scope__;
349#[repr(C)]
350#[derive(Debug, Copy, Clone)]
351pub struct napi_escapable_handle_scope__ {
352 _unused: [u8; 0],
353}
354pub type napi_escapable_handle_scope = *mut napi_escapable_handle_scope__;
355#[repr(C)]
356#[derive(Debug, Copy, Clone)]
357pub struct napi_callback_info__ {
358 _unused: [u8; 0],
359}
360pub type napi_callback_info = *mut napi_callback_info__;
361#[repr(C)]
362#[derive(Debug, Copy, Clone)]
363pub struct napi_deferred__ {
364 _unused: [u8; 0],
365}
366pub type napi_deferred = *mut napi_deferred__;
367#[repr(u32)]
368#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
369pub enum napi_property_attributes {
370 napi_default = 0,
371 napi_writable = 1,
372 napi_enumerable = 2,
373 napi_configurable = 4,
374 napi_static = 1024,
375 napi_default_method = 5,
376 napi_default_jsproperty = 7,
377}
378#[repr(u32)]
379#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
380pub enum napi_valuetype {
381 napi_undefined = 0,
382 napi_null = 1,
383 napi_boolean = 2,
384 napi_number = 3,
385 napi_string = 4,
386 napi_symbol = 5,
387 napi_object = 6,
388 napi_function = 7,
389 napi_external = 8,
390 napi_bigint = 9,
391}
392#[repr(u32)]
393#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
394pub enum napi_typedarray_type {
395 napi_int8_array = 0,
396 napi_uint8_array = 1,
397 napi_uint8_clamped_array = 2,
398 napi_int16_array = 3,
399 napi_uint16_array = 4,
400 napi_int32_array = 5,
401 napi_uint32_array = 6,
402 napi_float32_array = 7,
403 napi_float64_array = 8,
404 napi_bigint64_array = 9,
405 napi_biguint64_array = 10,
406}
407#[repr(u32)]
408#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
409pub enum napi_status {
410 napi_ok = 0,
411 napi_invalid_arg = 1,
412 napi_object_expected = 2,
413 napi_string_expected = 3,
414 napi_name_expected = 4,
415 napi_function_expected = 5,
416 napi_number_expected = 6,
417 napi_boolean_expected = 7,
418 napi_array_expected = 8,
419 napi_generic_failure = 9,
420 napi_pending_exception = 10,
421 napi_cancelled = 11,
422 napi_escape_called_twice = 12,
423 napi_handle_scope_mismatch = 13,
424 napi_callback_scope_mismatch = 14,
425 napi_queue_full = 15,
426 napi_closing = 16,
427 napi_bigint_expected = 17,
428 napi_date_expected = 18,
429 napi_arraybuffer_expected = 19,
430 napi_detachable_arraybuffer_expected = 20,
431 napi_would_deadlock = 21,
432}
433pub type napi_callback = ::std::option::Option<
434 unsafe extern "C" fn(env: napi_env, info: napi_callback_info) -> napi_value,
435>;
436pub type napi_finalize = ::std::option::Option<
437 unsafe extern "C" fn(
438 env: napi_env,
439 finalize_data: *mut ::std::os::raw::c_void,
440 finalize_hint: *mut ::std::os::raw::c_void,
441 ),
442>;
443#[repr(C)]
444#[derive(Debug, Copy, Clone)]
445pub struct napi_property_descriptor {
446 pub utf8name: *const ::std::os::raw::c_char,
447 pub name: napi_value,
448 pub method: napi_callback,
449 pub getter: napi_callback,
450 pub setter: napi_callback,
451 pub value: napi_value,
452 pub attributes: napi_property_attributes,
453 pub data: *mut ::std::os::raw::c_void,
454}
455#[test]
456fn bindgen_test_layout_napi_property_descriptor() {
457 assert_eq!(
458 ::std::mem::size_of::<napi_property_descriptor>(),
459 64usize,
460 concat!("Size of: ", stringify!(napi_property_descriptor))
461 );
462 assert_eq!(
463 ::std::mem::align_of::<napi_property_descriptor>(),
464 8usize,
465 concat!("Alignment of ", stringify!(napi_property_descriptor))
466 );
467 assert_eq!(
468 unsafe {
469 &(*(::std::ptr::null::<napi_property_descriptor>())).utf8name as *const _ as usize
470 },
471 0usize,
472 concat!(
473 "Offset of field: ",
474 stringify!(napi_property_descriptor),
475 "::",
476 stringify!(utf8name)
477 )
478 );
479 assert_eq!(
480 unsafe { &(*(::std::ptr::null::<napi_property_descriptor>())).name as *const _ as usize },
481 8usize,
482 concat!(
483 "Offset of field: ",
484 stringify!(napi_property_descriptor),
485 "::",
486 stringify!(name)
487 )
488 );
489 assert_eq!(
490 unsafe { &(*(::std::ptr::null::<napi_property_descriptor>())).method as *const _ as usize },
491 16usize,
492 concat!(
493 "Offset of field: ",
494 stringify!(napi_property_descriptor),
495 "::",
496 stringify!(method)
497 )
498 );
499 assert_eq!(
500 unsafe { &(*(::std::ptr::null::<napi_property_descriptor>())).getter as *const _ as usize },
501 24usize,
502 concat!(
503 "Offset of field: ",
504 stringify!(napi_property_descriptor),
505 "::",
506 stringify!(getter)
507 )
508 );
509 assert_eq!(
510 unsafe { &(*(::std::ptr::null::<napi_property_descriptor>())).setter as *const _ as usize },
511 32usize,
512 concat!(
513 "Offset of field: ",
514 stringify!(napi_property_descriptor),
515 "::",
516 stringify!(setter)
517 )
518 );
519 assert_eq!(
520 unsafe { &(*(::std::ptr::null::<napi_property_descriptor>())).value as *const _ as usize },
521 40usize,
522 concat!(
523 "Offset of field: ",
524 stringify!(napi_property_descriptor),
525 "::",
526 stringify!(value)
527 )
528 );
529 assert_eq!(
530 unsafe {
531 &(*(::std::ptr::null::<napi_property_descriptor>())).attributes as *const _ as usize
532 },
533 48usize,
534 concat!(
535 "Offset of field: ",
536 stringify!(napi_property_descriptor),
537 "::",
538 stringify!(attributes)
539 )
540 );
541 assert_eq!(
542 unsafe { &(*(::std::ptr::null::<napi_property_descriptor>())).data as *const _ as usize },
543 56usize,
544 concat!(
545 "Offset of field: ",
546 stringify!(napi_property_descriptor),
547 "::",
548 stringify!(data)
549 )
550 );
551}
552impl Default for napi_property_descriptor {
553 fn default() -> Self {
554 unsafe { ::std::mem::zeroed() }
555 }
556}
557#[repr(C)]
558#[derive(Debug, Copy, Clone)]
559pub struct napi_extended_error_info {
560 pub error_message: *const ::std::os::raw::c_char,
561 pub engine_reserved: *mut ::std::os::raw::c_void,
562 pub engine_error_code: u32,
563 pub error_code: napi_status,
564}
565#[test]
566fn bindgen_test_layout_napi_extended_error_info() {
567 assert_eq!(
568 ::std::mem::size_of::<napi_extended_error_info>(),
569 24usize,
570 concat!("Size of: ", stringify!(napi_extended_error_info))
571 );
572 assert_eq!(
573 ::std::mem::align_of::<napi_extended_error_info>(),
574 8usize,
575 concat!("Alignment of ", stringify!(napi_extended_error_info))
576 );
577 assert_eq!(
578 unsafe {
579 &(*(::std::ptr::null::<napi_extended_error_info>())).error_message as *const _ as usize
580 },
581 0usize,
582 concat!(
583 "Offset of field: ",
584 stringify!(napi_extended_error_info),
585 "::",
586 stringify!(error_message)
587 )
588 );
589 assert_eq!(
590 unsafe {
591 &(*(::std::ptr::null::<napi_extended_error_info>())).engine_reserved as *const _
592 as usize
593 },
594 8usize,
595 concat!(
596 "Offset of field: ",
597 stringify!(napi_extended_error_info),
598 "::",
599 stringify!(engine_reserved)
600 )
601 );
602 assert_eq!(
603 unsafe {
604 &(*(::std::ptr::null::<napi_extended_error_info>())).engine_error_code as *const _
605 as usize
606 },
607 16usize,
608 concat!(
609 "Offset of field: ",
610 stringify!(napi_extended_error_info),
611 "::",
612 stringify!(engine_error_code)
613 )
614 );
615 assert_eq!(
616 unsafe {
617 &(*(::std::ptr::null::<napi_extended_error_info>())).error_code as *const _ as usize
618 },
619 20usize,
620 concat!(
621 "Offset of field: ",
622 stringify!(napi_extended_error_info),
623 "::",
624 stringify!(error_code)
625 )
626 );
627}
628impl Default for napi_extended_error_info {
629 fn default() -> Self {
630 unsafe { ::std::mem::zeroed() }
631 }
632}
633#[repr(u32)]
634#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
635pub enum napi_key_collection_mode {
636 napi_key_include_prototypes = 0,
637 napi_key_own_only = 1,
638}
639#[repr(u32)]
640#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
641pub enum napi_key_filter {
642 napi_key_all_properties = 0,
643 napi_key_writable = 1,
644 napi_key_enumerable = 2,
645 napi_key_configurable = 4,
646 napi_key_skip_strings = 8,
647 napi_key_skip_symbols = 16,
648}
649#[repr(u32)]
650#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
651pub enum napi_key_conversion {
652 napi_key_keep_numbers = 0,
653 napi_key_numbers_to_strings = 1,
654}
655#[repr(C)]
656#[derive(Debug, Default, Copy, Clone)]
657pub struct napi_type_tag {
658 pub lower: u64,
659 pub upper: u64,
660}
661#[test]
662fn bindgen_test_layout_napi_type_tag() {
663 assert_eq!(
664 ::std::mem::size_of::<napi_type_tag>(),
665 16usize,
666 concat!("Size of: ", stringify!(napi_type_tag))
667 );
668 assert_eq!(
669 ::std::mem::align_of::<napi_type_tag>(),
670 8usize,
671 concat!("Alignment of ", stringify!(napi_type_tag))
672 );
673 assert_eq!(
674 unsafe { &(*(::std::ptr::null::<napi_type_tag>())).lower as *const _ as usize },
675 0usize,
676 concat!(
677 "Offset of field: ",
678 stringify!(napi_type_tag),
679 "::",
680 stringify!(lower)
681 )
682 );
683 assert_eq!(
684 unsafe { &(*(::std::ptr::null::<napi_type_tag>())).upper as *const _ as usize },
685 8usize,
686 concat!(
687 "Offset of field: ",
688 stringify!(napi_type_tag),
689 "::",
690 stringify!(upper)
691 )
692 );
693}
694extern "C" {
695 pub fn napi_get_last_error_info(
696 env: napi_env,
697 result: *mut *const napi_extended_error_info,
698 ) -> napi_status;
699}
700extern "C" {
701 pub fn napi_get_undefined(env: napi_env, result: *mut napi_value) -> napi_status;
702}
703extern "C" {
704 pub fn napi_get_null(env: napi_env, result: *mut napi_value) -> napi_status;
705}
706extern "C" {
707 pub fn napi_get_global(env: napi_env, result: *mut napi_value) -> napi_status;
708}
709extern "C" {
710 pub fn napi_get_boolean(env: napi_env, value: bool, result: *mut napi_value) -> napi_status;
711}
712extern "C" {
713 pub fn napi_create_object(env: napi_env, result: *mut napi_value) -> napi_status;
714}
715extern "C" {
716 pub fn napi_create_array(env: napi_env, result: *mut napi_value) -> napi_status;
717}
718extern "C" {
719 pub fn napi_create_array_with_length(
720 env: napi_env,
721 length: size_t,
722 result: *mut napi_value,
723 ) -> napi_status;
724}
725extern "C" {
726 pub fn napi_create_double(env: napi_env, value: f64, result: *mut napi_value) -> napi_status;
727}
728extern "C" {
729 pub fn napi_create_int32(env: napi_env, value: i32, result: *mut napi_value) -> napi_status;
730}
731extern "C" {
732 pub fn napi_create_uint32(env: napi_env, value: u32, result: *mut napi_value) -> napi_status;
733}
734extern "C" {
735 pub fn napi_create_int64(env: napi_env, value: i64, result: *mut napi_value) -> napi_status;
736}
737extern "C" {
738 pub fn napi_create_string_latin1(
739 env: napi_env,
740 str_: *const ::std::os::raw::c_char,
741 length: size_t,
742 result: *mut napi_value,
743 ) -> napi_status;
744}
745extern "C" {
746 pub fn napi_create_string_utf8(
747 env: napi_env,
748 str_: *const ::std::os::raw::c_char,
749 length: size_t,
750 result: *mut napi_value,
751 ) -> napi_status;
752}
753extern "C" {
754 pub fn napi_create_string_utf16(
755 env: napi_env,
756 str_: *const char16_t,
757 length: size_t,
758 result: *mut napi_value,
759 ) -> napi_status;
760}
761extern "C" {
762 pub fn napi_create_symbol(
763 env: napi_env,
764 description: napi_value,
765 result: *mut napi_value,
766 ) -> napi_status;
767}
768extern "C" {
769 pub fn napi_create_function(
770 env: napi_env,
771 utf8name: *const ::std::os::raw::c_char,
772 length: size_t,
773 cb: napi_callback,
774 data: *mut ::std::os::raw::c_void,
775 result: *mut napi_value,
776 ) -> napi_status;
777}
778extern "C" {
779 pub fn napi_create_error(
780 env: napi_env,
781 code: napi_value,
782 msg: napi_value,
783 result: *mut napi_value,
784 ) -> napi_status;
785}
786extern "C" {
787 pub fn napi_create_type_error(
788 env: napi_env,
789 code: napi_value,
790 msg: napi_value,
791 result: *mut napi_value,
792 ) -> napi_status;
793}
794extern "C" {
795 pub fn napi_create_range_error(
796 env: napi_env,
797 code: napi_value,
798 msg: napi_value,
799 result: *mut napi_value,
800 ) -> napi_status;
801}
802extern "C" {
803 pub fn napi_typeof(
804 env: napi_env,
805 value: napi_value,
806 result: *mut napi_valuetype,
807 ) -> napi_status;
808}
809extern "C" {
810 pub fn napi_get_value_double(env: napi_env, value: napi_value, result: *mut f64)
811 -> napi_status;
812}
813extern "C" {
814 pub fn napi_get_value_int32(env: napi_env, value: napi_value, result: *mut i32) -> napi_status;
815}
816extern "C" {
817 pub fn napi_get_value_uint32(env: napi_env, value: napi_value, result: *mut u32)
818 -> napi_status;
819}
820extern "C" {
821 pub fn napi_get_value_int64(env: napi_env, value: napi_value, result: *mut i64) -> napi_status;
822}
823extern "C" {
824 pub fn napi_get_value_bool(env: napi_env, value: napi_value, result: *mut bool) -> napi_status;
825}
826extern "C" {
827 pub fn napi_get_value_string_latin1(
828 env: napi_env,
829 value: napi_value,
830 buf: *mut ::std::os::raw::c_char,
831 bufsize: size_t,
832 result: *mut size_t,
833 ) -> napi_status;
834}
835extern "C" {
836 pub fn napi_get_value_string_utf8(
837 env: napi_env,
838 value: napi_value,
839 buf: *mut ::std::os::raw::c_char,
840 bufsize: size_t,
841 result: *mut size_t,
842 ) -> napi_status;
843}
844extern "C" {
845 pub fn napi_get_value_string_utf16(
846 env: napi_env,
847 value: napi_value,
848 buf: *mut char16_t,
849 bufsize: size_t,
850 result: *mut size_t,
851 ) -> napi_status;
852}
853extern "C" {
854 pub fn napi_coerce_to_bool(
855 env: napi_env,
856 value: napi_value,
857 result: *mut napi_value,
858 ) -> napi_status;
859}
860extern "C" {
861 pub fn napi_coerce_to_number(
862 env: napi_env,
863 value: napi_value,
864 result: *mut napi_value,
865 ) -> napi_status;
866}
867extern "C" {
868 pub fn napi_coerce_to_object(
869 env: napi_env,
870 value: napi_value,
871 result: *mut napi_value,
872 ) -> napi_status;
873}
874extern "C" {
875 pub fn napi_coerce_to_string(
876 env: napi_env,
877 value: napi_value,
878 result: *mut napi_value,
879 ) -> napi_status;
880}
881extern "C" {
882 pub fn napi_get_prototype(
883 env: napi_env,
884 object: napi_value,
885 result: *mut napi_value,
886 ) -> napi_status;
887}
888extern "C" {
889 pub fn napi_get_property_names(
890 env: napi_env,
891 object: napi_value,
892 result: *mut napi_value,
893 ) -> napi_status;
894}
895extern "C" {
896 pub fn napi_set_property(
897 env: napi_env,
898 object: napi_value,
899 key: napi_value,
900 value: napi_value,
901 ) -> napi_status;
902}
903extern "C" {
904 pub fn napi_has_property(
905 env: napi_env,
906 object: napi_value,
907 key: napi_value,
908 result: *mut bool,
909 ) -> napi_status;
910}
911extern "C" {
912 pub fn napi_get_property(
913 env: napi_env,
914 object: napi_value,
915 key: napi_value,
916 result: *mut napi_value,
917 ) -> napi_status;
918}
919extern "C" {
920 pub fn napi_delete_property(
921 env: napi_env,
922 object: napi_value,
923 key: napi_value,
924 result: *mut bool,
925 ) -> napi_status;
926}
927extern "C" {
928 pub fn napi_has_own_property(
929 env: napi_env,
930 object: napi_value,
931 key: napi_value,
932 result: *mut bool,
933 ) -> napi_status;
934}
935extern "C" {
936 pub fn napi_set_named_property(
937 env: napi_env,
938 object: napi_value,
939 utf8name: *const ::std::os::raw::c_char,
940 value: napi_value,
941 ) -> napi_status;
942}
943extern "C" {
944 pub fn napi_has_named_property(
945 env: napi_env,
946 object: napi_value,
947 utf8name: *const ::std::os::raw::c_char,
948 result: *mut bool,
949 ) -> napi_status;
950}
951extern "C" {
952 pub fn napi_get_named_property(
953 env: napi_env,
954 object: napi_value,
955 utf8name: *const ::std::os::raw::c_char,
956 result: *mut napi_value,
957 ) -> napi_status;
958}
959extern "C" {
960 pub fn napi_set_element(
961 env: napi_env,
962 object: napi_value,
963 index: u32,
964 value: napi_value,
965 ) -> napi_status;
966}
967extern "C" {
968 pub fn napi_has_element(
969 env: napi_env,
970 object: napi_value,
971 index: u32,
972 result: *mut bool,
973 ) -> napi_status;
974}
975extern "C" {
976 pub fn napi_get_element(
977 env: napi_env,
978 object: napi_value,
979 index: u32,
980 result: *mut napi_value,
981 ) -> napi_status;
982}
983extern "C" {
984 pub fn napi_delete_element(
985 env: napi_env,
986 object: napi_value,
987 index: u32,
988 result: *mut bool,
989 ) -> napi_status;
990}
991extern "C" {
992 pub fn napi_define_properties(
993 env: napi_env,
994 object: napi_value,
995 property_count: size_t,
996 properties: *const napi_property_descriptor,
997 ) -> napi_status;
998}
999extern "C" {
1000 pub fn napi_is_array(env: napi_env, value: napi_value, result: *mut bool) -> napi_status;
1001}
1002extern "C" {
1003 pub fn napi_get_array_length(env: napi_env, value: napi_value, result: *mut u32)
1004 -> napi_status;
1005}
1006extern "C" {
1007 pub fn napi_strict_equals(
1008 env: napi_env,
1009 lhs: napi_value,
1010 rhs: napi_value,
1011 result: *mut bool,
1012 ) -> napi_status;
1013}
1014extern "C" {
1015 pub fn napi_call_function(
1016 env: napi_env,
1017 recv: napi_value,
1018 func: napi_value,
1019 argc: size_t,
1020 argv: *const napi_value,
1021 result: *mut napi_value,
1022 ) -> napi_status;
1023}
1024extern "C" {
1025 pub fn napi_new_instance(
1026 env: napi_env,
1027 constructor: napi_value,
1028 argc: size_t,
1029 argv: *const napi_value,
1030 result: *mut napi_value,
1031 ) -> napi_status;
1032}
1033extern "C" {
1034 pub fn napi_instanceof(
1035 env: napi_env,
1036 object: napi_value,
1037 constructor: napi_value,
1038 result: *mut bool,
1039 ) -> napi_status;
1040}
1041extern "C" {
1042 pub fn napi_get_cb_info(
1043 env: napi_env,
1044 cbinfo: napi_callback_info,
1045 argc: *mut size_t,
1046 argv: *mut napi_value,
1047 this_arg: *mut napi_value,
1048 data: *mut *mut ::std::os::raw::c_void,
1049 ) -> napi_status;
1050}
1051extern "C" {
1052 pub fn napi_get_new_target(
1053 env: napi_env,
1054 cbinfo: napi_callback_info,
1055 result: *mut napi_value,
1056 ) -> napi_status;
1057}
1058extern "C" {
1059 pub fn napi_define_class(
1060 env: napi_env,
1061 utf8name: *const ::std::os::raw::c_char,
1062 length: size_t,
1063 constructor: napi_callback,
1064 data: *mut ::std::os::raw::c_void,
1065 property_count: size_t,
1066 properties: *const napi_property_descriptor,
1067 result: *mut napi_value,
1068 ) -> napi_status;
1069}
1070extern "C" {
1071 pub fn napi_wrap(
1072 env: napi_env,
1073 js_object: napi_value,
1074 native_object: *mut ::std::os::raw::c_void,
1075 finalize_cb: napi_finalize,
1076 finalize_hint: *mut ::std::os::raw::c_void,
1077 result: *mut napi_ref,
1078 ) -> napi_status;
1079}
1080extern "C" {
1081 pub fn napi_unwrap(
1082 env: napi_env,
1083 js_object: napi_value,
1084 result: *mut *mut ::std::os::raw::c_void,
1085 ) -> napi_status;
1086}
1087extern "C" {
1088 pub fn napi_remove_wrap(
1089 env: napi_env,
1090 js_object: napi_value,
1091 result: *mut *mut ::std::os::raw::c_void,
1092 ) -> napi_status;
1093}
1094extern "C" {
1095 pub fn napi_create_external(
1096 env: napi_env,
1097 data: *mut ::std::os::raw::c_void,
1098 finalize_cb: napi_finalize,
1099 finalize_hint: *mut ::std::os::raw::c_void,
1100 result: *mut napi_value,
1101 ) -> napi_status;
1102}
1103extern "C" {
1104 pub fn napi_get_value_external(
1105 env: napi_env,
1106 value: napi_value,
1107 result: *mut *mut ::std::os::raw::c_void,
1108 ) -> napi_status;
1109}
1110extern "C" {
1111 pub fn napi_create_reference(
1112 env: napi_env,
1113 value: napi_value,
1114 initial_refcount: u32,
1115 result: *mut napi_ref,
1116 ) -> napi_status;
1117}
1118extern "C" {
1119 pub fn napi_delete_reference(env: napi_env, ref_: napi_ref) -> napi_status;
1120}
1121extern "C" {
1122 pub fn napi_reference_ref(env: napi_env, ref_: napi_ref, result: *mut u32) -> napi_status;
1123}
1124extern "C" {
1125 pub fn napi_reference_unref(env: napi_env, ref_: napi_ref, result: *mut u32) -> napi_status;
1126}
1127extern "C" {
1128 pub fn napi_get_reference_value(
1129 env: napi_env,
1130 ref_: napi_ref,
1131 result: *mut napi_value,
1132 ) -> napi_status;
1133}
1134extern "C" {
1135 pub fn napi_open_handle_scope(env: napi_env, result: *mut napi_handle_scope) -> napi_status;
1136}
1137extern "C" {
1138 pub fn napi_close_handle_scope(env: napi_env, scope: napi_handle_scope) -> napi_status;
1139}
1140extern "C" {
1141 pub fn napi_open_escapable_handle_scope(
1142 env: napi_env,
1143 result: *mut napi_escapable_handle_scope,
1144 ) -> napi_status;
1145}
1146extern "C" {
1147 pub fn napi_close_escapable_handle_scope(
1148 env: napi_env,
1149 scope: napi_escapable_handle_scope,
1150 ) -> napi_status;
1151}
1152extern "C" {
1153 pub fn napi_escape_handle(
1154 env: napi_env,
1155 scope: napi_escapable_handle_scope,
1156 escapee: napi_value,
1157 result: *mut napi_value,
1158 ) -> napi_status;
1159}
1160extern "C" {
1161 pub fn napi_throw(env: napi_env, error: napi_value) -> napi_status;
1162}
1163extern "C" {
1164 pub fn napi_throw_error(
1165 env: napi_env,
1166 code: *const ::std::os::raw::c_char,
1167 msg: *const ::std::os::raw::c_char,
1168 ) -> napi_status;
1169}
1170extern "C" {
1171 pub fn napi_throw_type_error(
1172 env: napi_env,
1173 code: *const ::std::os::raw::c_char,
1174 msg: *const ::std::os::raw::c_char,
1175 ) -> napi_status;
1176}
1177extern "C" {
1178 pub fn napi_throw_range_error(
1179 env: napi_env,
1180 code: *const ::std::os::raw::c_char,
1181 msg: *const ::std::os::raw::c_char,
1182 ) -> napi_status;
1183}
1184extern "C" {
1185 pub fn napi_is_error(env: napi_env, value: napi_value, result: *mut bool) -> napi_status;
1186}
1187extern "C" {
1188 pub fn napi_is_exception_pending(env: napi_env, result: *mut bool) -> napi_status;
1189}
1190extern "C" {
1191 pub fn napi_get_and_clear_last_exception(env: napi_env, result: *mut napi_value)
1192 -> napi_status;
1193}
1194extern "C" {
1195 pub fn napi_is_arraybuffer(env: napi_env, value: napi_value, result: *mut bool) -> napi_status;
1196}
1197extern "C" {
1198 pub fn napi_create_arraybuffer(
1199 env: napi_env,
1200 byte_length: size_t,
1201 data: *mut *mut ::std::os::raw::c_void,
1202 result: *mut napi_value,
1203 ) -> napi_status;
1204}
1205extern "C" {
1206 pub fn napi_create_external_arraybuffer(
1207 env: napi_env,
1208 external_data: *mut ::std::os::raw::c_void,
1209 byte_length: size_t,
1210 finalize_cb: napi_finalize,
1211 finalize_hint: *mut ::std::os::raw::c_void,
1212 result: *mut napi_value,
1213 ) -> napi_status;
1214}
1215extern "C" {
1216 pub fn napi_get_arraybuffer_info(
1217 env: napi_env,
1218 arraybuffer: napi_value,
1219 data: *mut *mut ::std::os::raw::c_void,
1220 byte_length: *mut size_t,
1221 ) -> napi_status;
1222}
1223extern "C" {
1224 pub fn napi_is_typedarray(env: napi_env, value: napi_value, result: *mut bool) -> napi_status;
1225}
1226extern "C" {
1227 pub fn napi_create_typedarray(
1228 env: napi_env,
1229 type_: napi_typedarray_type,
1230 length: size_t,
1231 arraybuffer: napi_value,
1232 byte_offset: size_t,
1233 result: *mut napi_value,
1234 ) -> napi_status;
1235}
1236extern "C" {
1237 pub fn napi_get_typedarray_info(
1238 env: napi_env,
1239 typedarray: napi_value,
1240 type_: *mut napi_typedarray_type,
1241 length: *mut size_t,
1242 data: *mut *mut ::std::os::raw::c_void,
1243 arraybuffer: *mut napi_value,
1244 byte_offset: *mut size_t,
1245 ) -> napi_status;
1246}
1247extern "C" {
1248 pub fn napi_create_dataview(
1249 env: napi_env,
1250 length: size_t,
1251 arraybuffer: napi_value,
1252 byte_offset: size_t,
1253 result: *mut napi_value,
1254 ) -> napi_status;
1255}
1256extern "C" {
1257 pub fn napi_is_dataview(env: napi_env, value: napi_value, result: *mut bool) -> napi_status;
1258}
1259extern "C" {
1260 pub fn napi_get_dataview_info(
1261 env: napi_env,
1262 dataview: napi_value,
1263 bytelength: *mut size_t,
1264 data: *mut *mut ::std::os::raw::c_void,
1265 arraybuffer: *mut napi_value,
1266 byte_offset: *mut size_t,
1267 ) -> napi_status;
1268}
1269extern "C" {
1270 pub fn napi_get_version(env: napi_env, result: *mut u32) -> napi_status;
1271}
1272extern "C" {
1273 pub fn napi_create_promise(
1274 env: napi_env,
1275 deferred: *mut napi_deferred,
1276 promise: *mut napi_value,
1277 ) -> napi_status;
1278}
1279extern "C" {
1280 pub fn napi_resolve_deferred(
1281 env: napi_env,
1282 deferred: napi_deferred,
1283 resolution: napi_value,
1284 ) -> napi_status;
1285}
1286extern "C" {
1287 pub fn napi_reject_deferred(
1288 env: napi_env,
1289 deferred: napi_deferred,
1290 rejection: napi_value,
1291 ) -> napi_status;
1292}
1293extern "C" {
1294 pub fn napi_is_promise(env: napi_env, value: napi_value, is_promise: *mut bool) -> napi_status;
1295}
1296extern "C" {
1297 pub fn napi_run_script(
1298 env: napi_env,
1299 script: napi_value,
1300 result: *mut napi_value,
1301 ) -> napi_status;
1302}
1303extern "C" {
1304 pub fn napi_adjust_external_memory(
1305 env: napi_env,
1306 change_in_bytes: i64,
1307 adjusted_value: *mut i64,
1308 ) -> napi_status;
1309}
1310extern "C" {
1311 pub fn napi_create_date(env: napi_env, time: f64, result: *mut napi_value) -> napi_status;
1312}
1313extern "C" {
1314 pub fn napi_is_date(env: napi_env, value: napi_value, is_date: *mut bool) -> napi_status;
1315}
1316extern "C" {
1317 pub fn napi_get_date_value(env: napi_env, value: napi_value, result: *mut f64) -> napi_status;
1318}
1319extern "C" {
1320 pub fn napi_add_finalizer(
1321 env: napi_env,
1322 js_object: napi_value,
1323 native_object: *mut ::std::os::raw::c_void,
1324 finalize_cb: napi_finalize,
1325 finalize_hint: *mut ::std::os::raw::c_void,
1326 result: *mut napi_ref,
1327 ) -> napi_status;
1328}
1329extern "C" {
1330 pub fn napi_create_bigint_int64(
1331 env: napi_env,
1332 value: i64,
1333 result: *mut napi_value,
1334 ) -> napi_status;
1335}
1336extern "C" {
1337 pub fn napi_create_bigint_uint64(
1338 env: napi_env,
1339 value: u64,
1340 result: *mut napi_value,
1341 ) -> napi_status;
1342}
1343extern "C" {
1344 pub fn napi_create_bigint_words(
1345 env: napi_env,
1346 sign_bit: ::std::os::raw::c_int,
1347 word_count: size_t,
1348 words: *const u64,
1349 result: *mut napi_value,
1350 ) -> napi_status;
1351}
1352extern "C" {
1353 pub fn napi_get_value_bigint_int64(
1354 env: napi_env,
1355 value: napi_value,
1356 result: *mut i64,
1357 lossless: *mut bool,
1358 ) -> napi_status;
1359}
1360extern "C" {
1361 pub fn napi_get_value_bigint_uint64(
1362 env: napi_env,
1363 value: napi_value,
1364 result: *mut u64,
1365 lossless: *mut bool,
1366 ) -> napi_status;
1367}
1368extern "C" {
1369 pub fn napi_get_value_bigint_words(
1370 env: napi_env,
1371 value: napi_value,
1372 sign_bit: *mut ::std::os::raw::c_int,
1373 word_count: *mut size_t,
1374 words: *mut u64,
1375 ) -> napi_status;
1376}
1377extern "C" {
1378 pub fn napi_get_all_property_names(
1379 env: napi_env,
1380 object: napi_value,
1381 key_mode: napi_key_collection_mode,
1382 key_filter: napi_key_filter,
1383 key_conversion: napi_key_conversion,
1384 result: *mut napi_value,
1385 ) -> napi_status;
1386}
1387extern "C" {
1388 pub fn napi_set_instance_data(
1389 env: napi_env,
1390 data: *mut ::std::os::raw::c_void,
1391 finalize_cb: napi_finalize,
1392 finalize_hint: *mut ::std::os::raw::c_void,
1393 ) -> napi_status;
1394}
1395extern "C" {
1396 pub fn napi_get_instance_data(
1397 env: napi_env,
1398 data: *mut *mut ::std::os::raw::c_void,
1399 ) -> napi_status;
1400}
1401extern "C" {
1402 pub fn napi_detach_arraybuffer(env: napi_env, arraybuffer: napi_value) -> napi_status;
1403}
1404extern "C" {
1405 pub fn napi_is_detached_arraybuffer(
1406 env: napi_env,
1407 value: napi_value,
1408 result: *mut bool,
1409 ) -> napi_status;
1410}
1411extern "C" {
1412 pub fn napi_type_tag_object(
1413 env: napi_env,
1414 value: napi_value,
1415 type_tag: *const napi_type_tag,
1416 ) -> napi_status;
1417}
1418extern "C" {
1419 pub fn napi_check_object_type_tag(
1420 env: napi_env,
1421 value: napi_value,
1422 type_tag: *const napi_type_tag,
1423 result: *mut bool,
1424 ) -> napi_status;
1425}
1426extern "C" {
1427 pub fn napi_object_freeze(env: napi_env, object: napi_value) -> napi_status;
1428}
1429extern "C" {
1430 pub fn napi_object_seal(env: napi_env, object: napi_value) -> napi_status;
1431}
1432#[repr(C)]
1433#[derive(Debug, Copy, Clone)]
1434pub struct napi_callback_scope__ {
1435 _unused: [u8; 0],
1436}
1437pub type napi_callback_scope = *mut napi_callback_scope__;
1438#[repr(C)]
1439#[derive(Debug, Copy, Clone)]
1440pub struct napi_async_context__ {
1441 _unused: [u8; 0],
1442}
1443pub type napi_async_context = *mut napi_async_context__;
1444#[repr(C)]
1445#[derive(Debug, Copy, Clone)]
1446pub struct napi_async_work__ {
1447 _unused: [u8; 0],
1448}
1449pub type napi_async_work = *mut napi_async_work__;
1450#[repr(C)]
1451#[derive(Debug, Copy, Clone)]
1452pub struct napi_threadsafe_function__ {
1453 _unused: [u8; 0],
1454}
1455pub type napi_threadsafe_function = *mut napi_threadsafe_function__;
1456#[repr(u32)]
1457#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
1458pub enum napi_threadsafe_function_release_mode {
1459 napi_tsfn_release = 0,
1460 napi_tsfn_abort = 1,
1461}
1462#[repr(u32)]
1463#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
1464pub enum napi_threadsafe_function_call_mode {
1465 napi_tsfn_nonblocking = 0,
1466 napi_tsfn_blocking = 1,
1467}
1468pub type napi_async_execute_callback =
1469 ::std::option::Option<unsafe extern "C" fn(env: napi_env, data: *mut ::std::os::raw::c_void)>;
1470pub type napi_async_complete_callback = ::std::option::Option<
1471 unsafe extern "C" fn(env: napi_env, status: napi_status, data: *mut ::std::os::raw::c_void),
1472>;
1473pub type napi_threadsafe_function_call_js = ::std::option::Option<
1474 unsafe extern "C" fn(
1475 env: napi_env,
1476 js_callback: napi_value,
1477 context: *mut ::std::os::raw::c_void,
1478 data: *mut ::std::os::raw::c_void,
1479 ),
1480>;
1481#[repr(C)]
1482#[derive(Debug, Copy, Clone)]
1483pub struct napi_node_version {
1484 pub major: u32,
1485 pub minor: u32,
1486 pub patch: u32,
1487 pub release: *const ::std::os::raw::c_char,
1488}
1489#[test]
1490fn bindgen_test_layout_napi_node_version() {
1491 assert_eq!(
1492 ::std::mem::size_of::<napi_node_version>(),
1493 24usize,
1494 concat!("Size of: ", stringify!(napi_node_version))
1495 );
1496 assert_eq!(
1497 ::std::mem::align_of::<napi_node_version>(),
1498 8usize,
1499 concat!("Alignment of ", stringify!(napi_node_version))
1500 );
1501 assert_eq!(
1502 unsafe { &(*(::std::ptr::null::<napi_node_version>())).major as *const _ as usize },
1503 0usize,
1504 concat!(
1505 "Offset of field: ",
1506 stringify!(napi_node_version),
1507 "::",
1508 stringify!(major)
1509 )
1510 );
1511 assert_eq!(
1512 unsafe { &(*(::std::ptr::null::<napi_node_version>())).minor as *const _ as usize },
1513 4usize,
1514 concat!(
1515 "Offset of field: ",
1516 stringify!(napi_node_version),
1517 "::",
1518 stringify!(minor)
1519 )
1520 );
1521 assert_eq!(
1522 unsafe { &(*(::std::ptr::null::<napi_node_version>())).patch as *const _ as usize },
1523 8usize,
1524 concat!(
1525 "Offset of field: ",
1526 stringify!(napi_node_version),
1527 "::",
1528 stringify!(patch)
1529 )
1530 );
1531 assert_eq!(
1532 unsafe { &(*(::std::ptr::null::<napi_node_version>())).release as *const _ as usize },
1533 16usize,
1534 concat!(
1535 "Offset of field: ",
1536 stringify!(napi_node_version),
1537 "::",
1538 stringify!(release)
1539 )
1540 );
1541}
1542impl Default for napi_node_version {
1543 fn default() -> Self {
1544 unsafe { ::std::mem::zeroed() }
1545 }
1546}
1547#[repr(C)]
1548#[derive(Debug, Copy, Clone)]
1549pub struct napi_async_cleanup_hook_handle__ {
1550 _unused: [u8; 0],
1551}
1552pub type napi_async_cleanup_hook_handle = *mut napi_async_cleanup_hook_handle__;
1553pub type napi_async_cleanup_hook = ::std::option::Option<
1554 unsafe extern "C" fn(handle: napi_async_cleanup_hook_handle, data: *mut ::std::os::raw::c_void),
1555>;
1556pub type napi_addon_register_func =
1557 ::std::option::Option<unsafe extern "C" fn(env: napi_env, exports: napi_value) -> napi_value>;
1558#[repr(C)]
1559#[derive(Debug, Copy, Clone)]
1560pub struct napi_module {
1561 pub nm_version: ::std::os::raw::c_int,
1562 pub nm_flags: ::std::os::raw::c_uint,
1563 pub nm_filename: *const ::std::os::raw::c_char,
1564 pub nm_register_func: napi_addon_register_func,
1565 pub nm_modname: *const ::std::os::raw::c_char,
1566 pub nm_priv: *mut ::std::os::raw::c_void,
1567 pub reserved: [*mut ::std::os::raw::c_void; 4usize],
1568}
1569#[test]
1570fn bindgen_test_layout_napi_module() {
1571 assert_eq!(
1572 ::std::mem::size_of::<napi_module>(),
1573 72usize,
1574 concat!("Size of: ", stringify!(napi_module))
1575 );
1576 assert_eq!(
1577 ::std::mem::align_of::<napi_module>(),
1578 8usize,
1579 concat!("Alignment of ", stringify!(napi_module))
1580 );
1581 assert_eq!(
1582 unsafe { &(*(::std::ptr::null::<napi_module>())).nm_version as *const _ as usize },
1583 0usize,
1584 concat!(
1585 "Offset of field: ",
1586 stringify!(napi_module),
1587 "::",
1588 stringify!(nm_version)
1589 )
1590 );
1591 assert_eq!(
1592 unsafe { &(*(::std::ptr::null::<napi_module>())).nm_flags as *const _ as usize },
1593 4usize,
1594 concat!(
1595 "Offset of field: ",
1596 stringify!(napi_module),
1597 "::",
1598 stringify!(nm_flags)
1599 )
1600 );
1601 assert_eq!(
1602 unsafe { &(*(::std::ptr::null::<napi_module>())).nm_filename as *const _ as usize },
1603 8usize,
1604 concat!(
1605 "Offset of field: ",
1606 stringify!(napi_module),
1607 "::",
1608 stringify!(nm_filename)
1609 )
1610 );
1611 assert_eq!(
1612 unsafe { &(*(::std::ptr::null::<napi_module>())).nm_register_func as *const _ as usize },
1613 16usize,
1614 concat!(
1615 "Offset of field: ",
1616 stringify!(napi_module),
1617 "::",
1618 stringify!(nm_register_func)
1619 )
1620 );
1621 assert_eq!(
1622 unsafe { &(*(::std::ptr::null::<napi_module>())).nm_modname as *const _ as usize },
1623 24usize,
1624 concat!(
1625 "Offset of field: ",
1626 stringify!(napi_module),
1627 "::",
1628 stringify!(nm_modname)
1629 )
1630 );
1631 assert_eq!(
1632 unsafe { &(*(::std::ptr::null::<napi_module>())).nm_priv as *const _ as usize },
1633 32usize,
1634 concat!(
1635 "Offset of field: ",
1636 stringify!(napi_module),
1637 "::",
1638 stringify!(nm_priv)
1639 )
1640 );
1641 assert_eq!(
1642 unsafe { &(*(::std::ptr::null::<napi_module>())).reserved as *const _ as usize },
1643 40usize,
1644 concat!(
1645 "Offset of field: ",
1646 stringify!(napi_module),
1647 "::",
1648 stringify!(reserved)
1649 )
1650 );
1651}
1652impl Default for napi_module {
1653 fn default() -> Self {
1654 unsafe { ::std::mem::zeroed() }
1655 }
1656}
1657extern "C" {
1658 pub fn napi_module_register(mod_: *mut napi_module);
1659}
1660extern "C" {
1661 pub fn napi_fatal_error(
1662 location: *const ::std::os::raw::c_char,
1663 location_len: size_t,
1664 message: *const ::std::os::raw::c_char,
1665 message_len: size_t,
1666 );
1667}
1668extern "C" {
1669 pub fn napi_async_init(
1670 env: napi_env,
1671 async_resource: napi_value,
1672 async_resource_name: napi_value,
1673 result: *mut napi_async_context,
1674 ) -> napi_status;
1675}
1676extern "C" {
1677 pub fn napi_async_destroy(env: napi_env, async_context: napi_async_context) -> napi_status;
1678}
1679extern "C" {
1680 pub fn napi_make_callback(
1681 env: napi_env,
1682 async_context: napi_async_context,
1683 recv: napi_value,
1684 func: napi_value,
1685 argc: size_t,
1686 argv: *const napi_value,
1687 result: *mut napi_value,
1688 ) -> napi_status;
1689}
1690extern "C" {
1691 pub fn napi_create_buffer(
1692 env: napi_env,
1693 length: size_t,
1694 data: *mut *mut ::std::os::raw::c_void,
1695 result: *mut napi_value,
1696 ) -> napi_status;
1697}
1698extern "C" {
1699 pub fn napi_create_external_buffer(
1700 env: napi_env,
1701 length: size_t,
1702 data: *mut ::std::os::raw::c_void,
1703 finalize_cb: napi_finalize,
1704 finalize_hint: *mut ::std::os::raw::c_void,
1705 result: *mut napi_value,
1706 ) -> napi_status;
1707}
1708extern "C" {
1709 pub fn napi_create_buffer_copy(
1710 env: napi_env,
1711 length: size_t,
1712 data: *const ::std::os::raw::c_void,
1713 result_data: *mut *mut ::std::os::raw::c_void,
1714 result: *mut napi_value,
1715 ) -> napi_status;
1716}
1717extern "C" {
1718 pub fn napi_is_buffer(env: napi_env, value: napi_value, result: *mut bool) -> napi_status;
1719}
1720extern "C" {
1721 pub fn napi_get_buffer_info(
1722 env: napi_env,
1723 value: napi_value,
1724 data: *mut *mut ::std::os::raw::c_void,
1725 length: *mut size_t,
1726 ) -> napi_status;
1727}
1728extern "C" {
1729 pub fn napi_create_async_work(
1730 env: napi_env,
1731 async_resource: napi_value,
1732 async_resource_name: napi_value,
1733 execute: napi_async_execute_callback,
1734 complete: napi_async_complete_callback,
1735 data: *mut ::std::os::raw::c_void,
1736 result: *mut napi_async_work,
1737 ) -> napi_status;
1738}
1739extern "C" {
1740 pub fn napi_delete_async_work(env: napi_env, work: napi_async_work) -> napi_status;
1741}
1742extern "C" {
1743 pub fn napi_queue_async_work(env: napi_env, work: napi_async_work) -> napi_status;
1744}
1745extern "C" {
1746 pub fn napi_cancel_async_work(env: napi_env, work: napi_async_work) -> napi_status;
1747}
1748extern "C" {
1749 pub fn napi_get_node_version(
1750 env: napi_env,
1751 version: *mut *const napi_node_version,
1752 ) -> napi_status;
1753}
1754extern "C" {
1755 pub fn napi_get_uv_event_loop(env: napi_env, loop_: *mut *mut uv_loop_s) -> napi_status;
1756}
1757extern "C" {
1758 pub fn napi_fatal_exception(env: napi_env, err: napi_value) -> napi_status;
1759}
1760extern "C" {
1761 pub fn napi_add_env_cleanup_hook(
1762 env: napi_env,
1763 fun: ::std::option::Option<unsafe extern "C" fn(arg: *mut ::std::os::raw::c_void)>,
1764 arg: *mut ::std::os::raw::c_void,
1765 ) -> napi_status;
1766}
1767extern "C" {
1768 pub fn napi_remove_env_cleanup_hook(
1769 env: napi_env,
1770 fun: ::std::option::Option<unsafe extern "C" fn(arg: *mut ::std::os::raw::c_void)>,
1771 arg: *mut ::std::os::raw::c_void,
1772 ) -> napi_status;
1773}
1774extern "C" {
1775 pub fn napi_open_callback_scope(
1776 env: napi_env,
1777 resource_object: napi_value,
1778 context: napi_async_context,
1779 result: *mut napi_callback_scope,
1780 ) -> napi_status;
1781}
1782extern "C" {
1783 pub fn napi_close_callback_scope(env: napi_env, scope: napi_callback_scope) -> napi_status;
1784}
1785extern "C" {
1786 pub fn napi_create_threadsafe_function(
1787 env: napi_env,
1788 func: napi_value,
1789 async_resource: napi_value,
1790 async_resource_name: napi_value,
1791 max_queue_size: size_t,
1792 initial_thread_count: size_t,
1793 thread_finalize_data: *mut ::std::os::raw::c_void,
1794 thread_finalize_cb: napi_finalize,
1795 context: *mut ::std::os::raw::c_void,
1796 call_js_cb: napi_threadsafe_function_call_js,
1797 result: *mut napi_threadsafe_function,
1798 ) -> napi_status;
1799}
1800extern "C" {
1801 pub fn napi_get_threadsafe_function_context(
1802 func: napi_threadsafe_function,
1803 result: *mut *mut ::std::os::raw::c_void,
1804 ) -> napi_status;
1805}
1806extern "C" {
1807 pub fn napi_call_threadsafe_function(
1808 func: napi_threadsafe_function,
1809 data: *mut ::std::os::raw::c_void,
1810 is_blocking: napi_threadsafe_function_call_mode,
1811 ) -> napi_status;
1812}
1813extern "C" {
1814 pub fn napi_acquire_threadsafe_function(func: napi_threadsafe_function) -> napi_status;
1815}
1816extern "C" {
1817 pub fn napi_release_threadsafe_function(
1818 func: napi_threadsafe_function,
1819 mode: napi_threadsafe_function_release_mode,
1820 ) -> napi_status;
1821}
1822extern "C" {
1823 pub fn napi_unref_threadsafe_function(
1824 env: napi_env,
1825 func: napi_threadsafe_function,
1826 ) -> napi_status;
1827}
1828extern "C" {
1829 pub fn napi_ref_threadsafe_function(
1830 env: napi_env,
1831 func: napi_threadsafe_function,
1832 ) -> napi_status;
1833}
1834extern "C" {
1835 pub fn napi_add_async_cleanup_hook(
1836 env: napi_env,
1837 hook: napi_async_cleanup_hook,
1838 arg: *mut ::std::os::raw::c_void,
1839 remove_handle: *mut napi_async_cleanup_hook_handle,
1840 ) -> napi_status;
1841}
1842extern "C" {
1843 pub fn napi_remove_async_cleanup_hook(
1844 remove_handle: napi_async_cleanup_hook_handle,
1845 ) -> napi_status;
1846}
1847pub type fpos_t = __darwin_off_t;
1848#[repr(C)]
1849#[derive(Debug, Copy, Clone)]
1850pub struct __sbuf {
1851 pub _base: *mut ::std::os::raw::c_uchar,
1852 pub _size: ::std::os::raw::c_int,
1853}
1854#[test]
1855fn bindgen_test_layout___sbuf() {
1856 assert_eq!(
1857 ::std::mem::size_of::<__sbuf>(),
1858 16usize,
1859 concat!("Size of: ", stringify!(__sbuf))
1860 );
1861 assert_eq!(
1862 ::std::mem::align_of::<__sbuf>(),
1863 8usize,
1864 concat!("Alignment of ", stringify!(__sbuf))
1865 );
1866 assert_eq!(
1867 unsafe { &(*(::std::ptr::null::<__sbuf>()))._base as *const _ as usize },
1868 0usize,
1869 concat!(
1870 "Offset of field: ",
1871 stringify!(__sbuf),
1872 "::",
1873 stringify!(_base)
1874 )
1875 );
1876 assert_eq!(
1877 unsafe { &(*(::std::ptr::null::<__sbuf>()))._size as *const _ as usize },
1878 8usize,
1879 concat!(
1880 "Offset of field: ",
1881 stringify!(__sbuf),
1882 "::",
1883 stringify!(_size)
1884 )
1885 );
1886}
1887impl Default for __sbuf {
1888 fn default() -> Self {
1889 unsafe { ::std::mem::zeroed() }
1890 }
1891}
1892#[repr(C)]
1893#[derive(Debug, Copy, Clone)]
1894pub struct __sFILEX {
1895 _unused: [u8; 0],
1896}
1897#[repr(C)]
1898#[derive(Debug, Copy, Clone)]
1899pub struct __sFILE {
1900 pub _p: *mut ::std::os::raw::c_uchar,
1901 pub _r: ::std::os::raw::c_int,
1902 pub _w: ::std::os::raw::c_int,
1903 pub _flags: ::std::os::raw::c_short,
1904 pub _file: ::std::os::raw::c_short,
1905 pub _bf: __sbuf,
1906 pub _lbfsize: ::std::os::raw::c_int,
1907 pub _cookie: *mut ::std::os::raw::c_void,
1908 pub _close: ::std::option::Option<
1909 unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void) -> ::std::os::raw::c_int,
1910 >,
1911 pub _read: ::std::option::Option<
1912 unsafe extern "C" fn(
1913 arg1: *mut ::std::os::raw::c_void,
1914 arg2: *mut ::std::os::raw::c_char,
1915 arg3: ::std::os::raw::c_int,
1916 ) -> ::std::os::raw::c_int,
1917 >,
1918 pub _seek: ::std::option::Option<
1919 unsafe extern "C" fn(
1920 arg1: *mut ::std::os::raw::c_void,
1921 arg2: fpos_t,
1922 arg3: ::std::os::raw::c_int,
1923 ) -> fpos_t,
1924 >,
1925 pub _write: ::std::option::Option<
1926 unsafe extern "C" fn(
1927 arg1: *mut ::std::os::raw::c_void,
1928 arg2: *const ::std::os::raw::c_char,
1929 arg3: ::std::os::raw::c_int,
1930 ) -> ::std::os::raw::c_int,
1931 >,
1932 pub _ub: __sbuf,
1933 pub _extra: *mut __sFILEX,
1934 pub _ur: ::std::os::raw::c_int,
1935 pub _ubuf: [::std::os::raw::c_uchar; 3usize],
1936 pub _nbuf: [::std::os::raw::c_uchar; 1usize],
1937 pub _lb: __sbuf,
1938 pub _blksize: ::std::os::raw::c_int,
1939 pub _offset: fpos_t,
1940}
1941#[test]
1942fn bindgen_test_layout___sFILE() {
1943 assert_eq!(
1944 ::std::mem::size_of::<__sFILE>(),
1945 152usize,
1946 concat!("Size of: ", stringify!(__sFILE))
1947 );
1948 assert_eq!(
1949 ::std::mem::align_of::<__sFILE>(),
1950 8usize,
1951 concat!("Alignment of ", stringify!(__sFILE))
1952 );
1953 assert_eq!(
1954 unsafe { &(*(::std::ptr::null::<__sFILE>()))._p as *const _ as usize },
1955 0usize,
1956 concat!(
1957 "Offset of field: ",
1958 stringify!(__sFILE),
1959 "::",
1960 stringify!(_p)
1961 )
1962 );
1963 assert_eq!(
1964 unsafe { &(*(::std::ptr::null::<__sFILE>()))._r as *const _ as usize },
1965 8usize,
1966 concat!(
1967 "Offset of field: ",
1968 stringify!(__sFILE),
1969 "::",
1970 stringify!(_r)
1971 )
1972 );
1973 assert_eq!(
1974 unsafe { &(*(::std::ptr::null::<__sFILE>()))._w as *const _ as usize },
1975 12usize,
1976 concat!(
1977 "Offset of field: ",
1978 stringify!(__sFILE),
1979 "::",
1980 stringify!(_w)
1981 )
1982 );
1983 assert_eq!(
1984 unsafe { &(*(::std::ptr::null::<__sFILE>()))._flags as *const _ as usize },
1985 16usize,
1986 concat!(
1987 "Offset of field: ",
1988 stringify!(__sFILE),
1989 "::",
1990 stringify!(_flags)
1991 )
1992 );
1993 assert_eq!(
1994 unsafe { &(*(::std::ptr::null::<__sFILE>()))._file as *const _ as usize },
1995 18usize,
1996 concat!(
1997 "Offset of field: ",
1998 stringify!(__sFILE),
1999 "::",
2000 stringify!(_file)
2001 )
2002 );
2003 assert_eq!(
2004 unsafe { &(*(::std::ptr::null::<__sFILE>()))._bf as *const _ as usize },
2005 24usize,
2006 concat!(
2007 "Offset of field: ",
2008 stringify!(__sFILE),
2009 "::",
2010 stringify!(_bf)
2011 )
2012 );
2013 assert_eq!(
2014 unsafe { &(*(::std::ptr::null::<__sFILE>()))._lbfsize as *const _ as usize },
2015 40usize,
2016 concat!(
2017 "Offset of field: ",
2018 stringify!(__sFILE),
2019 "::",
2020 stringify!(_lbfsize)
2021 )
2022 );
2023 assert_eq!(
2024 unsafe { &(*(::std::ptr::null::<__sFILE>()))._cookie as *const _ as usize },
2025 48usize,
2026 concat!(
2027 "Offset of field: ",
2028 stringify!(__sFILE),
2029 "::",
2030 stringify!(_cookie)
2031 )
2032 );
2033 assert_eq!(
2034 unsafe { &(*(::std::ptr::null::<__sFILE>()))._close as *const _ as usize },
2035 56usize,
2036 concat!(
2037 "Offset of field: ",
2038 stringify!(__sFILE),
2039 "::",
2040 stringify!(_close)
2041 )
2042 );
2043 assert_eq!(
2044 unsafe { &(*(::std::ptr::null::<__sFILE>()))._read as *const _ as usize },
2045 64usize,
2046 concat!(
2047 "Offset of field: ",
2048 stringify!(__sFILE),
2049 "::",
2050 stringify!(_read)
2051 )
2052 );
2053 assert_eq!(
2054 unsafe { &(*(::std::ptr::null::<__sFILE>()))._seek as *const _ as usize },
2055 72usize,
2056 concat!(
2057 "Offset of field: ",
2058 stringify!(__sFILE),
2059 "::",
2060 stringify!(_seek)
2061 )
2062 );
2063 assert_eq!(
2064 unsafe { &(*(::std::ptr::null::<__sFILE>()))._write as *const _ as usize },
2065 80usize,
2066 concat!(
2067 "Offset of field: ",
2068 stringify!(__sFILE),
2069 "::",
2070 stringify!(_write)
2071 )
2072 );
2073 assert_eq!(
2074 unsafe { &(*(::std::ptr::null::<__sFILE>()))._ub as *const _ as usize },
2075 88usize,
2076 concat!(
2077 "Offset of field: ",
2078 stringify!(__sFILE),
2079 "::",
2080 stringify!(_ub)
2081 )
2082 );
2083 assert_eq!(
2084 unsafe { &(*(::std::ptr::null::<__sFILE>()))._extra as *const _ as usize },
2085 104usize,
2086 concat!(
2087 "Offset of field: ",
2088 stringify!(__sFILE),
2089 "::",
2090 stringify!(_extra)
2091 )
2092 );
2093 assert_eq!(
2094 unsafe { &(*(::std::ptr::null::<__sFILE>()))._ur as *const _ as usize },
2095 112usize,
2096 concat!(
2097 "Offset of field: ",
2098 stringify!(__sFILE),
2099 "::",
2100 stringify!(_ur)
2101 )
2102 );
2103 assert_eq!(
2104 unsafe { &(*(::std::ptr::null::<__sFILE>()))._ubuf as *const _ as usize },
2105 116usize,
2106 concat!(
2107 "Offset of field: ",
2108 stringify!(__sFILE),
2109 "::",
2110 stringify!(_ubuf)
2111 )
2112 );
2113 assert_eq!(
2114 unsafe { &(*(::std::ptr::null::<__sFILE>()))._nbuf as *const _ as usize },
2115 119usize,
2116 concat!(
2117 "Offset of field: ",
2118 stringify!(__sFILE),
2119 "::",
2120 stringify!(_nbuf)
2121 )
2122 );
2123 assert_eq!(
2124 unsafe { &(*(::std::ptr::null::<__sFILE>()))._lb as *const _ as usize },
2125 120usize,
2126 concat!(
2127 "Offset of field: ",
2128 stringify!(__sFILE),
2129 "::",
2130 stringify!(_lb)
2131 )
2132 );
2133 assert_eq!(
2134 unsafe { &(*(::std::ptr::null::<__sFILE>()))._blksize as *const _ as usize },
2135 136usize,
2136 concat!(
2137 "Offset of field: ",
2138 stringify!(__sFILE),
2139 "::",
2140 stringify!(_blksize)
2141 )
2142 );
2143 assert_eq!(
2144 unsafe { &(*(::std::ptr::null::<__sFILE>()))._offset as *const _ as usize },
2145 144usize,
2146 concat!(
2147 "Offset of field: ",
2148 stringify!(__sFILE),
2149 "::",
2150 stringify!(_offset)
2151 )
2152 );
2153}
2154impl Default for __sFILE {
2155 fn default() -> Self {
2156 unsafe { ::std::mem::zeroed() }
2157 }
2158}
2159pub type FILE = __sFILE;
2160pub type off_t = __darwin_off_t;
2161pub type ssize_t = __darwin_ssize_t;
2162pub type gid_t = __darwin_gid_t;
2163pub type in_addr_t = __uint32_t;
2164pub type in_port_t = __uint16_t;
2165pub type mode_t = __darwin_mode_t;
2166pub type pid_t = __darwin_pid_t;
2167pub type uid_t = __darwin_uid_t;
2168pub type pthread_cond_t = __darwin_pthread_cond_t;
2169pub type pthread_mutex_t = __darwin_pthread_mutex_t;
2170pub type pthread_once_t = __darwin_pthread_once_t;
2171pub type pthread_rwlock_t = __darwin_pthread_rwlock_t;
2172pub type pthread_t = __darwin_pthread_t;
2173pub type pthread_key_t = __darwin_pthread_key_t;
2174#[repr(C)]
2175#[derive(Copy, Clone)]
2176pub struct dirent {
2177 pub d_ino: __uint64_t,
2178 pub d_seekoff: __uint64_t,
2179 pub d_reclen: __uint16_t,
2180 pub d_namlen: __uint16_t,
2181 pub d_type: __uint8_t,
2182 pub d_name: [::std::os::raw::c_char; 1024usize],
2183}
2184#[test]
2185fn bindgen_test_layout_dirent() {
2186 assert_eq!(
2187 ::std::mem::size_of::<dirent>(),
2188 1048usize,
2189 concat!("Size of: ", stringify!(dirent))
2190 );
2191 assert_eq!(
2192 ::std::mem::align_of::<dirent>(),
2193 8usize,
2194 concat!("Alignment of ", stringify!(dirent))
2195 );
2196 assert_eq!(
2197 unsafe { &(*(::std::ptr::null::<dirent>())).d_ino as *const _ as usize },
2198 0usize,
2199 concat!(
2200 "Offset of field: ",
2201 stringify!(dirent),
2202 "::",
2203 stringify!(d_ino)
2204 )
2205 );
2206 assert_eq!(
2207 unsafe { &(*(::std::ptr::null::<dirent>())).d_seekoff as *const _ as usize },
2208 8usize,
2209 concat!(
2210 "Offset of field: ",
2211 stringify!(dirent),
2212 "::",
2213 stringify!(d_seekoff)
2214 )
2215 );
2216 assert_eq!(
2217 unsafe { &(*(::std::ptr::null::<dirent>())).d_reclen as *const _ as usize },
2218 16usize,
2219 concat!(
2220 "Offset of field: ",
2221 stringify!(dirent),
2222 "::",
2223 stringify!(d_reclen)
2224 )
2225 );
2226 assert_eq!(
2227 unsafe { &(*(::std::ptr::null::<dirent>())).d_namlen as *const _ as usize },
2228 18usize,
2229 concat!(
2230 "Offset of field: ",
2231 stringify!(dirent),
2232 "::",
2233 stringify!(d_namlen)
2234 )
2235 );
2236 assert_eq!(
2237 unsafe { &(*(::std::ptr::null::<dirent>())).d_type as *const _ as usize },
2238 20usize,
2239 concat!(
2240 "Offset of field: ",
2241 stringify!(dirent),
2242 "::",
2243 stringify!(d_type)
2244 )
2245 );
2246 assert_eq!(
2247 unsafe { &(*(::std::ptr::null::<dirent>())).d_name as *const _ as usize },
2248 21usize,
2249 concat!(
2250 "Offset of field: ",
2251 stringify!(dirent),
2252 "::",
2253 stringify!(d_name)
2254 )
2255 );
2256}
2257impl Default for dirent {
2258 fn default() -> Self {
2259 unsafe { ::std::mem::zeroed() }
2260 }
2261}
2262#[repr(C)]
2263#[derive(Debug, Copy, Clone)]
2264pub struct _telldir {
2265 _unused: [u8; 0],
2266}
2267#[repr(C)]
2268#[derive(Copy, Clone)]
2269pub struct DIR {
2270 pub __dd_fd: ::std::os::raw::c_int,
2271 pub __dd_loc: ::std::os::raw::c_long,
2272 pub __dd_size: ::std::os::raw::c_long,
2273 pub __dd_buf: *mut ::std::os::raw::c_char,
2274 pub __dd_len: ::std::os::raw::c_int,
2275 pub __dd_seek: ::std::os::raw::c_long,
2276 pub __padding: ::std::os::raw::c_long,
2277 pub __dd_flags: ::std::os::raw::c_int,
2278 pub __dd_lock: __darwin_pthread_mutex_t,
2279 pub __dd_td: *mut _telldir,
2280}
2281#[test]
2282fn bindgen_test_layout_DIR() {
2283 assert_eq!(
2284 ::std::mem::size_of::<DIR>(),
2285 136usize,
2286 concat!("Size of: ", stringify!(DIR))
2287 );
2288 assert_eq!(
2289 ::std::mem::align_of::<DIR>(),
2290 8usize,
2291 concat!("Alignment of ", stringify!(DIR))
2292 );
2293 assert_eq!(
2294 unsafe { &(*(::std::ptr::null::<DIR>())).__dd_fd as *const _ as usize },
2295 0usize,
2296 concat!(
2297 "Offset of field: ",
2298 stringify!(DIR),
2299 "::",
2300 stringify!(__dd_fd)
2301 )
2302 );
2303 assert_eq!(
2304 unsafe { &(*(::std::ptr::null::<DIR>())).__dd_loc as *const _ as usize },
2305 8usize,
2306 concat!(
2307 "Offset of field: ",
2308 stringify!(DIR),
2309 "::",
2310 stringify!(__dd_loc)
2311 )
2312 );
2313 assert_eq!(
2314 unsafe { &(*(::std::ptr::null::<DIR>())).__dd_size as *const _ as usize },
2315 16usize,
2316 concat!(
2317 "Offset of field: ",
2318 stringify!(DIR),
2319 "::",
2320 stringify!(__dd_size)
2321 )
2322 );
2323 assert_eq!(
2324 unsafe { &(*(::std::ptr::null::<DIR>())).__dd_buf as *const _ as usize },
2325 24usize,
2326 concat!(
2327 "Offset of field: ",
2328 stringify!(DIR),
2329 "::",
2330 stringify!(__dd_buf)
2331 )
2332 );
2333 assert_eq!(
2334 unsafe { &(*(::std::ptr::null::<DIR>())).__dd_len as *const _ as usize },
2335 32usize,
2336 concat!(
2337 "Offset of field: ",
2338 stringify!(DIR),
2339 "::",
2340 stringify!(__dd_len)
2341 )
2342 );
2343 assert_eq!(
2344 unsafe { &(*(::std::ptr::null::<DIR>())).__dd_seek as *const _ as usize },
2345 40usize,
2346 concat!(
2347 "Offset of field: ",
2348 stringify!(DIR),
2349 "::",
2350 stringify!(__dd_seek)
2351 )
2352 );
2353 assert_eq!(
2354 unsafe { &(*(::std::ptr::null::<DIR>())).__padding as *const _ as usize },
2355 48usize,
2356 concat!(
2357 "Offset of field: ",
2358 stringify!(DIR),
2359 "::",
2360 stringify!(__padding)
2361 )
2362 );
2363 assert_eq!(
2364 unsafe { &(*(::std::ptr::null::<DIR>())).__dd_flags as *const _ as usize },
2365 56usize,
2366 concat!(
2367 "Offset of field: ",
2368 stringify!(DIR),
2369 "::",
2370 stringify!(__dd_flags)
2371 )
2372 );
2373 assert_eq!(
2374 unsafe { &(*(::std::ptr::null::<DIR>())).__dd_lock as *const _ as usize },
2375 64usize,
2376 concat!(
2377 "Offset of field: ",
2378 stringify!(DIR),
2379 "::",
2380 stringify!(__dd_lock)
2381 )
2382 );
2383 assert_eq!(
2384 unsafe { &(*(::std::ptr::null::<DIR>())).__dd_td as *const _ as usize },
2385 128usize,
2386 concat!(
2387 "Offset of field: ",
2388 stringify!(DIR),
2389 "::",
2390 stringify!(__dd_td)
2391 )
2392 );
2393}
2394impl Default for DIR {
2395 fn default() -> Self {
2396 unsafe { ::std::mem::zeroed() }
2397 }
2398}
2399pub type sa_family_t = __uint8_t;
2400pub type socklen_t = __darwin_socklen_t;
2401#[repr(C)]
2402#[derive(Debug, Default, Copy, Clone)]
2403pub struct sockaddr {
2404 pub sa_len: __uint8_t,
2405 pub sa_family: sa_family_t,
2406 pub sa_data: [::std::os::raw::c_char; 14usize],
2407}
2408#[test]
2409fn bindgen_test_layout_sockaddr() {
2410 assert_eq!(
2411 ::std::mem::size_of::<sockaddr>(),
2412 16usize,
2413 concat!("Size of: ", stringify!(sockaddr))
2414 );
2415 assert_eq!(
2416 ::std::mem::align_of::<sockaddr>(),
2417 1usize,
2418 concat!("Alignment of ", stringify!(sockaddr))
2419 );
2420 assert_eq!(
2421 unsafe { &(*(::std::ptr::null::<sockaddr>())).sa_len as *const _ as usize },
2422 0usize,
2423 concat!(
2424 "Offset of field: ",
2425 stringify!(sockaddr),
2426 "::",
2427 stringify!(sa_len)
2428 )
2429 );
2430 assert_eq!(
2431 unsafe { &(*(::std::ptr::null::<sockaddr>())).sa_family as *const _ as usize },
2432 1usize,
2433 concat!(
2434 "Offset of field: ",
2435 stringify!(sockaddr),
2436 "::",
2437 stringify!(sa_family)
2438 )
2439 );
2440 assert_eq!(
2441 unsafe { &(*(::std::ptr::null::<sockaddr>())).sa_data as *const _ as usize },
2442 2usize,
2443 concat!(
2444 "Offset of field: ",
2445 stringify!(sockaddr),
2446 "::",
2447 stringify!(sa_data)
2448 )
2449 );
2450}
2451#[repr(C)]
2452#[derive(Copy, Clone)]
2453pub struct sockaddr_storage {
2454 pub ss_len: __uint8_t,
2455 pub ss_family: sa_family_t,
2456 pub __ss_pad1: [::std::os::raw::c_char; 6usize],
2457 pub __ss_align: __int64_t,
2458 pub __ss_pad2: [::std::os::raw::c_char; 112usize],
2459}
2460#[test]
2461fn bindgen_test_layout_sockaddr_storage() {
2462 assert_eq!(
2463 ::std::mem::size_of::<sockaddr_storage>(),
2464 128usize,
2465 concat!("Size of: ", stringify!(sockaddr_storage))
2466 );
2467 assert_eq!(
2468 ::std::mem::align_of::<sockaddr_storage>(),
2469 8usize,
2470 concat!("Alignment of ", stringify!(sockaddr_storage))
2471 );
2472 assert_eq!(
2473 unsafe { &(*(::std::ptr::null::<sockaddr_storage>())).ss_len as *const _ as usize },
2474 0usize,
2475 concat!(
2476 "Offset of field: ",
2477 stringify!(sockaddr_storage),
2478 "::",
2479 stringify!(ss_len)
2480 )
2481 );
2482 assert_eq!(
2483 unsafe { &(*(::std::ptr::null::<sockaddr_storage>())).ss_family as *const _ as usize },
2484 1usize,
2485 concat!(
2486 "Offset of field: ",
2487 stringify!(sockaddr_storage),
2488 "::",
2489 stringify!(ss_family)
2490 )
2491 );
2492 assert_eq!(
2493 unsafe { &(*(::std::ptr::null::<sockaddr_storage>())).__ss_pad1 as *const _ as usize },
2494 2usize,
2495 concat!(
2496 "Offset of field: ",
2497 stringify!(sockaddr_storage),
2498 "::",
2499 stringify!(__ss_pad1)
2500 )
2501 );
2502 assert_eq!(
2503 unsafe { &(*(::std::ptr::null::<sockaddr_storage>())).__ss_align as *const _ as usize },
2504 8usize,
2505 concat!(
2506 "Offset of field: ",
2507 stringify!(sockaddr_storage),
2508 "::",
2509 stringify!(__ss_align)
2510 )
2511 );
2512 assert_eq!(
2513 unsafe { &(*(::std::ptr::null::<sockaddr_storage>())).__ss_pad2 as *const _ as usize },
2514 16usize,
2515 concat!(
2516 "Offset of field: ",
2517 stringify!(sockaddr_storage),
2518 "::",
2519 stringify!(__ss_pad2)
2520 )
2521 );
2522}
2523impl Default for sockaddr_storage {
2524 fn default() -> Self {
2525 unsafe { ::std::mem::zeroed() }
2526 }
2527}
2528#[repr(C)]
2529#[derive(Debug, Default, Copy, Clone)]
2530pub struct in_addr {
2531 pub s_addr: in_addr_t,
2532}
2533#[test]
2534fn bindgen_test_layout_in_addr() {
2535 assert_eq!(
2536 ::std::mem::size_of::<in_addr>(),
2537 4usize,
2538 concat!("Size of: ", stringify!(in_addr))
2539 );
2540 assert_eq!(
2541 ::std::mem::align_of::<in_addr>(),
2542 4usize,
2543 concat!("Alignment of ", stringify!(in_addr))
2544 );
2545 assert_eq!(
2546 unsafe { &(*(::std::ptr::null::<in_addr>())).s_addr as *const _ as usize },
2547 0usize,
2548 concat!(
2549 "Offset of field: ",
2550 stringify!(in_addr),
2551 "::",
2552 stringify!(s_addr)
2553 )
2554 );
2555}
2556#[repr(C)]
2557#[derive(Debug, Default, Copy, Clone)]
2558pub struct sockaddr_in {
2559 pub sin_len: __uint8_t,
2560 pub sin_family: sa_family_t,
2561 pub sin_port: in_port_t,
2562 pub sin_addr: in_addr,
2563 pub sin_zero: [::std::os::raw::c_char; 8usize],
2564}
2565#[test]
2566fn bindgen_test_layout_sockaddr_in() {
2567 assert_eq!(
2568 ::std::mem::size_of::<sockaddr_in>(),
2569 16usize,
2570 concat!("Size of: ", stringify!(sockaddr_in))
2571 );
2572 assert_eq!(
2573 ::std::mem::align_of::<sockaddr_in>(),
2574 4usize,
2575 concat!("Alignment of ", stringify!(sockaddr_in))
2576 );
2577 assert_eq!(
2578 unsafe { &(*(::std::ptr::null::<sockaddr_in>())).sin_len as *const _ as usize },
2579 0usize,
2580 concat!(
2581 "Offset of field: ",
2582 stringify!(sockaddr_in),
2583 "::",
2584 stringify!(sin_len)
2585 )
2586 );
2587 assert_eq!(
2588 unsafe { &(*(::std::ptr::null::<sockaddr_in>())).sin_family as *const _ as usize },
2589 1usize,
2590 concat!(
2591 "Offset of field: ",
2592 stringify!(sockaddr_in),
2593 "::",
2594 stringify!(sin_family)
2595 )
2596 );
2597 assert_eq!(
2598 unsafe { &(*(::std::ptr::null::<sockaddr_in>())).sin_port as *const _ as usize },
2599 2usize,
2600 concat!(
2601 "Offset of field: ",
2602 stringify!(sockaddr_in),
2603 "::",
2604 stringify!(sin_port)
2605 )
2606 );
2607 assert_eq!(
2608 unsafe { &(*(::std::ptr::null::<sockaddr_in>())).sin_addr as *const _ as usize },
2609 4usize,
2610 concat!(
2611 "Offset of field: ",
2612 stringify!(sockaddr_in),
2613 "::",
2614 stringify!(sin_addr)
2615 )
2616 );
2617 assert_eq!(
2618 unsafe { &(*(::std::ptr::null::<sockaddr_in>())).sin_zero as *const _ as usize },
2619 8usize,
2620 concat!(
2621 "Offset of field: ",
2622 stringify!(sockaddr_in),
2623 "::",
2624 stringify!(sin_zero)
2625 )
2626 );
2627}
2628#[repr(C)]
2629#[derive(Copy, Clone)]
2630pub struct in6_addr {
2631 pub __u6_addr: in6_addr__bindgen_ty_1,
2632}
2633#[repr(C)]
2634#[derive(Copy, Clone)]
2635pub union in6_addr__bindgen_ty_1 {
2636 pub __u6_addr8: [__uint8_t; 16usize],
2637 pub __u6_addr16: [__uint16_t; 8usize],
2638 pub __u6_addr32: [__uint32_t; 4usize],
2639 _bindgen_union_align: [u32; 4usize],
2640}
2641#[test]
2642fn bindgen_test_layout_in6_addr__bindgen_ty_1() {
2643 assert_eq!(
2644 ::std::mem::size_of::<in6_addr__bindgen_ty_1>(),
2645 16usize,
2646 concat!("Size of: ", stringify!(in6_addr__bindgen_ty_1))
2647 );
2648 assert_eq!(
2649 ::std::mem::align_of::<in6_addr__bindgen_ty_1>(),
2650 4usize,
2651 concat!("Alignment of ", stringify!(in6_addr__bindgen_ty_1))
2652 );
2653 assert_eq!(
2654 unsafe {
2655 &(*(::std::ptr::null::<in6_addr__bindgen_ty_1>())).__u6_addr8 as *const _ as usize
2656 },
2657 0usize,
2658 concat!(
2659 "Offset of field: ",
2660 stringify!(in6_addr__bindgen_ty_1),
2661 "::",
2662 stringify!(__u6_addr8)
2663 )
2664 );
2665 assert_eq!(
2666 unsafe {
2667 &(*(::std::ptr::null::<in6_addr__bindgen_ty_1>())).__u6_addr16 as *const _ as usize
2668 },
2669 0usize,
2670 concat!(
2671 "Offset of field: ",
2672 stringify!(in6_addr__bindgen_ty_1),
2673 "::",
2674 stringify!(__u6_addr16)
2675 )
2676 );
2677 assert_eq!(
2678 unsafe {
2679 &(*(::std::ptr::null::<in6_addr__bindgen_ty_1>())).__u6_addr32 as *const _ as usize
2680 },
2681 0usize,
2682 concat!(
2683 "Offset of field: ",
2684 stringify!(in6_addr__bindgen_ty_1),
2685 "::",
2686 stringify!(__u6_addr32)
2687 )
2688 );
2689}
2690impl Default for in6_addr__bindgen_ty_1 {
2691 fn default() -> Self {
2692 unsafe { ::std::mem::zeroed() }
2693 }
2694}
2695#[test]
2696fn bindgen_test_layout_in6_addr() {
2697 assert_eq!(
2698 ::std::mem::size_of::<in6_addr>(),
2699 16usize,
2700 concat!("Size of: ", stringify!(in6_addr))
2701 );
2702 assert_eq!(
2703 ::std::mem::align_of::<in6_addr>(),
2704 4usize,
2705 concat!("Alignment of ", stringify!(in6_addr))
2706 );
2707 assert_eq!(
2708 unsafe { &(*(::std::ptr::null::<in6_addr>())).__u6_addr as *const _ as usize },
2709 0usize,
2710 concat!(
2711 "Offset of field: ",
2712 stringify!(in6_addr),
2713 "::",
2714 stringify!(__u6_addr)
2715 )
2716 );
2717}
2718impl Default for in6_addr {
2719 fn default() -> Self {
2720 unsafe { ::std::mem::zeroed() }
2721 }
2722}
2723#[repr(C)]
2724#[derive(Copy, Clone)]
2725pub struct sockaddr_in6 {
2726 pub sin6_len: __uint8_t,
2727 pub sin6_family: sa_family_t,
2728 pub sin6_port: in_port_t,
2729 pub sin6_flowinfo: __uint32_t,
2730 pub sin6_addr: in6_addr,
2731 pub sin6_scope_id: __uint32_t,
2732}
2733#[test]
2734fn bindgen_test_layout_sockaddr_in6() {
2735 assert_eq!(
2736 ::std::mem::size_of::<sockaddr_in6>(),
2737 28usize,
2738 concat!("Size of: ", stringify!(sockaddr_in6))
2739 );
2740 assert_eq!(
2741 ::std::mem::align_of::<sockaddr_in6>(),
2742 4usize,
2743 concat!("Alignment of ", stringify!(sockaddr_in6))
2744 );
2745 assert_eq!(
2746 unsafe { &(*(::std::ptr::null::<sockaddr_in6>())).sin6_len as *const _ as usize },
2747 0usize,
2748 concat!(
2749 "Offset of field: ",
2750 stringify!(sockaddr_in6),
2751 "::",
2752 stringify!(sin6_len)
2753 )
2754 );
2755 assert_eq!(
2756 unsafe { &(*(::std::ptr::null::<sockaddr_in6>())).sin6_family as *const _ as usize },
2757 1usize,
2758 concat!(
2759 "Offset of field: ",
2760 stringify!(sockaddr_in6),
2761 "::",
2762 stringify!(sin6_family)
2763 )
2764 );
2765 assert_eq!(
2766 unsafe { &(*(::std::ptr::null::<sockaddr_in6>())).sin6_port as *const _ as usize },
2767 2usize,
2768 concat!(
2769 "Offset of field: ",
2770 stringify!(sockaddr_in6),
2771 "::",
2772 stringify!(sin6_port)
2773 )
2774 );
2775 assert_eq!(
2776 unsafe { &(*(::std::ptr::null::<sockaddr_in6>())).sin6_flowinfo as *const _ as usize },
2777 4usize,
2778 concat!(
2779 "Offset of field: ",
2780 stringify!(sockaddr_in6),
2781 "::",
2782 stringify!(sin6_flowinfo)
2783 )
2784 );
2785 assert_eq!(
2786 unsafe { &(*(::std::ptr::null::<sockaddr_in6>())).sin6_addr as *const _ as usize },
2787 8usize,
2788 concat!(
2789 "Offset of field: ",
2790 stringify!(sockaddr_in6),
2791 "::",
2792 stringify!(sin6_addr)
2793 )
2794 );
2795 assert_eq!(
2796 unsafe { &(*(::std::ptr::null::<sockaddr_in6>())).sin6_scope_id as *const _ as usize },
2797 24usize,
2798 concat!(
2799 "Offset of field: ",
2800 stringify!(sockaddr_in6),
2801 "::",
2802 stringify!(sin6_scope_id)
2803 )
2804 );
2805}
2806impl Default for sockaddr_in6 {
2807 fn default() -> Self {
2808 unsafe { ::std::mem::zeroed() }
2809 }
2810}
2811#[repr(C)]
2812#[derive(Debug, Copy, Clone)]
2813pub struct addrinfo {
2814 pub ai_flags: ::std::os::raw::c_int,
2815 pub ai_family: ::std::os::raw::c_int,
2816 pub ai_socktype: ::std::os::raw::c_int,
2817 pub ai_protocol: ::std::os::raw::c_int,
2818 pub ai_addrlen: socklen_t,
2819 pub ai_canonname: *mut ::std::os::raw::c_char,
2820 pub ai_addr: *mut sockaddr,
2821 pub ai_next: *mut addrinfo,
2822}
2823#[test]
2824fn bindgen_test_layout_addrinfo() {
2825 assert_eq!(
2826 ::std::mem::size_of::<addrinfo>(),
2827 48usize,
2828 concat!("Size of: ", stringify!(addrinfo))
2829 );
2830 assert_eq!(
2831 ::std::mem::align_of::<addrinfo>(),
2832 8usize,
2833 concat!("Alignment of ", stringify!(addrinfo))
2834 );
2835 assert_eq!(
2836 unsafe { &(*(::std::ptr::null::<addrinfo>())).ai_flags as *const _ as usize },
2837 0usize,
2838 concat!(
2839 "Offset of field: ",
2840 stringify!(addrinfo),
2841 "::",
2842 stringify!(ai_flags)
2843 )
2844 );
2845 assert_eq!(
2846 unsafe { &(*(::std::ptr::null::<addrinfo>())).ai_family as *const _ as usize },
2847 4usize,
2848 concat!(
2849 "Offset of field: ",
2850 stringify!(addrinfo),
2851 "::",
2852 stringify!(ai_family)
2853 )
2854 );
2855 assert_eq!(
2856 unsafe { &(*(::std::ptr::null::<addrinfo>())).ai_socktype as *const _ as usize },
2857 8usize,
2858 concat!(
2859 "Offset of field: ",
2860 stringify!(addrinfo),
2861 "::",
2862 stringify!(ai_socktype)
2863 )
2864 );
2865 assert_eq!(
2866 unsafe { &(*(::std::ptr::null::<addrinfo>())).ai_protocol as *const _ as usize },
2867 12usize,
2868 concat!(
2869 "Offset of field: ",
2870 stringify!(addrinfo),
2871 "::",
2872 stringify!(ai_protocol)
2873 )
2874 );
2875 assert_eq!(
2876 unsafe { &(*(::std::ptr::null::<addrinfo>())).ai_addrlen as *const _ as usize },
2877 16usize,
2878 concat!(
2879 "Offset of field: ",
2880 stringify!(addrinfo),
2881 "::",
2882 stringify!(ai_addrlen)
2883 )
2884 );
2885 assert_eq!(
2886 unsafe { &(*(::std::ptr::null::<addrinfo>())).ai_canonname as *const _ as usize },
2887 24usize,
2888 concat!(
2889 "Offset of field: ",
2890 stringify!(addrinfo),
2891 "::",
2892 stringify!(ai_canonname)
2893 )
2894 );
2895 assert_eq!(
2896 unsafe { &(*(::std::ptr::null::<addrinfo>())).ai_addr as *const _ as usize },
2897 32usize,
2898 concat!(
2899 "Offset of field: ",
2900 stringify!(addrinfo),
2901 "::",
2902 stringify!(ai_addr)
2903 )
2904 );
2905 assert_eq!(
2906 unsafe { &(*(::std::ptr::null::<addrinfo>())).ai_next as *const _ as usize },
2907 40usize,
2908 concat!(
2909 "Offset of field: ",
2910 stringify!(addrinfo),
2911 "::",
2912 stringify!(ai_next)
2913 )
2914 );
2915}
2916impl Default for addrinfo {
2917 fn default() -> Self {
2918 unsafe { ::std::mem::zeroed() }
2919 }
2920}
2921pub type tcflag_t = ::std::os::raw::c_ulong;
2922pub type cc_t = ::std::os::raw::c_uchar;
2923pub type speed_t = ::std::os::raw::c_ulong;
2924#[repr(C)]
2925#[derive(Debug, Default, Copy, Clone)]
2926pub struct termios {
2927 pub c_iflag: tcflag_t,
2928 pub c_oflag: tcflag_t,
2929 pub c_cflag: tcflag_t,
2930 pub c_lflag: tcflag_t,
2931 pub c_cc: [cc_t; 20usize],
2932 pub c_ispeed: speed_t,
2933 pub c_ospeed: speed_t,
2934}
2935#[test]
2936fn bindgen_test_layout_termios() {
2937 assert_eq!(
2938 ::std::mem::size_of::<termios>(),
2939 72usize,
2940 concat!("Size of: ", stringify!(termios))
2941 );
2942 assert_eq!(
2943 ::std::mem::align_of::<termios>(),
2944 8usize,
2945 concat!("Alignment of ", stringify!(termios))
2946 );
2947 assert_eq!(
2948 unsafe { &(*(::std::ptr::null::<termios>())).c_iflag as *const _ as usize },
2949 0usize,
2950 concat!(
2951 "Offset of field: ",
2952 stringify!(termios),
2953 "::",
2954 stringify!(c_iflag)
2955 )
2956 );
2957 assert_eq!(
2958 unsafe { &(*(::std::ptr::null::<termios>())).c_oflag as *const _ as usize },
2959 8usize,
2960 concat!(
2961 "Offset of field: ",
2962 stringify!(termios),
2963 "::",
2964 stringify!(c_oflag)
2965 )
2966 );
2967 assert_eq!(
2968 unsafe { &(*(::std::ptr::null::<termios>())).c_cflag as *const _ as usize },
2969 16usize,
2970 concat!(
2971 "Offset of field: ",
2972 stringify!(termios),
2973 "::",
2974 stringify!(c_cflag)
2975 )
2976 );
2977 assert_eq!(
2978 unsafe { &(*(::std::ptr::null::<termios>())).c_lflag as *const _ as usize },
2979 24usize,
2980 concat!(
2981 "Offset of field: ",
2982 stringify!(termios),
2983 "::",
2984 stringify!(c_lflag)
2985 )
2986 );
2987 assert_eq!(
2988 unsafe { &(*(::std::ptr::null::<termios>())).c_cc as *const _ as usize },
2989 32usize,
2990 concat!(
2991 "Offset of field: ",
2992 stringify!(termios),
2993 "::",
2994 stringify!(c_cc)
2995 )
2996 );
2997 assert_eq!(
2998 unsafe { &(*(::std::ptr::null::<termios>())).c_ispeed as *const _ as usize },
2999 56usize,
3000 concat!(
3001 "Offset of field: ",
3002 stringify!(termios),
3003 "::",
3004 stringify!(c_ispeed)
3005 )
3006 );
3007 assert_eq!(
3008 unsafe { &(*(::std::ptr::null::<termios>())).c_ospeed as *const _ as usize },
3009 64usize,
3010 concat!(
3011 "Offset of field: ",
3012 stringify!(termios),
3013 "::",
3014 stringify!(c_ospeed)
3015 )
3016 );
3017}
3018pub type mach_port_t = __darwin_mach_port_t;
3019#[repr(C)]
3020#[derive(Debug, Copy, Clone)]
3021pub struct uv__work {
3022 pub work: ::std::option::Option<unsafe extern "C" fn(w: *mut uv__work)>,
3023 pub done: ::std::option::Option<
3024 unsafe extern "C" fn(w: *mut uv__work, status: ::std::os::raw::c_int),
3025 >,
3026 pub loop_: *mut uv_loop_s,
3027 pub wq: [*mut ::std::os::raw::c_void; 2usize],
3028}
3029#[test]
3030fn bindgen_test_layout_uv__work() {
3031 assert_eq!(
3032 ::std::mem::size_of::<uv__work>(),
3033 40usize,
3034 concat!("Size of: ", stringify!(uv__work))
3035 );
3036 assert_eq!(
3037 ::std::mem::align_of::<uv__work>(),
3038 8usize,
3039 concat!("Alignment of ", stringify!(uv__work))
3040 );
3041 assert_eq!(
3042 unsafe { &(*(::std::ptr::null::<uv__work>())).work as *const _ as usize },
3043 0usize,
3044 concat!(
3045 "Offset of field: ",
3046 stringify!(uv__work),
3047 "::",
3048 stringify!(work)
3049 )
3050 );
3051 assert_eq!(
3052 unsafe { &(*(::std::ptr::null::<uv__work>())).done as *const _ as usize },
3053 8usize,
3054 concat!(
3055 "Offset of field: ",
3056 stringify!(uv__work),
3057 "::",
3058 stringify!(done)
3059 )
3060 );
3061 assert_eq!(
3062 unsafe { &(*(::std::ptr::null::<uv__work>())).loop_ as *const _ as usize },
3063 16usize,
3064 concat!(
3065 "Offset of field: ",
3066 stringify!(uv__work),
3067 "::",
3068 stringify!(loop_)
3069 )
3070 );
3071 assert_eq!(
3072 unsafe { &(*(::std::ptr::null::<uv__work>())).wq as *const _ as usize },
3073 24usize,
3074 concat!(
3075 "Offset of field: ",
3076 stringify!(uv__work),
3077 "::",
3078 stringify!(wq)
3079 )
3080 );
3081}
3082impl Default for uv__work {
3083 fn default() -> Self {
3084 unsafe { ::std::mem::zeroed() }
3085 }
3086}
3087pub type semaphore_t = mach_port_t;
3088pub type uv__io_cb = ::std::option::Option<
3089 unsafe extern "C" fn(loop_: *mut uv_loop_s, w: *mut uv__io_s, events: ::std::os::raw::c_uint),
3090>;
3091pub type uv__io_t = uv__io_s;
3092#[repr(C)]
3093#[derive(Debug, Copy, Clone)]
3094pub struct uv__io_s {
3095 pub cb: uv__io_cb,
3096 pub pending_queue: [*mut ::std::os::raw::c_void; 2usize],
3097 pub watcher_queue: [*mut ::std::os::raw::c_void; 2usize],
3098 pub pevents: ::std::os::raw::c_uint,
3099 pub events: ::std::os::raw::c_uint,
3100 pub fd: ::std::os::raw::c_int,
3101 pub rcount: ::std::os::raw::c_int,
3102 pub wcount: ::std::os::raw::c_int,
3103}
3104#[test]
3105fn bindgen_test_layout_uv__io_s() {
3106 assert_eq!(
3107 ::std::mem::size_of::<uv__io_s>(),
3108 64usize,
3109 concat!("Size of: ", stringify!(uv__io_s))
3110 );
3111 assert_eq!(
3112 ::std::mem::align_of::<uv__io_s>(),
3113 8usize,
3114 concat!("Alignment of ", stringify!(uv__io_s))
3115 );
3116 assert_eq!(
3117 unsafe { &(*(::std::ptr::null::<uv__io_s>())).cb as *const _ as usize },
3118 0usize,
3119 concat!(
3120 "Offset of field: ",
3121 stringify!(uv__io_s),
3122 "::",
3123 stringify!(cb)
3124 )
3125 );
3126 assert_eq!(
3127 unsafe { &(*(::std::ptr::null::<uv__io_s>())).pending_queue as *const _ as usize },
3128 8usize,
3129 concat!(
3130 "Offset of field: ",
3131 stringify!(uv__io_s),
3132 "::",
3133 stringify!(pending_queue)
3134 )
3135 );
3136 assert_eq!(
3137 unsafe { &(*(::std::ptr::null::<uv__io_s>())).watcher_queue as *const _ as usize },
3138 24usize,
3139 concat!(
3140 "Offset of field: ",
3141 stringify!(uv__io_s),
3142 "::",
3143 stringify!(watcher_queue)
3144 )
3145 );
3146 assert_eq!(
3147 unsafe { &(*(::std::ptr::null::<uv__io_s>())).pevents as *const _ as usize },
3148 40usize,
3149 concat!(
3150 "Offset of field: ",
3151 stringify!(uv__io_s),
3152 "::",
3153 stringify!(pevents)
3154 )
3155 );
3156 assert_eq!(
3157 unsafe { &(*(::std::ptr::null::<uv__io_s>())).events as *const _ as usize },
3158 44usize,
3159 concat!(
3160 "Offset of field: ",
3161 stringify!(uv__io_s),
3162 "::",
3163 stringify!(events)
3164 )
3165 );
3166 assert_eq!(
3167 unsafe { &(*(::std::ptr::null::<uv__io_s>())).fd as *const _ as usize },
3168 48usize,
3169 concat!(
3170 "Offset of field: ",
3171 stringify!(uv__io_s),
3172 "::",
3173 stringify!(fd)
3174 )
3175 );
3176 assert_eq!(
3177 unsafe { &(*(::std::ptr::null::<uv__io_s>())).rcount as *const _ as usize },
3178 52usize,
3179 concat!(
3180 "Offset of field: ",
3181 stringify!(uv__io_s),
3182 "::",
3183 stringify!(rcount)
3184 )
3185 );
3186 assert_eq!(
3187 unsafe { &(*(::std::ptr::null::<uv__io_s>())).wcount as *const _ as usize },
3188 56usize,
3189 concat!(
3190 "Offset of field: ",
3191 stringify!(uv__io_s),
3192 "::",
3193 stringify!(wcount)
3194 )
3195 );
3196}
3197impl Default for uv__io_s {
3198 fn default() -> Self {
3199 unsafe { ::std::mem::zeroed() }
3200 }
3201}
3202#[repr(C)]
3203#[derive(Debug, Copy, Clone)]
3204pub struct uv_buf_t {
3205 pub base: *mut ::std::os::raw::c_char,
3206 pub len: size_t,
3207}
3208#[test]
3209fn bindgen_test_layout_uv_buf_t() {
3210 assert_eq!(
3211 ::std::mem::size_of::<uv_buf_t>(),
3212 16usize,
3213 concat!("Size of: ", stringify!(uv_buf_t))
3214 );
3215 assert_eq!(
3216 ::std::mem::align_of::<uv_buf_t>(),
3217 8usize,
3218 concat!("Alignment of ", stringify!(uv_buf_t))
3219 );
3220 assert_eq!(
3221 unsafe { &(*(::std::ptr::null::<uv_buf_t>())).base as *const _ as usize },
3222 0usize,
3223 concat!(
3224 "Offset of field: ",
3225 stringify!(uv_buf_t),
3226 "::",
3227 stringify!(base)
3228 )
3229 );
3230 assert_eq!(
3231 unsafe { &(*(::std::ptr::null::<uv_buf_t>())).len as *const _ as usize },
3232 8usize,
3233 concat!(
3234 "Offset of field: ",
3235 stringify!(uv_buf_t),
3236 "::",
3237 stringify!(len)
3238 )
3239 );
3240}
3241impl Default for uv_buf_t {
3242 fn default() -> Self {
3243 unsafe { ::std::mem::zeroed() }
3244 }
3245}
3246pub type uv_file = ::std::os::raw::c_int;
3247pub type uv_os_sock_t = ::std::os::raw::c_int;
3248pub type uv_os_fd_t = ::std::os::raw::c_int;
3249pub type uv_pid_t = pid_t;
3250pub type uv_once_t = pthread_once_t;
3251pub type uv_thread_t = pthread_t;
3252pub type uv_mutex_t = pthread_mutex_t;
3253pub type uv_rwlock_t = pthread_rwlock_t;
3254pub type uv_sem_t = semaphore_t;
3255pub type uv_cond_t = pthread_cond_t;
3256pub type uv_key_t = pthread_key_t;
3257#[repr(C)]
3258#[derive(Copy, Clone)]
3259pub struct _uv_barrier {
3260 pub mutex: uv_mutex_t,
3261 pub cond: uv_cond_t,
3262 pub threshold: ::std::os::raw::c_uint,
3263 pub in_: ::std::os::raw::c_uint,
3264 pub out: ::std::os::raw::c_uint,
3265}
3266#[test]
3267fn bindgen_test_layout__uv_barrier() {
3268 assert_eq!(
3269 ::std::mem::size_of::<_uv_barrier>(),
3270 128usize,
3271 concat!("Size of: ", stringify!(_uv_barrier))
3272 );
3273 assert_eq!(
3274 ::std::mem::align_of::<_uv_barrier>(),
3275 8usize,
3276 concat!("Alignment of ", stringify!(_uv_barrier))
3277 );
3278 assert_eq!(
3279 unsafe { &(*(::std::ptr::null::<_uv_barrier>())).mutex as *const _ as usize },
3280 0usize,
3281 concat!(
3282 "Offset of field: ",
3283 stringify!(_uv_barrier),
3284 "::",
3285 stringify!(mutex)
3286 )
3287 );
3288 assert_eq!(
3289 unsafe { &(*(::std::ptr::null::<_uv_barrier>())).cond as *const _ as usize },
3290 64usize,
3291 concat!(
3292 "Offset of field: ",
3293 stringify!(_uv_barrier),
3294 "::",
3295 stringify!(cond)
3296 )
3297 );
3298 assert_eq!(
3299 unsafe { &(*(::std::ptr::null::<_uv_barrier>())).threshold as *const _ as usize },
3300 112usize,
3301 concat!(
3302 "Offset of field: ",
3303 stringify!(_uv_barrier),
3304 "::",
3305 stringify!(threshold)
3306 )
3307 );
3308 assert_eq!(
3309 unsafe { &(*(::std::ptr::null::<_uv_barrier>())).in_ as *const _ as usize },
3310 116usize,
3311 concat!(
3312 "Offset of field: ",
3313 stringify!(_uv_barrier),
3314 "::",
3315 stringify!(in_)
3316 )
3317 );
3318 assert_eq!(
3319 unsafe { &(*(::std::ptr::null::<_uv_barrier>())).out as *const _ as usize },
3320 120usize,
3321 concat!(
3322 "Offset of field: ",
3323 stringify!(_uv_barrier),
3324 "::",
3325 stringify!(out)
3326 )
3327 );
3328}
3329impl Default for _uv_barrier {
3330 fn default() -> Self {
3331 unsafe { ::std::mem::zeroed() }
3332 }
3333}
3334#[repr(C)]
3335#[derive(Debug, Copy, Clone)]
3336pub struct uv_barrier_t {
3337 pub b: *mut _uv_barrier,
3338}
3339#[test]
3340fn bindgen_test_layout_uv_barrier_t() {
3341 assert_eq!(
3342 ::std::mem::size_of::<uv_barrier_t>(),
3343 8usize,
3344 concat!("Size of: ", stringify!(uv_barrier_t))
3345 );
3346 assert_eq!(
3347 ::std::mem::align_of::<uv_barrier_t>(),
3348 8usize,
3349 concat!("Alignment of ", stringify!(uv_barrier_t))
3350 );
3351 assert_eq!(
3352 unsafe { &(*(::std::ptr::null::<uv_barrier_t>())).b as *const _ as usize },
3353 0usize,
3354 concat!(
3355 "Offset of field: ",
3356 stringify!(uv_barrier_t),
3357 "::",
3358 stringify!(b)
3359 )
3360 );
3361}
3362impl Default for uv_barrier_t {
3363 fn default() -> Self {
3364 unsafe { ::std::mem::zeroed() }
3365 }
3366}
3367pub type uv_gid_t = gid_t;
3368pub type uv_uid_t = uid_t;
3369pub type uv__dirent_t = dirent;
3370#[repr(C)]
3371#[derive(Debug, Copy, Clone)]
3372pub struct uv_lib_t {
3373 pub handle: *mut ::std::os::raw::c_void,
3374 pub errmsg: *mut ::std::os::raw::c_char,
3375}
3376#[test]
3377fn bindgen_test_layout_uv_lib_t() {
3378 assert_eq!(
3379 ::std::mem::size_of::<uv_lib_t>(),
3380 16usize,
3381 concat!("Size of: ", stringify!(uv_lib_t))
3382 );
3383 assert_eq!(
3384 ::std::mem::align_of::<uv_lib_t>(),
3385 8usize,
3386 concat!("Alignment of ", stringify!(uv_lib_t))
3387 );
3388 assert_eq!(
3389 unsafe { &(*(::std::ptr::null::<uv_lib_t>())).handle as *const _ as usize },
3390 0usize,
3391 concat!(
3392 "Offset of field: ",
3393 stringify!(uv_lib_t),
3394 "::",
3395 stringify!(handle)
3396 )
3397 );
3398 assert_eq!(
3399 unsafe { &(*(::std::ptr::null::<uv_lib_t>())).errmsg as *const _ as usize },
3400 8usize,
3401 concat!(
3402 "Offset of field: ",
3403 stringify!(uv_lib_t),
3404 "::",
3405 stringify!(errmsg)
3406 )
3407 );
3408}
3409impl Default for uv_lib_t {
3410 fn default() -> Self {
3411 unsafe { ::std::mem::zeroed() }
3412 }
3413}
3414#[repr(i32)]
3415#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
3416pub enum uv_errno_t {
3417 UV_E2BIG = -7,
3418 UV_EACCES = -13,
3419 UV_EADDRINUSE = -48,
3420 UV_EADDRNOTAVAIL = -49,
3421 UV_EAFNOSUPPORT = -47,
3422 UV_EAGAIN = -35,
3423 UV_EAI_ADDRFAMILY = -3000,
3424 UV_EAI_AGAIN = -3001,
3425 UV_EAI_BADFLAGS = -3002,
3426 UV_EAI_BADHINTS = -3013,
3427 UV_EAI_CANCELED = -3003,
3428 UV_EAI_FAIL = -3004,
3429 UV_EAI_FAMILY = -3005,
3430 UV_EAI_MEMORY = -3006,
3431 UV_EAI_NODATA = -3007,
3432 UV_EAI_NONAME = -3008,
3433 UV_EAI_OVERFLOW = -3009,
3434 UV_EAI_PROTOCOL = -3014,
3435 UV_EAI_SERVICE = -3010,
3436 UV_EAI_SOCKTYPE = -3011,
3437 UV_EALREADY = -37,
3438 UV_EBADF = -9,
3439 UV_EBUSY = -16,
3440 UV_ECANCELED = -89,
3441 UV_ECHARSET = -4080,
3442 UV_ECONNABORTED = -53,
3443 UV_ECONNREFUSED = -61,
3444 UV_ECONNRESET = -54,
3445 UV_EDESTADDRREQ = -39,
3446 UV_EEXIST = -17,
3447 UV_EFAULT = -14,
3448 UV_EFBIG = -27,
3449 UV_EHOSTUNREACH = -65,
3450 UV_EINTR = -4,
3451 UV_EINVAL = -22,
3452 UV_EIO = -5,
3453 UV_EISCONN = -56,
3454 UV_EISDIR = -21,
3455 UV_ELOOP = -62,
3456 UV_EMFILE = -24,
3457 UV_EMSGSIZE = -40,
3458 UV_ENAMETOOLONG = -63,
3459 UV_ENETDOWN = -50,
3460 UV_ENETUNREACH = -51,
3461 UV_ENFILE = -23,
3462 UV_ENOBUFS = -55,
3463 UV_ENODEV = -19,
3464 UV_ENOENT = -2,
3465 UV_ENOMEM = -12,
3466 UV_ENONET = -4056,
3467 UV_ENOPROTOOPT = -42,
3468 UV_ENOSPC = -28,
3469 UV_ENOSYS = -78,
3470 UV_ENOTCONN = -57,
3471 UV_ENOTDIR = -20,
3472 UV_ENOTEMPTY = -66,
3473 UV_ENOTSOCK = -38,
3474 UV_ENOTSUP = -45,
3475 UV_EPERM = -1,
3476 UV_EPIPE = -32,
3477 UV_EPROTO = -100,
3478 UV_EPROTONOSUPPORT = -43,
3479 UV_EPROTOTYPE = -41,
3480 UV_ERANGE = -34,
3481 UV_EROFS = -30,
3482 UV_ESHUTDOWN = -58,
3483 UV_ESPIPE = -29,
3484 UV_ESRCH = -3,
3485 UV_ETIMEDOUT = -60,
3486 UV_ETXTBSY = -26,
3487 UV_EXDEV = -18,
3488 UV_UNKNOWN = -4094,
3489 UV_EOF = -4095,
3490 UV_ENXIO = -6,
3491 UV_EMLINK = -31,
3492 UV_EHOSTDOWN = -64,
3493 UV_EREMOTEIO = -4030,
3494 UV_ENOTTY = -25,
3495 UV_EFTYPE = -79,
3496 UV_EILSEQ = -92,
3497 UV_ERRNO_MAX = -4096,
3498}
3499#[repr(u32)]
3500#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
3501pub enum uv_handle_type {
3502 UV_UNKNOWN_HANDLE = 0,
3503 UV_ASYNC = 1,
3504 UV_CHECK = 2,
3505 UV_FS_EVENT = 3,
3506 UV_FS_POLL = 4,
3507 UV_HANDLE = 5,
3508 UV_IDLE = 6,
3509 UV_NAMED_PIPE = 7,
3510 UV_POLL = 8,
3511 UV_PREPARE = 9,
3512 UV_PROCESS = 10,
3513 UV_STREAM = 11,
3514 UV_TCP = 12,
3515 UV_TIMER = 13,
3516 UV_TTY = 14,
3517 UV_UDP = 15,
3518 UV_SIGNAL = 16,
3519 UV_FILE = 17,
3520 UV_HANDLE_TYPE_MAX = 18,
3521}
3522#[repr(u32)]
3523#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
3524pub enum uv_req_type {
3525 UV_UNKNOWN_REQ = 0,
3526 UV_REQ = 1,
3527 UV_CONNECT = 2,
3528 UV_WRITE = 3,
3529 UV_SHUTDOWN = 4,
3530 UV_UDP_SEND = 5,
3531 UV_FS = 6,
3532 UV_WORK = 7,
3533 UV_GETADDRINFO = 8,
3534 UV_GETNAMEINFO = 9,
3535 UV_RANDOM = 10,
3536 UV_REQ_TYPE_MAX = 11,
3537}
3538pub type uv_loop_t = uv_loop_s;
3539pub type uv_handle_t = uv_handle_s;
3540pub type uv_dir_t = uv_dir_s;
3541pub type uv_stream_t = uv_stream_s;
3542pub type uv_tcp_t = uv_tcp_s;
3543pub type uv_udp_t = uv_udp_s;
3544pub type uv_pipe_t = uv_pipe_s;
3545pub type uv_tty_t = uv_tty_s;
3546pub type uv_poll_t = uv_poll_s;
3547pub type uv_timer_t = uv_timer_s;
3548pub type uv_prepare_t = uv_prepare_s;
3549pub type uv_check_t = uv_check_s;
3550pub type uv_idle_t = uv_idle_s;
3551pub type uv_async_t = uv_async_s;
3552pub type uv_process_t = uv_process_s;
3553pub type uv_fs_event_t = uv_fs_event_s;
3554pub type uv_fs_poll_t = uv_fs_poll_s;
3555pub type uv_signal_t = uv_signal_s;
3556pub type uv_req_t = uv_req_s;
3557pub type uv_getaddrinfo_t = uv_getaddrinfo_s;
3558pub type uv_getnameinfo_t = uv_getnameinfo_s;
3559pub type uv_shutdown_t = uv_shutdown_s;
3560pub type uv_write_t = uv_write_s;
3561pub type uv_connect_t = uv_connect_s;
3562pub type uv_udp_send_t = uv_udp_send_s;
3563pub type uv_fs_t = uv_fs_s;
3564pub type uv_work_t = uv_work_s;
3565pub type uv_random_t = uv_random_s;
3566pub type uv_env_item_t = uv_env_item_s;
3567pub type uv_cpu_info_t = uv_cpu_info_s;
3568pub type uv_interface_address_t = uv_interface_address_s;
3569pub type uv_dirent_t = uv_dirent_s;
3570pub type uv_passwd_t = uv_passwd_s;
3571pub type uv_utsname_t = uv_utsname_s;
3572pub type uv_statfs_t = uv_statfs_s;
3573#[repr(u32)]
3574#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
3575pub enum uv_loop_option {
3576 UV_LOOP_BLOCK_SIGNAL = 0,
3577 UV_METRICS_IDLE_TIME = 1,
3578}
3579#[repr(u32)]
3580#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
3581pub enum uv_run_mode {
3582 UV_RUN_DEFAULT = 0,
3583 UV_RUN_ONCE = 1,
3584 UV_RUN_NOWAIT = 2,
3585}
3586extern "C" {
3587 pub fn uv_version() -> ::std::os::raw::c_uint;
3588}
3589extern "C" {
3590 pub fn uv_version_string() -> *const ::std::os::raw::c_char;
3591}
3592pub type uv_malloc_func =
3593 ::std::option::Option<unsafe extern "C" fn(size: size_t) -> *mut ::std::os::raw::c_void>;
3594pub type uv_realloc_func = ::std::option::Option<
3595 unsafe extern "C" fn(
3596 ptr: *mut ::std::os::raw::c_void,
3597 size: size_t,
3598 ) -> *mut ::std::os::raw::c_void,
3599>;
3600pub type uv_calloc_func = ::std::option::Option<
3601 unsafe extern "C" fn(count: size_t, size: size_t) -> *mut ::std::os::raw::c_void,
3602>;
3603pub type uv_free_func =
3604 ::std::option::Option<unsafe extern "C" fn(ptr: *mut ::std::os::raw::c_void)>;
3605extern "C" {
3606 pub fn uv_library_shutdown();
3607}
3608extern "C" {
3609 pub fn uv_replace_allocator(
3610 malloc_func: uv_malloc_func,
3611 realloc_func: uv_realloc_func,
3612 calloc_func: uv_calloc_func,
3613 free_func: uv_free_func,
3614 ) -> ::std::os::raw::c_int;
3615}
3616extern "C" {
3617 pub fn uv_default_loop() -> *mut uv_loop_t;
3618}
3619extern "C" {
3620 pub fn uv_loop_init(loop_: *mut uv_loop_t) -> ::std::os::raw::c_int;
3621}
3622extern "C" {
3623 pub fn uv_loop_close(loop_: *mut uv_loop_t) -> ::std::os::raw::c_int;
3624}
3625extern "C" {
3626 pub fn uv_loop_new() -> *mut uv_loop_t;
3627}
3628extern "C" {
3629 pub fn uv_loop_delete(arg1: *mut uv_loop_t);
3630}
3631extern "C" {
3632 pub fn uv_loop_size() -> size_t;
3633}
3634extern "C" {
3635 pub fn uv_loop_alive(loop_: *const uv_loop_t) -> ::std::os::raw::c_int;
3636}
3637extern "C" {
3638 pub fn uv_loop_configure(
3639 loop_: *mut uv_loop_t,
3640 option: uv_loop_option,
3641 ...
3642 ) -> ::std::os::raw::c_int;
3643}
3644extern "C" {
3645 pub fn uv_loop_fork(loop_: *mut uv_loop_t) -> ::std::os::raw::c_int;
3646}
3647extern "C" {
3648 pub fn uv_run(arg1: *mut uv_loop_t, mode: uv_run_mode) -> ::std::os::raw::c_int;
3649}
3650extern "C" {
3651 pub fn uv_stop(arg1: *mut uv_loop_t);
3652}
3653extern "C" {
3654 pub fn uv_ref(arg1: *mut uv_handle_t);
3655}
3656extern "C" {
3657 pub fn uv_unref(arg1: *mut uv_handle_t);
3658}
3659extern "C" {
3660 pub fn uv_has_ref(arg1: *const uv_handle_t) -> ::std::os::raw::c_int;
3661}
3662extern "C" {
3663 pub fn uv_update_time(arg1: *mut uv_loop_t);
3664}
3665extern "C" {
3666 pub fn uv_now(arg1: *const uv_loop_t) -> u64;
3667}
3668extern "C" {
3669 pub fn uv_backend_fd(arg1: *const uv_loop_t) -> ::std::os::raw::c_int;
3670}
3671extern "C" {
3672 pub fn uv_backend_timeout(arg1: *const uv_loop_t) -> ::std::os::raw::c_int;
3673}
3674pub type uv_alloc_cb = ::std::option::Option<
3675 unsafe extern "C" fn(handle: *mut uv_handle_t, suggested_size: size_t, buf: *mut uv_buf_t),
3676>;
3677pub type uv_read_cb = ::std::option::Option<
3678 unsafe extern "C" fn(stream: *mut uv_stream_t, nread: ssize_t, buf: *const uv_buf_t),
3679>;
3680pub type uv_write_cb = ::std::option::Option<
3681 unsafe extern "C" fn(req: *mut uv_write_t, status: ::std::os::raw::c_int),
3682>;
3683pub type uv_connect_cb = ::std::option::Option<
3684 unsafe extern "C" fn(req: *mut uv_connect_t, status: ::std::os::raw::c_int),
3685>;
3686pub type uv_shutdown_cb = ::std::option::Option<
3687 unsafe extern "C" fn(req: *mut uv_shutdown_t, status: ::std::os::raw::c_int),
3688>;
3689pub type uv_connection_cb = ::std::option::Option<
3690 unsafe extern "C" fn(server: *mut uv_stream_t, status: ::std::os::raw::c_int),
3691>;
3692pub type uv_close_cb = ::std::option::Option<unsafe extern "C" fn(handle: *mut uv_handle_t)>;
3693pub type uv_poll_cb = ::std::option::Option<
3694 unsafe extern "C" fn(
3695 handle: *mut uv_poll_t,
3696 status: ::std::os::raw::c_int,
3697 events: ::std::os::raw::c_int,
3698 ),
3699>;
3700pub type uv_timer_cb = ::std::option::Option<unsafe extern "C" fn(handle: *mut uv_timer_t)>;
3701pub type uv_async_cb = ::std::option::Option<unsafe extern "C" fn(handle: *mut uv_async_t)>;
3702pub type uv_prepare_cb = ::std::option::Option<unsafe extern "C" fn(handle: *mut uv_prepare_t)>;
3703pub type uv_check_cb = ::std::option::Option<unsafe extern "C" fn(handle: *mut uv_check_t)>;
3704pub type uv_idle_cb = ::std::option::Option<unsafe extern "C" fn(handle: *mut uv_idle_t)>;
3705pub type uv_exit_cb = ::std::option::Option<
3706 unsafe extern "C" fn(
3707 arg1: *mut uv_process_t,
3708 exit_status: i64,
3709 term_signal: ::std::os::raw::c_int,
3710 ),
3711>;
3712pub type uv_walk_cb = ::std::option::Option<
3713 unsafe extern "C" fn(handle: *mut uv_handle_t, arg: *mut ::std::os::raw::c_void),
3714>;
3715pub type uv_fs_cb = ::std::option::Option<unsafe extern "C" fn(req: *mut uv_fs_t)>;
3716pub type uv_work_cb = ::std::option::Option<unsafe extern "C" fn(req: *mut uv_work_t)>;
3717pub type uv_after_work_cb =
3718 ::std::option::Option<unsafe extern "C" fn(req: *mut uv_work_t, status: ::std::os::raw::c_int)>;
3719pub type uv_getaddrinfo_cb = ::std::option::Option<
3720 unsafe extern "C" fn(
3721 req: *mut uv_getaddrinfo_t,
3722 status: ::std::os::raw::c_int,
3723 res: *mut addrinfo,
3724 ),
3725>;
3726pub type uv_getnameinfo_cb = ::std::option::Option<
3727 unsafe extern "C" fn(
3728 req: *mut uv_getnameinfo_t,
3729 status: ::std::os::raw::c_int,
3730 hostname: *const ::std::os::raw::c_char,
3731 service: *const ::std::os::raw::c_char,
3732 ),
3733>;
3734pub type uv_random_cb = ::std::option::Option<
3735 unsafe extern "C" fn(
3736 req: *mut uv_random_t,
3737 status: ::std::os::raw::c_int,
3738 buf: *mut ::std::os::raw::c_void,
3739 buflen: size_t,
3740 ),
3741>;
3742#[repr(C)]
3743#[derive(Debug, Default, Copy, Clone)]
3744pub struct uv_timespec_t {
3745 pub tv_sec: ::std::os::raw::c_long,
3746 pub tv_nsec: ::std::os::raw::c_long,
3747}
3748#[test]
3749fn bindgen_test_layout_uv_timespec_t() {
3750 assert_eq!(
3751 ::std::mem::size_of::<uv_timespec_t>(),
3752 16usize,
3753 concat!("Size of: ", stringify!(uv_timespec_t))
3754 );
3755 assert_eq!(
3756 ::std::mem::align_of::<uv_timespec_t>(),
3757 8usize,
3758 concat!("Alignment of ", stringify!(uv_timespec_t))
3759 );
3760 assert_eq!(
3761 unsafe { &(*(::std::ptr::null::<uv_timespec_t>())).tv_sec as *const _ as usize },
3762 0usize,
3763 concat!(
3764 "Offset of field: ",
3765 stringify!(uv_timespec_t),
3766 "::",
3767 stringify!(tv_sec)
3768 )
3769 );
3770 assert_eq!(
3771 unsafe { &(*(::std::ptr::null::<uv_timespec_t>())).tv_nsec as *const _ as usize },
3772 8usize,
3773 concat!(
3774 "Offset of field: ",
3775 stringify!(uv_timespec_t),
3776 "::",
3777 stringify!(tv_nsec)
3778 )
3779 );
3780}
3781#[repr(C)]
3782#[derive(Debug, Default, Copy, Clone)]
3783pub struct uv_stat_t {
3784 pub st_dev: u64,
3785 pub st_mode: u64,
3786 pub st_nlink: u64,
3787 pub st_uid: u64,
3788 pub st_gid: u64,
3789 pub st_rdev: u64,
3790 pub st_ino: u64,
3791 pub st_size: u64,
3792 pub st_blksize: u64,
3793 pub st_blocks: u64,
3794 pub st_flags: u64,
3795 pub st_gen: u64,
3796 pub st_atim: uv_timespec_t,
3797 pub st_mtim: uv_timespec_t,
3798 pub st_ctim: uv_timespec_t,
3799 pub st_birthtim: uv_timespec_t,
3800}
3801#[test]
3802fn bindgen_test_layout_uv_stat_t() {
3803 assert_eq!(
3804 ::std::mem::size_of::<uv_stat_t>(),
3805 160usize,
3806 concat!("Size of: ", stringify!(uv_stat_t))
3807 );
3808 assert_eq!(
3809 ::std::mem::align_of::<uv_stat_t>(),
3810 8usize,
3811 concat!("Alignment of ", stringify!(uv_stat_t))
3812 );
3813 assert_eq!(
3814 unsafe { &(*(::std::ptr::null::<uv_stat_t>())).st_dev as *const _ as usize },
3815 0usize,
3816 concat!(
3817 "Offset of field: ",
3818 stringify!(uv_stat_t),
3819 "::",
3820 stringify!(st_dev)
3821 )
3822 );
3823 assert_eq!(
3824 unsafe { &(*(::std::ptr::null::<uv_stat_t>())).st_mode as *const _ as usize },
3825 8usize,
3826 concat!(
3827 "Offset of field: ",
3828 stringify!(uv_stat_t),
3829 "::",
3830 stringify!(st_mode)
3831 )
3832 );
3833 assert_eq!(
3834 unsafe { &(*(::std::ptr::null::<uv_stat_t>())).st_nlink as *const _ as usize },
3835 16usize,
3836 concat!(
3837 "Offset of field: ",
3838 stringify!(uv_stat_t),
3839 "::",
3840 stringify!(st_nlink)
3841 )
3842 );
3843 assert_eq!(
3844 unsafe { &(*(::std::ptr::null::<uv_stat_t>())).st_uid as *const _ as usize },
3845 24usize,
3846 concat!(
3847 "Offset of field: ",
3848 stringify!(uv_stat_t),
3849 "::",
3850 stringify!(st_uid)
3851 )
3852 );
3853 assert_eq!(
3854 unsafe { &(*(::std::ptr::null::<uv_stat_t>())).st_gid as *const _ as usize },
3855 32usize,
3856 concat!(
3857 "Offset of field: ",
3858 stringify!(uv_stat_t),
3859 "::",
3860 stringify!(st_gid)
3861 )
3862 );
3863 assert_eq!(
3864 unsafe { &(*(::std::ptr::null::<uv_stat_t>())).st_rdev as *const _ as usize },
3865 40usize,
3866 concat!(
3867 "Offset of field: ",
3868 stringify!(uv_stat_t),
3869 "::",
3870 stringify!(st_rdev)
3871 )
3872 );
3873 assert_eq!(
3874 unsafe { &(*(::std::ptr::null::<uv_stat_t>())).st_ino as *const _ as usize },
3875 48usize,
3876 concat!(
3877 "Offset of field: ",
3878 stringify!(uv_stat_t),
3879 "::",
3880 stringify!(st_ino)
3881 )
3882 );
3883 assert_eq!(
3884 unsafe { &(*(::std::ptr::null::<uv_stat_t>())).st_size as *const _ as usize },
3885 56usize,
3886 concat!(
3887 "Offset of field: ",
3888 stringify!(uv_stat_t),
3889 "::",
3890 stringify!(st_size)
3891 )
3892 );
3893 assert_eq!(
3894 unsafe { &(*(::std::ptr::null::<uv_stat_t>())).st_blksize as *const _ as usize },
3895 64usize,
3896 concat!(
3897 "Offset of field: ",
3898 stringify!(uv_stat_t),
3899 "::",
3900 stringify!(st_blksize)
3901 )
3902 );
3903 assert_eq!(
3904 unsafe { &(*(::std::ptr::null::<uv_stat_t>())).st_blocks as *const _ as usize },
3905 72usize,
3906 concat!(
3907 "Offset of field: ",
3908 stringify!(uv_stat_t),
3909 "::",
3910 stringify!(st_blocks)
3911 )
3912 );
3913 assert_eq!(
3914 unsafe { &(*(::std::ptr::null::<uv_stat_t>())).st_flags as *const _ as usize },
3915 80usize,
3916 concat!(
3917 "Offset of field: ",
3918 stringify!(uv_stat_t),
3919 "::",
3920 stringify!(st_flags)
3921 )
3922 );
3923 assert_eq!(
3924 unsafe { &(*(::std::ptr::null::<uv_stat_t>())).st_gen as *const _ as usize },
3925 88usize,
3926 concat!(
3927 "Offset of field: ",
3928 stringify!(uv_stat_t),
3929 "::",
3930 stringify!(st_gen)
3931 )
3932 );
3933 assert_eq!(
3934 unsafe { &(*(::std::ptr::null::<uv_stat_t>())).st_atim as *const _ as usize },
3935 96usize,
3936 concat!(
3937 "Offset of field: ",
3938 stringify!(uv_stat_t),
3939 "::",
3940 stringify!(st_atim)
3941 )
3942 );
3943 assert_eq!(
3944 unsafe { &(*(::std::ptr::null::<uv_stat_t>())).st_mtim as *const _ as usize },
3945 112usize,
3946 concat!(
3947 "Offset of field: ",
3948 stringify!(uv_stat_t),
3949 "::",
3950 stringify!(st_mtim)
3951 )
3952 );
3953 assert_eq!(
3954 unsafe { &(*(::std::ptr::null::<uv_stat_t>())).st_ctim as *const _ as usize },
3955 128usize,
3956 concat!(
3957 "Offset of field: ",
3958 stringify!(uv_stat_t),
3959 "::",
3960 stringify!(st_ctim)
3961 )
3962 );
3963 assert_eq!(
3964 unsafe { &(*(::std::ptr::null::<uv_stat_t>())).st_birthtim as *const _ as usize },
3965 144usize,
3966 concat!(
3967 "Offset of field: ",
3968 stringify!(uv_stat_t),
3969 "::",
3970 stringify!(st_birthtim)
3971 )
3972 );
3973}
3974pub type uv_fs_event_cb = ::std::option::Option<
3975 unsafe extern "C" fn(
3976 handle: *mut uv_fs_event_t,
3977 filename: *const ::std::os::raw::c_char,
3978 events: ::std::os::raw::c_int,
3979 status: ::std::os::raw::c_int,
3980 ),
3981>;
3982pub type uv_fs_poll_cb = ::std::option::Option<
3983 unsafe extern "C" fn(
3984 handle: *mut uv_fs_poll_t,
3985 status: ::std::os::raw::c_int,
3986 prev: *const uv_stat_t,
3987 curr: *const uv_stat_t,
3988 ),
3989>;
3990pub type uv_signal_cb = ::std::option::Option<
3991 unsafe extern "C" fn(handle: *mut uv_signal_t, signum: ::std::os::raw::c_int),
3992>;
3993#[repr(u32)]
3994#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
3995pub enum uv_membership {
3996 UV_LEAVE_GROUP = 0,
3997 UV_JOIN_GROUP = 1,
3998}
3999extern "C" {
4000 pub fn uv_translate_sys_error(sys_errno: ::std::os::raw::c_int) -> ::std::os::raw::c_int;
4001}
4002extern "C" {
4003 pub fn uv_strerror(err: ::std::os::raw::c_int) -> *const ::std::os::raw::c_char;
4004}
4005extern "C" {
4006 pub fn uv_strerror_r(
4007 err: ::std::os::raw::c_int,
4008 buf: *mut ::std::os::raw::c_char,
4009 buflen: size_t,
4010 ) -> *mut ::std::os::raw::c_char;
4011}
4012extern "C" {
4013 pub fn uv_err_name(err: ::std::os::raw::c_int) -> *const ::std::os::raw::c_char;
4014}
4015extern "C" {
4016 pub fn uv_err_name_r(
4017 err: ::std::os::raw::c_int,
4018 buf: *mut ::std::os::raw::c_char,
4019 buflen: size_t,
4020 ) -> *mut ::std::os::raw::c_char;
4021}
4022#[repr(C)]
4023#[derive(Debug, Copy, Clone)]
4024pub struct uv_req_s {
4025 pub data: *mut ::std::os::raw::c_void,
4026 pub type_: uv_req_type,
4027 pub reserved: [*mut ::std::os::raw::c_void; 6usize],
4028}
4029#[test]
4030fn bindgen_test_layout_uv_req_s() {
4031 assert_eq!(
4032 ::std::mem::size_of::<uv_req_s>(),
4033 64usize,
4034 concat!("Size of: ", stringify!(uv_req_s))
4035 );
4036 assert_eq!(
4037 ::std::mem::align_of::<uv_req_s>(),
4038 8usize,
4039 concat!("Alignment of ", stringify!(uv_req_s))
4040 );
4041 assert_eq!(
4042 unsafe { &(*(::std::ptr::null::<uv_req_s>())).data as *const _ as usize },
4043 0usize,
4044 concat!(
4045 "Offset of field: ",
4046 stringify!(uv_req_s),
4047 "::",
4048 stringify!(data)
4049 )
4050 );
4051 assert_eq!(
4052 unsafe { &(*(::std::ptr::null::<uv_req_s>())).type_ as *const _ as usize },
4053 8usize,
4054 concat!(
4055 "Offset of field: ",
4056 stringify!(uv_req_s),
4057 "::",
4058 stringify!(type_)
4059 )
4060 );
4061 assert_eq!(
4062 unsafe { &(*(::std::ptr::null::<uv_req_s>())).reserved as *const _ as usize },
4063 16usize,
4064 concat!(
4065 "Offset of field: ",
4066 stringify!(uv_req_s),
4067 "::",
4068 stringify!(reserved)
4069 )
4070 );
4071}
4072impl Default for uv_req_s {
4073 fn default() -> Self {
4074 unsafe { ::std::mem::zeroed() }
4075 }
4076}
4077extern "C" {
4078 pub fn uv_shutdown(
4079 req: *mut uv_shutdown_t,
4080 handle: *mut uv_stream_t,
4081 cb: uv_shutdown_cb,
4082 ) -> ::std::os::raw::c_int;
4083}
4084#[repr(C)]
4085#[derive(Debug, Copy, Clone)]
4086pub struct uv_shutdown_s {
4087 pub data: *mut ::std::os::raw::c_void,
4088 pub type_: uv_req_type,
4089 pub reserved: [*mut ::std::os::raw::c_void; 6usize],
4090 pub handle: *mut uv_stream_t,
4091 pub cb: uv_shutdown_cb,
4092}
4093#[test]
4094fn bindgen_test_layout_uv_shutdown_s() {
4095 assert_eq!(
4096 ::std::mem::size_of::<uv_shutdown_s>(),
4097 80usize,
4098 concat!("Size of: ", stringify!(uv_shutdown_s))
4099 );
4100 assert_eq!(
4101 ::std::mem::align_of::<uv_shutdown_s>(),
4102 8usize,
4103 concat!("Alignment of ", stringify!(uv_shutdown_s))
4104 );
4105 assert_eq!(
4106 unsafe { &(*(::std::ptr::null::<uv_shutdown_s>())).data as *const _ as usize },
4107 0usize,
4108 concat!(
4109 "Offset of field: ",
4110 stringify!(uv_shutdown_s),
4111 "::",
4112 stringify!(data)
4113 )
4114 );
4115 assert_eq!(
4116 unsafe { &(*(::std::ptr::null::<uv_shutdown_s>())).type_ as *const _ as usize },
4117 8usize,
4118 concat!(
4119 "Offset of field: ",
4120 stringify!(uv_shutdown_s),
4121 "::",
4122 stringify!(type_)
4123 )
4124 );
4125 assert_eq!(
4126 unsafe { &(*(::std::ptr::null::<uv_shutdown_s>())).reserved as *const _ as usize },
4127 16usize,
4128 concat!(
4129 "Offset of field: ",
4130 stringify!(uv_shutdown_s),
4131 "::",
4132 stringify!(reserved)
4133 )
4134 );
4135 assert_eq!(
4136 unsafe { &(*(::std::ptr::null::<uv_shutdown_s>())).handle as *const _ as usize },
4137 64usize,
4138 concat!(
4139 "Offset of field: ",
4140 stringify!(uv_shutdown_s),
4141 "::",
4142 stringify!(handle)
4143 )
4144 );
4145 assert_eq!(
4146 unsafe { &(*(::std::ptr::null::<uv_shutdown_s>())).cb as *const _ as usize },
4147 72usize,
4148 concat!(
4149 "Offset of field: ",
4150 stringify!(uv_shutdown_s),
4151 "::",
4152 stringify!(cb)
4153 )
4154 );
4155}
4156impl Default for uv_shutdown_s {
4157 fn default() -> Self {
4158 unsafe { ::std::mem::zeroed() }
4159 }
4160}
4161#[repr(C)]
4162#[derive(Copy, Clone)]
4163pub struct uv_handle_s {
4164 pub data: *mut ::std::os::raw::c_void,
4165 pub loop_: *mut uv_loop_t,
4166 pub type_: uv_handle_type,
4167 pub close_cb: uv_close_cb,
4168 pub handle_queue: [*mut ::std::os::raw::c_void; 2usize],
4169 pub u: uv_handle_s__bindgen_ty_1,
4170 pub next_closing: *mut uv_handle_t,
4171 pub flags: ::std::os::raw::c_uint,
4172}
4173#[repr(C)]
4174#[derive(Copy, Clone)]
4175pub union uv_handle_s__bindgen_ty_1 {
4176 pub fd: ::std::os::raw::c_int,
4177 pub reserved: [*mut ::std::os::raw::c_void; 4usize],
4178 _bindgen_union_align: [u64; 4usize],
4179}
4180#[test]
4181fn bindgen_test_layout_uv_handle_s__bindgen_ty_1() {
4182 assert_eq!(
4183 ::std::mem::size_of::<uv_handle_s__bindgen_ty_1>(),
4184 32usize,
4185 concat!("Size of: ", stringify!(uv_handle_s__bindgen_ty_1))
4186 );
4187 assert_eq!(
4188 ::std::mem::align_of::<uv_handle_s__bindgen_ty_1>(),
4189 8usize,
4190 concat!("Alignment of ", stringify!(uv_handle_s__bindgen_ty_1))
4191 );
4192 assert_eq!(
4193 unsafe { &(*(::std::ptr::null::<uv_handle_s__bindgen_ty_1>())).fd as *const _ as usize },
4194 0usize,
4195 concat!(
4196 "Offset of field: ",
4197 stringify!(uv_handle_s__bindgen_ty_1),
4198 "::",
4199 stringify!(fd)
4200 )
4201 );
4202 assert_eq!(
4203 unsafe {
4204 &(*(::std::ptr::null::<uv_handle_s__bindgen_ty_1>())).reserved as *const _ as usize
4205 },
4206 0usize,
4207 concat!(
4208 "Offset of field: ",
4209 stringify!(uv_handle_s__bindgen_ty_1),
4210 "::",
4211 stringify!(reserved)
4212 )
4213 );
4214}
4215impl Default for uv_handle_s__bindgen_ty_1 {
4216 fn default() -> Self {
4217 unsafe { ::std::mem::zeroed() }
4218 }
4219}
4220#[test]
4221fn bindgen_test_layout_uv_handle_s() {
4222 assert_eq!(
4223 ::std::mem::size_of::<uv_handle_s>(),
4224 96usize,
4225 concat!("Size of: ", stringify!(uv_handle_s))
4226 );
4227 assert_eq!(
4228 ::std::mem::align_of::<uv_handle_s>(),
4229 8usize,
4230 concat!("Alignment of ", stringify!(uv_handle_s))
4231 );
4232 assert_eq!(
4233 unsafe { &(*(::std::ptr::null::<uv_handle_s>())).data as *const _ as usize },
4234 0usize,
4235 concat!(
4236 "Offset of field: ",
4237 stringify!(uv_handle_s),
4238 "::",
4239 stringify!(data)
4240 )
4241 );
4242 assert_eq!(
4243 unsafe { &(*(::std::ptr::null::<uv_handle_s>())).loop_ as *const _ as usize },
4244 8usize,
4245 concat!(
4246 "Offset of field: ",
4247 stringify!(uv_handle_s),
4248 "::",
4249 stringify!(loop_)
4250 )
4251 );
4252 assert_eq!(
4253 unsafe { &(*(::std::ptr::null::<uv_handle_s>())).type_ as *const _ as usize },
4254 16usize,
4255 concat!(
4256 "Offset of field: ",
4257 stringify!(uv_handle_s),
4258 "::",
4259 stringify!(type_)
4260 )
4261 );
4262 assert_eq!(
4263 unsafe { &(*(::std::ptr::null::<uv_handle_s>())).close_cb as *const _ as usize },
4264 24usize,
4265 concat!(
4266 "Offset of field: ",
4267 stringify!(uv_handle_s),
4268 "::",
4269 stringify!(close_cb)
4270 )
4271 );
4272 assert_eq!(
4273 unsafe { &(*(::std::ptr::null::<uv_handle_s>())).handle_queue as *const _ as usize },
4274 32usize,
4275 concat!(
4276 "Offset of field: ",
4277 stringify!(uv_handle_s),
4278 "::",
4279 stringify!(handle_queue)
4280 )
4281 );
4282 assert_eq!(
4283 unsafe { &(*(::std::ptr::null::<uv_handle_s>())).u as *const _ as usize },
4284 48usize,
4285 concat!(
4286 "Offset of field: ",
4287 stringify!(uv_handle_s),
4288 "::",
4289 stringify!(u)
4290 )
4291 );
4292 assert_eq!(
4293 unsafe { &(*(::std::ptr::null::<uv_handle_s>())).next_closing as *const _ as usize },
4294 80usize,
4295 concat!(
4296 "Offset of field: ",
4297 stringify!(uv_handle_s),
4298 "::",
4299 stringify!(next_closing)
4300 )
4301 );
4302 assert_eq!(
4303 unsafe { &(*(::std::ptr::null::<uv_handle_s>())).flags as *const _ as usize },
4304 88usize,
4305 concat!(
4306 "Offset of field: ",
4307 stringify!(uv_handle_s),
4308 "::",
4309 stringify!(flags)
4310 )
4311 );
4312}
4313impl Default for uv_handle_s {
4314 fn default() -> Self {
4315 unsafe { ::std::mem::zeroed() }
4316 }
4317}
4318extern "C" {
4319 pub fn uv_handle_size(type_: uv_handle_type) -> size_t;
4320}
4321extern "C" {
4322 pub fn uv_handle_get_type(handle: *const uv_handle_t) -> uv_handle_type;
4323}
4324extern "C" {
4325 pub fn uv_handle_type_name(type_: uv_handle_type) -> *const ::std::os::raw::c_char;
4326}
4327extern "C" {
4328 pub fn uv_handle_get_data(handle: *const uv_handle_t) -> *mut ::std::os::raw::c_void;
4329}
4330extern "C" {
4331 pub fn uv_handle_get_loop(handle: *const uv_handle_t) -> *mut uv_loop_t;
4332}
4333extern "C" {
4334 pub fn uv_handle_set_data(handle: *mut uv_handle_t, data: *mut ::std::os::raw::c_void);
4335}
4336extern "C" {
4337 pub fn uv_req_size(type_: uv_req_type) -> size_t;
4338}
4339extern "C" {
4340 pub fn uv_req_get_data(req: *const uv_req_t) -> *mut ::std::os::raw::c_void;
4341}
4342extern "C" {
4343 pub fn uv_req_set_data(req: *mut uv_req_t, data: *mut ::std::os::raw::c_void);
4344}
4345extern "C" {
4346 pub fn uv_req_get_type(req: *const uv_req_t) -> uv_req_type;
4347}
4348extern "C" {
4349 pub fn uv_req_type_name(type_: uv_req_type) -> *const ::std::os::raw::c_char;
4350}
4351extern "C" {
4352 pub fn uv_is_active(handle: *const uv_handle_t) -> ::std::os::raw::c_int;
4353}
4354extern "C" {
4355 pub fn uv_walk(loop_: *mut uv_loop_t, walk_cb: uv_walk_cb, arg: *mut ::std::os::raw::c_void);
4356}
4357extern "C" {
4358 pub fn uv_print_all_handles(loop_: *mut uv_loop_t, stream: *mut FILE);
4359}
4360extern "C" {
4361 pub fn uv_print_active_handles(loop_: *mut uv_loop_t, stream: *mut FILE);
4362}
4363extern "C" {
4364 pub fn uv_close(handle: *mut uv_handle_t, close_cb: uv_close_cb);
4365}
4366extern "C" {
4367 pub fn uv_send_buffer_size(
4368 handle: *mut uv_handle_t,
4369 value: *mut ::std::os::raw::c_int,
4370 ) -> ::std::os::raw::c_int;
4371}
4372extern "C" {
4373 pub fn uv_recv_buffer_size(
4374 handle: *mut uv_handle_t,
4375 value: *mut ::std::os::raw::c_int,
4376 ) -> ::std::os::raw::c_int;
4377}
4378extern "C" {
4379 pub fn uv_fileno(handle: *const uv_handle_t, fd: *mut uv_os_fd_t) -> ::std::os::raw::c_int;
4380}
4381extern "C" {
4382 pub fn uv_buf_init(base: *mut ::std::os::raw::c_char, len: ::std::os::raw::c_uint) -> uv_buf_t;
4383}
4384extern "C" {
4385 pub fn uv_pipe(
4386 fds: *mut uv_file,
4387 read_flags: ::std::os::raw::c_int,
4388 write_flags: ::std::os::raw::c_int,
4389 ) -> ::std::os::raw::c_int;
4390}
4391extern "C" {
4392 pub fn uv_socketpair(
4393 type_: ::std::os::raw::c_int,
4394 protocol: ::std::os::raw::c_int,
4395 socket_vector: *mut uv_os_sock_t,
4396 flags0: ::std::os::raw::c_int,
4397 flags1: ::std::os::raw::c_int,
4398 ) -> ::std::os::raw::c_int;
4399}
4400#[repr(C)]
4401#[derive(Copy, Clone)]
4402pub struct uv_stream_s {
4403 pub data: *mut ::std::os::raw::c_void,
4404 pub loop_: *mut uv_loop_t,
4405 pub type_: uv_handle_type,
4406 pub close_cb: uv_close_cb,
4407 pub handle_queue: [*mut ::std::os::raw::c_void; 2usize],
4408 pub u: uv_stream_s__bindgen_ty_1,
4409 pub next_closing: *mut uv_handle_t,
4410 pub flags: ::std::os::raw::c_uint,
4411 pub write_queue_size: size_t,
4412 pub alloc_cb: uv_alloc_cb,
4413 pub read_cb: uv_read_cb,
4414 pub connect_req: *mut uv_connect_t,
4415 pub shutdown_req: *mut uv_shutdown_t,
4416 pub io_watcher: uv__io_t,
4417 pub write_queue: [*mut ::std::os::raw::c_void; 2usize],
4418 pub write_completed_queue: [*mut ::std::os::raw::c_void; 2usize],
4419 pub connection_cb: uv_connection_cb,
4420 pub delayed_error: ::std::os::raw::c_int,
4421 pub accepted_fd: ::std::os::raw::c_int,
4422 pub queued_fds: *mut ::std::os::raw::c_void,
4423 pub select: *mut ::std::os::raw::c_void,
4424}
4425#[repr(C)]
4426#[derive(Copy, Clone)]
4427pub union uv_stream_s__bindgen_ty_1 {
4428 pub fd: ::std::os::raw::c_int,
4429 pub reserved: [*mut ::std::os::raw::c_void; 4usize],
4430 _bindgen_union_align: [u64; 4usize],
4431}
4432#[test]
4433fn bindgen_test_layout_uv_stream_s__bindgen_ty_1() {
4434 assert_eq!(
4435 ::std::mem::size_of::<uv_stream_s__bindgen_ty_1>(),
4436 32usize,
4437 concat!("Size of: ", stringify!(uv_stream_s__bindgen_ty_1))
4438 );
4439 assert_eq!(
4440 ::std::mem::align_of::<uv_stream_s__bindgen_ty_1>(),
4441 8usize,
4442 concat!("Alignment of ", stringify!(uv_stream_s__bindgen_ty_1))
4443 );
4444 assert_eq!(
4445 unsafe { &(*(::std::ptr::null::<uv_stream_s__bindgen_ty_1>())).fd as *const _ as usize },
4446 0usize,
4447 concat!(
4448 "Offset of field: ",
4449 stringify!(uv_stream_s__bindgen_ty_1),
4450 "::",
4451 stringify!(fd)
4452 )
4453 );
4454 assert_eq!(
4455 unsafe {
4456 &(*(::std::ptr::null::<uv_stream_s__bindgen_ty_1>())).reserved as *const _ as usize
4457 },
4458 0usize,
4459 concat!(
4460 "Offset of field: ",
4461 stringify!(uv_stream_s__bindgen_ty_1),
4462 "::",
4463 stringify!(reserved)
4464 )
4465 );
4466}
4467impl Default for uv_stream_s__bindgen_ty_1 {
4468 fn default() -> Self {
4469 unsafe { ::std::mem::zeroed() }
4470 }
4471}
4472#[test]
4473fn bindgen_test_layout_uv_stream_s() {
4474 assert_eq!(
4475 ::std::mem::size_of::<uv_stream_s>(),
4476 264usize,
4477 concat!("Size of: ", stringify!(uv_stream_s))
4478 );
4479 assert_eq!(
4480 ::std::mem::align_of::<uv_stream_s>(),
4481 8usize,
4482 concat!("Alignment of ", stringify!(uv_stream_s))
4483 );
4484 assert_eq!(
4485 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).data as *const _ as usize },
4486 0usize,
4487 concat!(
4488 "Offset of field: ",
4489 stringify!(uv_stream_s),
4490 "::",
4491 stringify!(data)
4492 )
4493 );
4494 assert_eq!(
4495 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).loop_ as *const _ as usize },
4496 8usize,
4497 concat!(
4498 "Offset of field: ",
4499 stringify!(uv_stream_s),
4500 "::",
4501 stringify!(loop_)
4502 )
4503 );
4504 assert_eq!(
4505 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).type_ as *const _ as usize },
4506 16usize,
4507 concat!(
4508 "Offset of field: ",
4509 stringify!(uv_stream_s),
4510 "::",
4511 stringify!(type_)
4512 )
4513 );
4514 assert_eq!(
4515 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).close_cb as *const _ as usize },
4516 24usize,
4517 concat!(
4518 "Offset of field: ",
4519 stringify!(uv_stream_s),
4520 "::",
4521 stringify!(close_cb)
4522 )
4523 );
4524 assert_eq!(
4525 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).handle_queue as *const _ as usize },
4526 32usize,
4527 concat!(
4528 "Offset of field: ",
4529 stringify!(uv_stream_s),
4530 "::",
4531 stringify!(handle_queue)
4532 )
4533 );
4534 assert_eq!(
4535 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).u as *const _ as usize },
4536 48usize,
4537 concat!(
4538 "Offset of field: ",
4539 stringify!(uv_stream_s),
4540 "::",
4541 stringify!(u)
4542 )
4543 );
4544 assert_eq!(
4545 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).next_closing as *const _ as usize },
4546 80usize,
4547 concat!(
4548 "Offset of field: ",
4549 stringify!(uv_stream_s),
4550 "::",
4551 stringify!(next_closing)
4552 )
4553 );
4554 assert_eq!(
4555 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).flags as *const _ as usize },
4556 88usize,
4557 concat!(
4558 "Offset of field: ",
4559 stringify!(uv_stream_s),
4560 "::",
4561 stringify!(flags)
4562 )
4563 );
4564 assert_eq!(
4565 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).write_queue_size as *const _ as usize },
4566 96usize,
4567 concat!(
4568 "Offset of field: ",
4569 stringify!(uv_stream_s),
4570 "::",
4571 stringify!(write_queue_size)
4572 )
4573 );
4574 assert_eq!(
4575 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).alloc_cb as *const _ as usize },
4576 104usize,
4577 concat!(
4578 "Offset of field: ",
4579 stringify!(uv_stream_s),
4580 "::",
4581 stringify!(alloc_cb)
4582 )
4583 );
4584 assert_eq!(
4585 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).read_cb as *const _ as usize },
4586 112usize,
4587 concat!(
4588 "Offset of field: ",
4589 stringify!(uv_stream_s),
4590 "::",
4591 stringify!(read_cb)
4592 )
4593 );
4594 assert_eq!(
4595 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).connect_req as *const _ as usize },
4596 120usize,
4597 concat!(
4598 "Offset of field: ",
4599 stringify!(uv_stream_s),
4600 "::",
4601 stringify!(connect_req)
4602 )
4603 );
4604 assert_eq!(
4605 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).shutdown_req as *const _ as usize },
4606 128usize,
4607 concat!(
4608 "Offset of field: ",
4609 stringify!(uv_stream_s),
4610 "::",
4611 stringify!(shutdown_req)
4612 )
4613 );
4614 assert_eq!(
4615 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).io_watcher as *const _ as usize },
4616 136usize,
4617 concat!(
4618 "Offset of field: ",
4619 stringify!(uv_stream_s),
4620 "::",
4621 stringify!(io_watcher)
4622 )
4623 );
4624 assert_eq!(
4625 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).write_queue as *const _ as usize },
4626 200usize,
4627 concat!(
4628 "Offset of field: ",
4629 stringify!(uv_stream_s),
4630 "::",
4631 stringify!(write_queue)
4632 )
4633 );
4634 assert_eq!(
4635 unsafe {
4636 &(*(::std::ptr::null::<uv_stream_s>())).write_completed_queue as *const _ as usize
4637 },
4638 216usize,
4639 concat!(
4640 "Offset of field: ",
4641 stringify!(uv_stream_s),
4642 "::",
4643 stringify!(write_completed_queue)
4644 )
4645 );
4646 assert_eq!(
4647 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).connection_cb as *const _ as usize },
4648 232usize,
4649 concat!(
4650 "Offset of field: ",
4651 stringify!(uv_stream_s),
4652 "::",
4653 stringify!(connection_cb)
4654 )
4655 );
4656 assert_eq!(
4657 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).delayed_error as *const _ as usize },
4658 240usize,
4659 concat!(
4660 "Offset of field: ",
4661 stringify!(uv_stream_s),
4662 "::",
4663 stringify!(delayed_error)
4664 )
4665 );
4666 assert_eq!(
4667 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).accepted_fd as *const _ as usize },
4668 244usize,
4669 concat!(
4670 "Offset of field: ",
4671 stringify!(uv_stream_s),
4672 "::",
4673 stringify!(accepted_fd)
4674 )
4675 );
4676 assert_eq!(
4677 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).queued_fds as *const _ as usize },
4678 248usize,
4679 concat!(
4680 "Offset of field: ",
4681 stringify!(uv_stream_s),
4682 "::",
4683 stringify!(queued_fds)
4684 )
4685 );
4686 assert_eq!(
4687 unsafe { &(*(::std::ptr::null::<uv_stream_s>())).select as *const _ as usize },
4688 256usize,
4689 concat!(
4690 "Offset of field: ",
4691 stringify!(uv_stream_s),
4692 "::",
4693 stringify!(select)
4694 )
4695 );
4696}
4697impl Default for uv_stream_s {
4698 fn default() -> Self {
4699 unsafe { ::std::mem::zeroed() }
4700 }
4701}
4702extern "C" {
4703 pub fn uv_stream_get_write_queue_size(stream: *const uv_stream_t) -> size_t;
4704}
4705extern "C" {
4706 pub fn uv_listen(
4707 stream: *mut uv_stream_t,
4708 backlog: ::std::os::raw::c_int,
4709 cb: uv_connection_cb,
4710 ) -> ::std::os::raw::c_int;
4711}
4712extern "C" {
4713 pub fn uv_accept(server: *mut uv_stream_t, client: *mut uv_stream_t) -> ::std::os::raw::c_int;
4714}
4715extern "C" {
4716 pub fn uv_read_start(
4717 arg1: *mut uv_stream_t,
4718 alloc_cb: uv_alloc_cb,
4719 read_cb: uv_read_cb,
4720 ) -> ::std::os::raw::c_int;
4721}
4722extern "C" {
4723 pub fn uv_read_stop(arg1: *mut uv_stream_t) -> ::std::os::raw::c_int;
4724}
4725extern "C" {
4726 pub fn uv_write(
4727 req: *mut uv_write_t,
4728 handle: *mut uv_stream_t,
4729 bufs: *const uv_buf_t,
4730 nbufs: ::std::os::raw::c_uint,
4731 cb: uv_write_cb,
4732 ) -> ::std::os::raw::c_int;
4733}
4734extern "C" {
4735 pub fn uv_write2(
4736 req: *mut uv_write_t,
4737 handle: *mut uv_stream_t,
4738 bufs: *const uv_buf_t,
4739 nbufs: ::std::os::raw::c_uint,
4740 send_handle: *mut uv_stream_t,
4741 cb: uv_write_cb,
4742 ) -> ::std::os::raw::c_int;
4743}
4744extern "C" {
4745 pub fn uv_try_write(
4746 handle: *mut uv_stream_t,
4747 bufs: *const uv_buf_t,
4748 nbufs: ::std::os::raw::c_uint,
4749 ) -> ::std::os::raw::c_int;
4750}
4751#[repr(C)]
4752#[derive(Debug, Copy, Clone)]
4753pub struct uv_write_s {
4754 pub data: *mut ::std::os::raw::c_void,
4755 pub type_: uv_req_type,
4756 pub reserved: [*mut ::std::os::raw::c_void; 6usize],
4757 pub cb: uv_write_cb,
4758 pub send_handle: *mut uv_stream_t,
4759 pub handle: *mut uv_stream_t,
4760 pub queue: [*mut ::std::os::raw::c_void; 2usize],
4761 pub write_index: ::std::os::raw::c_uint,
4762 pub bufs: *mut uv_buf_t,
4763 pub nbufs: ::std::os::raw::c_uint,
4764 pub error: ::std::os::raw::c_int,
4765 pub bufsml: [uv_buf_t; 4usize],
4766}
4767#[test]
4768fn bindgen_test_layout_uv_write_s() {
4769 assert_eq!(
4770 ::std::mem::size_of::<uv_write_s>(),
4771 192usize,
4772 concat!("Size of: ", stringify!(uv_write_s))
4773 );
4774 assert_eq!(
4775 ::std::mem::align_of::<uv_write_s>(),
4776 8usize,
4777 concat!("Alignment of ", stringify!(uv_write_s))
4778 );
4779 assert_eq!(
4780 unsafe { &(*(::std::ptr::null::<uv_write_s>())).data as *const _ as usize },
4781 0usize,
4782 concat!(
4783 "Offset of field: ",
4784 stringify!(uv_write_s),
4785 "::",
4786 stringify!(data)
4787 )
4788 );
4789 assert_eq!(
4790 unsafe { &(*(::std::ptr::null::<uv_write_s>())).type_ as *const _ as usize },
4791 8usize,
4792 concat!(
4793 "Offset of field: ",
4794 stringify!(uv_write_s),
4795 "::",
4796 stringify!(type_)
4797 )
4798 );
4799 assert_eq!(
4800 unsafe { &(*(::std::ptr::null::<uv_write_s>())).reserved as *const _ as usize },
4801 16usize,
4802 concat!(
4803 "Offset of field: ",
4804 stringify!(uv_write_s),
4805 "::",
4806 stringify!(reserved)
4807 )
4808 );
4809 assert_eq!(
4810 unsafe { &(*(::std::ptr::null::<uv_write_s>())).cb as *const _ as usize },
4811 64usize,
4812 concat!(
4813 "Offset of field: ",
4814 stringify!(uv_write_s),
4815 "::",
4816 stringify!(cb)
4817 )
4818 );
4819 assert_eq!(
4820 unsafe { &(*(::std::ptr::null::<uv_write_s>())).send_handle as *const _ as usize },
4821 72usize,
4822 concat!(
4823 "Offset of field: ",
4824 stringify!(uv_write_s),
4825 "::",
4826 stringify!(send_handle)
4827 )
4828 );
4829 assert_eq!(
4830 unsafe { &(*(::std::ptr::null::<uv_write_s>())).handle as *const _ as usize },
4831 80usize,
4832 concat!(
4833 "Offset of field: ",
4834 stringify!(uv_write_s),
4835 "::",
4836 stringify!(handle)
4837 )
4838 );
4839 assert_eq!(
4840 unsafe { &(*(::std::ptr::null::<uv_write_s>())).queue as *const _ as usize },
4841 88usize,
4842 concat!(
4843 "Offset of field: ",
4844 stringify!(uv_write_s),
4845 "::",
4846 stringify!(queue)
4847 )
4848 );
4849 assert_eq!(
4850 unsafe { &(*(::std::ptr::null::<uv_write_s>())).write_index as *const _ as usize },
4851 104usize,
4852 concat!(
4853 "Offset of field: ",
4854 stringify!(uv_write_s),
4855 "::",
4856 stringify!(write_index)
4857 )
4858 );
4859 assert_eq!(
4860 unsafe { &(*(::std::ptr::null::<uv_write_s>())).bufs as *const _ as usize },
4861 112usize,
4862 concat!(
4863 "Offset of field: ",
4864 stringify!(uv_write_s),
4865 "::",
4866 stringify!(bufs)
4867 )
4868 );
4869 assert_eq!(
4870 unsafe { &(*(::std::ptr::null::<uv_write_s>())).nbufs as *const _ as usize },
4871 120usize,
4872 concat!(
4873 "Offset of field: ",
4874 stringify!(uv_write_s),
4875 "::",
4876 stringify!(nbufs)
4877 )
4878 );
4879 assert_eq!(
4880 unsafe { &(*(::std::ptr::null::<uv_write_s>())).error as *const _ as usize },
4881 124usize,
4882 concat!(
4883 "Offset of field: ",
4884 stringify!(uv_write_s),
4885 "::",
4886 stringify!(error)
4887 )
4888 );
4889 assert_eq!(
4890 unsafe { &(*(::std::ptr::null::<uv_write_s>())).bufsml as *const _ as usize },
4891 128usize,
4892 concat!(
4893 "Offset of field: ",
4894 stringify!(uv_write_s),
4895 "::",
4896 stringify!(bufsml)
4897 )
4898 );
4899}
4900impl Default for uv_write_s {
4901 fn default() -> Self {
4902 unsafe { ::std::mem::zeroed() }
4903 }
4904}
4905extern "C" {
4906 pub fn uv_is_readable(handle: *const uv_stream_t) -> ::std::os::raw::c_int;
4907}
4908extern "C" {
4909 pub fn uv_is_writable(handle: *const uv_stream_t) -> ::std::os::raw::c_int;
4910}
4911extern "C" {
4912 pub fn uv_stream_set_blocking(
4913 handle: *mut uv_stream_t,
4914 blocking: ::std::os::raw::c_int,
4915 ) -> ::std::os::raw::c_int;
4916}
4917extern "C" {
4918 pub fn uv_is_closing(handle: *const uv_handle_t) -> ::std::os::raw::c_int;
4919}
4920#[repr(C)]
4921#[derive(Copy, Clone)]
4922pub struct uv_tcp_s {
4923 pub data: *mut ::std::os::raw::c_void,
4924 pub loop_: *mut uv_loop_t,
4925 pub type_: uv_handle_type,
4926 pub close_cb: uv_close_cb,
4927 pub handle_queue: [*mut ::std::os::raw::c_void; 2usize],
4928 pub u: uv_tcp_s__bindgen_ty_1,
4929 pub next_closing: *mut uv_handle_t,
4930 pub flags: ::std::os::raw::c_uint,
4931 pub write_queue_size: size_t,
4932 pub alloc_cb: uv_alloc_cb,
4933 pub read_cb: uv_read_cb,
4934 pub connect_req: *mut uv_connect_t,
4935 pub shutdown_req: *mut uv_shutdown_t,
4936 pub io_watcher: uv__io_t,
4937 pub write_queue: [*mut ::std::os::raw::c_void; 2usize],
4938 pub write_completed_queue: [*mut ::std::os::raw::c_void; 2usize],
4939 pub connection_cb: uv_connection_cb,
4940 pub delayed_error: ::std::os::raw::c_int,
4941 pub accepted_fd: ::std::os::raw::c_int,
4942 pub queued_fds: *mut ::std::os::raw::c_void,
4943 pub select: *mut ::std::os::raw::c_void,
4944}
4945#[repr(C)]
4946#[derive(Copy, Clone)]
4947pub union uv_tcp_s__bindgen_ty_1 {
4948 pub fd: ::std::os::raw::c_int,
4949 pub reserved: [*mut ::std::os::raw::c_void; 4usize],
4950 _bindgen_union_align: [u64; 4usize],
4951}
4952#[test]
4953fn bindgen_test_layout_uv_tcp_s__bindgen_ty_1() {
4954 assert_eq!(
4955 ::std::mem::size_of::<uv_tcp_s__bindgen_ty_1>(),
4956 32usize,
4957 concat!("Size of: ", stringify!(uv_tcp_s__bindgen_ty_1))
4958 );
4959 assert_eq!(
4960 ::std::mem::align_of::<uv_tcp_s__bindgen_ty_1>(),
4961 8usize,
4962 concat!("Alignment of ", stringify!(uv_tcp_s__bindgen_ty_1))
4963 );
4964 assert_eq!(
4965 unsafe { &(*(::std::ptr::null::<uv_tcp_s__bindgen_ty_1>())).fd as *const _ as usize },
4966 0usize,
4967 concat!(
4968 "Offset of field: ",
4969 stringify!(uv_tcp_s__bindgen_ty_1),
4970 "::",
4971 stringify!(fd)
4972 )
4973 );
4974 assert_eq!(
4975 unsafe { &(*(::std::ptr::null::<uv_tcp_s__bindgen_ty_1>())).reserved as *const _ as usize },
4976 0usize,
4977 concat!(
4978 "Offset of field: ",
4979 stringify!(uv_tcp_s__bindgen_ty_1),
4980 "::",
4981 stringify!(reserved)
4982 )
4983 );
4984}
4985impl Default for uv_tcp_s__bindgen_ty_1 {
4986 fn default() -> Self {
4987 unsafe { ::std::mem::zeroed() }
4988 }
4989}
4990#[test]
4991fn bindgen_test_layout_uv_tcp_s() {
4992 assert_eq!(
4993 ::std::mem::size_of::<uv_tcp_s>(),
4994 264usize,
4995 concat!("Size of: ", stringify!(uv_tcp_s))
4996 );
4997 assert_eq!(
4998 ::std::mem::align_of::<uv_tcp_s>(),
4999 8usize,
5000 concat!("Alignment of ", stringify!(uv_tcp_s))
5001 );
5002 assert_eq!(
5003 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).data as *const _ as usize },
5004 0usize,
5005 concat!(
5006 "Offset of field: ",
5007 stringify!(uv_tcp_s),
5008 "::",
5009 stringify!(data)
5010 )
5011 );
5012 assert_eq!(
5013 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).loop_ as *const _ as usize },
5014 8usize,
5015 concat!(
5016 "Offset of field: ",
5017 stringify!(uv_tcp_s),
5018 "::",
5019 stringify!(loop_)
5020 )
5021 );
5022 assert_eq!(
5023 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).type_ as *const _ as usize },
5024 16usize,
5025 concat!(
5026 "Offset of field: ",
5027 stringify!(uv_tcp_s),
5028 "::",
5029 stringify!(type_)
5030 )
5031 );
5032 assert_eq!(
5033 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).close_cb as *const _ as usize },
5034 24usize,
5035 concat!(
5036 "Offset of field: ",
5037 stringify!(uv_tcp_s),
5038 "::",
5039 stringify!(close_cb)
5040 )
5041 );
5042 assert_eq!(
5043 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).handle_queue as *const _ as usize },
5044 32usize,
5045 concat!(
5046 "Offset of field: ",
5047 stringify!(uv_tcp_s),
5048 "::",
5049 stringify!(handle_queue)
5050 )
5051 );
5052 assert_eq!(
5053 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).u as *const _ as usize },
5054 48usize,
5055 concat!(
5056 "Offset of field: ",
5057 stringify!(uv_tcp_s),
5058 "::",
5059 stringify!(u)
5060 )
5061 );
5062 assert_eq!(
5063 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).next_closing as *const _ as usize },
5064 80usize,
5065 concat!(
5066 "Offset of field: ",
5067 stringify!(uv_tcp_s),
5068 "::",
5069 stringify!(next_closing)
5070 )
5071 );
5072 assert_eq!(
5073 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).flags as *const _ as usize },
5074 88usize,
5075 concat!(
5076 "Offset of field: ",
5077 stringify!(uv_tcp_s),
5078 "::",
5079 stringify!(flags)
5080 )
5081 );
5082 assert_eq!(
5083 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).write_queue_size as *const _ as usize },
5084 96usize,
5085 concat!(
5086 "Offset of field: ",
5087 stringify!(uv_tcp_s),
5088 "::",
5089 stringify!(write_queue_size)
5090 )
5091 );
5092 assert_eq!(
5093 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).alloc_cb as *const _ as usize },
5094 104usize,
5095 concat!(
5096 "Offset of field: ",
5097 stringify!(uv_tcp_s),
5098 "::",
5099 stringify!(alloc_cb)
5100 )
5101 );
5102 assert_eq!(
5103 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).read_cb as *const _ as usize },
5104 112usize,
5105 concat!(
5106 "Offset of field: ",
5107 stringify!(uv_tcp_s),
5108 "::",
5109 stringify!(read_cb)
5110 )
5111 );
5112 assert_eq!(
5113 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).connect_req as *const _ as usize },
5114 120usize,
5115 concat!(
5116 "Offset of field: ",
5117 stringify!(uv_tcp_s),
5118 "::",
5119 stringify!(connect_req)
5120 )
5121 );
5122 assert_eq!(
5123 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).shutdown_req as *const _ as usize },
5124 128usize,
5125 concat!(
5126 "Offset of field: ",
5127 stringify!(uv_tcp_s),
5128 "::",
5129 stringify!(shutdown_req)
5130 )
5131 );
5132 assert_eq!(
5133 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).io_watcher as *const _ as usize },
5134 136usize,
5135 concat!(
5136 "Offset of field: ",
5137 stringify!(uv_tcp_s),
5138 "::",
5139 stringify!(io_watcher)
5140 )
5141 );
5142 assert_eq!(
5143 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).write_queue as *const _ as usize },
5144 200usize,
5145 concat!(
5146 "Offset of field: ",
5147 stringify!(uv_tcp_s),
5148 "::",
5149 stringify!(write_queue)
5150 )
5151 );
5152 assert_eq!(
5153 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).write_completed_queue as *const _ as usize },
5154 216usize,
5155 concat!(
5156 "Offset of field: ",
5157 stringify!(uv_tcp_s),
5158 "::",
5159 stringify!(write_completed_queue)
5160 )
5161 );
5162 assert_eq!(
5163 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).connection_cb as *const _ as usize },
5164 232usize,
5165 concat!(
5166 "Offset of field: ",
5167 stringify!(uv_tcp_s),
5168 "::",
5169 stringify!(connection_cb)
5170 )
5171 );
5172 assert_eq!(
5173 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).delayed_error as *const _ as usize },
5174 240usize,
5175 concat!(
5176 "Offset of field: ",
5177 stringify!(uv_tcp_s),
5178 "::",
5179 stringify!(delayed_error)
5180 )
5181 );
5182 assert_eq!(
5183 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).accepted_fd as *const _ as usize },
5184 244usize,
5185 concat!(
5186 "Offset of field: ",
5187 stringify!(uv_tcp_s),
5188 "::",
5189 stringify!(accepted_fd)
5190 )
5191 );
5192 assert_eq!(
5193 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).queued_fds as *const _ as usize },
5194 248usize,
5195 concat!(
5196 "Offset of field: ",
5197 stringify!(uv_tcp_s),
5198 "::",
5199 stringify!(queued_fds)
5200 )
5201 );
5202 assert_eq!(
5203 unsafe { &(*(::std::ptr::null::<uv_tcp_s>())).select as *const _ as usize },
5204 256usize,
5205 concat!(
5206 "Offset of field: ",
5207 stringify!(uv_tcp_s),
5208 "::",
5209 stringify!(select)
5210 )
5211 );
5212}
5213impl Default for uv_tcp_s {
5214 fn default() -> Self {
5215 unsafe { ::std::mem::zeroed() }
5216 }
5217}
5218extern "C" {
5219 pub fn uv_tcp_init(arg1: *mut uv_loop_t, handle: *mut uv_tcp_t) -> ::std::os::raw::c_int;
5220}
5221extern "C" {
5222 pub fn uv_tcp_init_ex(
5223 arg1: *mut uv_loop_t,
5224 handle: *mut uv_tcp_t,
5225 flags: ::std::os::raw::c_uint,
5226 ) -> ::std::os::raw::c_int;
5227}
5228extern "C" {
5229 pub fn uv_tcp_open(handle: *mut uv_tcp_t, sock: uv_os_sock_t) -> ::std::os::raw::c_int;
5230}
5231extern "C" {
5232 pub fn uv_tcp_nodelay(
5233 handle: *mut uv_tcp_t,
5234 enable: ::std::os::raw::c_int,
5235 ) -> ::std::os::raw::c_int;
5236}
5237extern "C" {
5238 pub fn uv_tcp_keepalive(
5239 handle: *mut uv_tcp_t,
5240 enable: ::std::os::raw::c_int,
5241 delay: ::std::os::raw::c_uint,
5242 ) -> ::std::os::raw::c_int;
5243}
5244extern "C" {
5245 pub fn uv_tcp_simultaneous_accepts(
5246 handle: *mut uv_tcp_t,
5247 enable: ::std::os::raw::c_int,
5248 ) -> ::std::os::raw::c_int;
5249}
5250#[repr(u32)]
5251#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
5252pub enum uv_tcp_flags {
5253 UV_TCP_IPV6ONLY = 1,
5254}
5255extern "C" {
5256 pub fn uv_tcp_bind(
5257 handle: *mut uv_tcp_t,
5258 addr: *const sockaddr,
5259 flags: ::std::os::raw::c_uint,
5260 ) -> ::std::os::raw::c_int;
5261}
5262extern "C" {
5263 pub fn uv_tcp_getsockname(
5264 handle: *const uv_tcp_t,
5265 name: *mut sockaddr,
5266 namelen: *mut ::std::os::raw::c_int,
5267 ) -> ::std::os::raw::c_int;
5268}
5269extern "C" {
5270 pub fn uv_tcp_getpeername(
5271 handle: *const uv_tcp_t,
5272 name: *mut sockaddr,
5273 namelen: *mut ::std::os::raw::c_int,
5274 ) -> ::std::os::raw::c_int;
5275}
5276extern "C" {
5277 pub fn uv_tcp_close_reset(
5278 handle: *mut uv_tcp_t,
5279 close_cb: uv_close_cb,
5280 ) -> ::std::os::raw::c_int;
5281}
5282extern "C" {
5283 pub fn uv_tcp_connect(
5284 req: *mut uv_connect_t,
5285 handle: *mut uv_tcp_t,
5286 addr: *const sockaddr,
5287 cb: uv_connect_cb,
5288 ) -> ::std::os::raw::c_int;
5289}
5290#[repr(C)]
5291#[derive(Debug, Copy, Clone)]
5292pub struct uv_connect_s {
5293 pub data: *mut ::std::os::raw::c_void,
5294 pub type_: uv_req_type,
5295 pub reserved: [*mut ::std::os::raw::c_void; 6usize],
5296 pub cb: uv_connect_cb,
5297 pub handle: *mut uv_stream_t,
5298 pub queue: [*mut ::std::os::raw::c_void; 2usize],
5299}
5300#[test]
5301fn bindgen_test_layout_uv_connect_s() {
5302 assert_eq!(
5303 ::std::mem::size_of::<uv_connect_s>(),
5304 96usize,
5305 concat!("Size of: ", stringify!(uv_connect_s))
5306 );
5307 assert_eq!(
5308 ::std::mem::align_of::<uv_connect_s>(),
5309 8usize,
5310 concat!("Alignment of ", stringify!(uv_connect_s))
5311 );
5312 assert_eq!(
5313 unsafe { &(*(::std::ptr::null::<uv_connect_s>())).data as *const _ as usize },
5314 0usize,
5315 concat!(
5316 "Offset of field: ",
5317 stringify!(uv_connect_s),
5318 "::",
5319 stringify!(data)
5320 )
5321 );
5322 assert_eq!(
5323 unsafe { &(*(::std::ptr::null::<uv_connect_s>())).type_ as *const _ as usize },
5324 8usize,
5325 concat!(
5326 "Offset of field: ",
5327 stringify!(uv_connect_s),
5328 "::",
5329 stringify!(type_)
5330 )
5331 );
5332 assert_eq!(
5333 unsafe { &(*(::std::ptr::null::<uv_connect_s>())).reserved as *const _ as usize },
5334 16usize,
5335 concat!(
5336 "Offset of field: ",
5337 stringify!(uv_connect_s),
5338 "::",
5339 stringify!(reserved)
5340 )
5341 );
5342 assert_eq!(
5343 unsafe { &(*(::std::ptr::null::<uv_connect_s>())).cb as *const _ as usize },
5344 64usize,
5345 concat!(
5346 "Offset of field: ",
5347 stringify!(uv_connect_s),
5348 "::",
5349 stringify!(cb)
5350 )
5351 );
5352 assert_eq!(
5353 unsafe { &(*(::std::ptr::null::<uv_connect_s>())).handle as *const _ as usize },
5354 72usize,
5355 concat!(
5356 "Offset of field: ",
5357 stringify!(uv_connect_s),
5358 "::",
5359 stringify!(handle)
5360 )
5361 );
5362 assert_eq!(
5363 unsafe { &(*(::std::ptr::null::<uv_connect_s>())).queue as *const _ as usize },
5364 80usize,
5365 concat!(
5366 "Offset of field: ",
5367 stringify!(uv_connect_s),
5368 "::",
5369 stringify!(queue)
5370 )
5371 );
5372}
5373impl Default for uv_connect_s {
5374 fn default() -> Self {
5375 unsafe { ::std::mem::zeroed() }
5376 }
5377}
5378#[repr(u32)]
5379#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
5380pub enum uv_udp_flags {
5381 UV_UDP_IPV6ONLY = 1,
5382 UV_UDP_PARTIAL = 2,
5383 UV_UDP_REUSEADDR = 4,
5384 UV_UDP_MMSG_CHUNK = 8,
5385 UV_UDP_MMSG_FREE = 16,
5386 UV_UDP_RECVMMSG = 256,
5387}
5388pub type uv_udp_send_cb = ::std::option::Option<
5389 unsafe extern "C" fn(req: *mut uv_udp_send_t, status: ::std::os::raw::c_int),
5390>;
5391pub type uv_udp_recv_cb = ::std::option::Option<
5392 unsafe extern "C" fn(
5393 handle: *mut uv_udp_t,
5394 nread: ssize_t,
5395 buf: *const uv_buf_t,
5396 addr: *const sockaddr,
5397 flags: ::std::os::raw::c_uint,
5398 ),
5399>;
5400#[repr(C)]
5401#[derive(Copy, Clone)]
5402pub struct uv_udp_s {
5403 pub data: *mut ::std::os::raw::c_void,
5404 pub loop_: *mut uv_loop_t,
5405 pub type_: uv_handle_type,
5406 pub close_cb: uv_close_cb,
5407 pub handle_queue: [*mut ::std::os::raw::c_void; 2usize],
5408 pub u: uv_udp_s__bindgen_ty_1,
5409 pub next_closing: *mut uv_handle_t,
5410 pub flags: ::std::os::raw::c_uint,
5411 pub send_queue_size: size_t,
5412 pub send_queue_count: size_t,
5413 pub alloc_cb: uv_alloc_cb,
5414 pub recv_cb: uv_udp_recv_cb,
5415 pub io_watcher: uv__io_t,
5416 pub write_queue: [*mut ::std::os::raw::c_void; 2usize],
5417 pub write_completed_queue: [*mut ::std::os::raw::c_void; 2usize],
5418}
5419#[repr(C)]
5420#[derive(Copy, Clone)]
5421pub union uv_udp_s__bindgen_ty_1 {
5422 pub fd: ::std::os::raw::c_int,
5423 pub reserved: [*mut ::std::os::raw::c_void; 4usize],
5424 _bindgen_union_align: [u64; 4usize],
5425}
5426#[test]
5427fn bindgen_test_layout_uv_udp_s__bindgen_ty_1() {
5428 assert_eq!(
5429 ::std::mem::size_of::<uv_udp_s__bindgen_ty_1>(),
5430 32usize,
5431 concat!("Size of: ", stringify!(uv_udp_s__bindgen_ty_1))
5432 );
5433 assert_eq!(
5434 ::std::mem::align_of::<uv_udp_s__bindgen_ty_1>(),
5435 8usize,
5436 concat!("Alignment of ", stringify!(uv_udp_s__bindgen_ty_1))
5437 );
5438 assert_eq!(
5439 unsafe { &(*(::std::ptr::null::<uv_udp_s__bindgen_ty_1>())).fd as *const _ as usize },
5440 0usize,
5441 concat!(
5442 "Offset of field: ",
5443 stringify!(uv_udp_s__bindgen_ty_1),
5444 "::",
5445 stringify!(fd)
5446 )
5447 );
5448 assert_eq!(
5449 unsafe { &(*(::std::ptr::null::<uv_udp_s__bindgen_ty_1>())).reserved as *const _ as usize },
5450 0usize,
5451 concat!(
5452 "Offset of field: ",
5453 stringify!(uv_udp_s__bindgen_ty_1),
5454 "::",
5455 stringify!(reserved)
5456 )
5457 );
5458}
5459impl Default for uv_udp_s__bindgen_ty_1 {
5460 fn default() -> Self {
5461 unsafe { ::std::mem::zeroed() }
5462 }
5463}
5464#[test]
5465fn bindgen_test_layout_uv_udp_s() {
5466 assert_eq!(
5467 ::std::mem::size_of::<uv_udp_s>(),
5468 224usize,
5469 concat!("Size of: ", stringify!(uv_udp_s))
5470 );
5471 assert_eq!(
5472 ::std::mem::align_of::<uv_udp_s>(),
5473 8usize,
5474 concat!("Alignment of ", stringify!(uv_udp_s))
5475 );
5476 assert_eq!(
5477 unsafe { &(*(::std::ptr::null::<uv_udp_s>())).data as *const _ as usize },
5478 0usize,
5479 concat!(
5480 "Offset of field: ",
5481 stringify!(uv_udp_s),
5482 "::",
5483 stringify!(data)
5484 )
5485 );
5486 assert_eq!(
5487 unsafe { &(*(::std::ptr::null::<uv_udp_s>())).loop_ as *const _ as usize },
5488 8usize,
5489 concat!(
5490 "Offset of field: ",
5491 stringify!(uv_udp_s),
5492 "::",
5493 stringify!(loop_)
5494 )
5495 );
5496 assert_eq!(
5497 unsafe { &(*(::std::ptr::null::<uv_udp_s>())).type_ as *const _ as usize },
5498 16usize,
5499 concat!(
5500 "Offset of field: ",
5501 stringify!(uv_udp_s),
5502 "::",
5503 stringify!(type_)
5504 )
5505 );
5506 assert_eq!(
5507 unsafe { &(*(::std::ptr::null::<uv_udp_s>())).close_cb as *const _ as usize },
5508 24usize,
5509 concat!(
5510 "Offset of field: ",
5511 stringify!(uv_udp_s),
5512 "::",
5513 stringify!(close_cb)
5514 )
5515 );
5516 assert_eq!(
5517 unsafe { &(*(::std::ptr::null::<uv_udp_s>())).handle_queue as *const _ as usize },
5518 32usize,
5519 concat!(
5520 "Offset of field: ",
5521 stringify!(uv_udp_s),
5522 "::",
5523 stringify!(handle_queue)
5524 )
5525 );
5526 assert_eq!(
5527 unsafe { &(*(::std::ptr::null::<uv_udp_s>())).u as *const _ as usize },
5528 48usize,
5529 concat!(
5530 "Offset of field: ",
5531 stringify!(uv_udp_s),
5532 "::",
5533 stringify!(u)
5534 )
5535 );
5536 assert_eq!(
5537 unsafe { &(*(::std::ptr::null::<uv_udp_s>())).next_closing as *const _ as usize },
5538 80usize,
5539 concat!(
5540 "Offset of field: ",
5541 stringify!(uv_udp_s),
5542 "::",
5543 stringify!(next_closing)
5544 )
5545 );
5546 assert_eq!(
5547 unsafe { &(*(::std::ptr::null::<uv_udp_s>())).flags as *const _ as usize },
5548 88usize,
5549 concat!(
5550 "Offset of field: ",
5551 stringify!(uv_udp_s),
5552 "::",
5553 stringify!(flags)
5554 )
5555 );
5556 assert_eq!(
5557 unsafe { &(*(::std::ptr::null::<uv_udp_s>())).send_queue_size as *const _ as usize },
5558 96usize,
5559 concat!(
5560 "Offset of field: ",
5561 stringify!(uv_udp_s),
5562 "::",
5563 stringify!(send_queue_size)
5564 )
5565 );
5566 assert_eq!(
5567 unsafe { &(*(::std::ptr::null::<uv_udp_s>())).send_queue_count as *const _ as usize },
5568 104usize,
5569 concat!(
5570 "Offset of field: ",
5571 stringify!(uv_udp_s),
5572 "::",
5573 stringify!(send_queue_count)
5574 )
5575 );
5576 assert_eq!(
5577 unsafe { &(*(::std::ptr::null::<uv_udp_s>())).alloc_cb as *const _ as usize },
5578 112usize,
5579 concat!(
5580 "Offset of field: ",
5581 stringify!(uv_udp_s),
5582 "::",
5583 stringify!(alloc_cb)
5584 )
5585 );
5586 assert_eq!(
5587 unsafe { &(*(::std::ptr::null::<uv_udp_s>())).recv_cb as *const _ as usize },
5588 120usize,
5589 concat!(
5590 "Offset of field: ",
5591 stringify!(uv_udp_s),
5592 "::",
5593 stringify!(recv_cb)
5594 )
5595 );
5596 assert_eq!(
5597 unsafe { &(*(::std::ptr::null::<uv_udp_s>())).io_watcher as *const _ as usize },
5598 128usize,
5599 concat!(
5600 "Offset of field: ",
5601 stringify!(uv_udp_s),
5602 "::",
5603 stringify!(io_watcher)
5604 )
5605 );
5606 assert_eq!(
5607 unsafe { &(*(::std::ptr::null::<uv_udp_s>())).write_queue as *const _ as usize },
5608 192usize,
5609 concat!(
5610 "Offset of field: ",
5611 stringify!(uv_udp_s),
5612 "::",
5613 stringify!(write_queue)
5614 )
5615 );
5616 assert_eq!(
5617 unsafe { &(*(::std::ptr::null::<uv_udp_s>())).write_completed_queue as *const _ as usize },
5618 208usize,
5619 concat!(
5620 "Offset of field: ",
5621 stringify!(uv_udp_s),
5622 "::",
5623 stringify!(write_completed_queue)
5624 )
5625 );
5626}
5627impl Default for uv_udp_s {
5628 fn default() -> Self {
5629 unsafe { ::std::mem::zeroed() }
5630 }
5631}
5632#[repr(C)]
5633#[derive(Copy, Clone)]
5634pub struct uv_udp_send_s {
5635 pub data: *mut ::std::os::raw::c_void,
5636 pub type_: uv_req_type,
5637 pub reserved: [*mut ::std::os::raw::c_void; 6usize],
5638 pub handle: *mut uv_udp_t,
5639 pub cb: uv_udp_send_cb,
5640 pub queue: [*mut ::std::os::raw::c_void; 2usize],
5641 pub addr: sockaddr_storage,
5642 pub nbufs: ::std::os::raw::c_uint,
5643 pub bufs: *mut uv_buf_t,
5644 pub status: ssize_t,
5645 pub send_cb: uv_udp_send_cb,
5646 pub bufsml: [uv_buf_t; 4usize],
5647}
5648#[test]
5649fn bindgen_test_layout_uv_udp_send_s() {
5650 assert_eq!(
5651 ::std::mem::size_of::<uv_udp_send_s>(),
5652 320usize,
5653 concat!("Size of: ", stringify!(uv_udp_send_s))
5654 );
5655 assert_eq!(
5656 ::std::mem::align_of::<uv_udp_send_s>(),
5657 8usize,
5658 concat!("Alignment of ", stringify!(uv_udp_send_s))
5659 );
5660 assert_eq!(
5661 unsafe { &(*(::std::ptr::null::<uv_udp_send_s>())).data as *const _ as usize },
5662 0usize,
5663 concat!(
5664 "Offset of field: ",
5665 stringify!(uv_udp_send_s),
5666 "::",
5667 stringify!(data)
5668 )
5669 );
5670 assert_eq!(
5671 unsafe { &(*(::std::ptr::null::<uv_udp_send_s>())).type_ as *const _ as usize },
5672 8usize,
5673 concat!(
5674 "Offset of field: ",
5675 stringify!(uv_udp_send_s),
5676 "::",
5677 stringify!(type_)
5678 )
5679 );
5680 assert_eq!(
5681 unsafe { &(*(::std::ptr::null::<uv_udp_send_s>())).reserved as *const _ as usize },
5682 16usize,
5683 concat!(
5684 "Offset of field: ",
5685 stringify!(uv_udp_send_s),
5686 "::",
5687 stringify!(reserved)
5688 )
5689 );
5690 assert_eq!(
5691 unsafe { &(*(::std::ptr::null::<uv_udp_send_s>())).handle as *const _ as usize },
5692 64usize,
5693 concat!(
5694 "Offset of field: ",
5695 stringify!(uv_udp_send_s),
5696 "::",
5697 stringify!(handle)
5698 )
5699 );
5700 assert_eq!(
5701 unsafe { &(*(::std::ptr::null::<uv_udp_send_s>())).cb as *const _ as usize },
5702 72usize,
5703 concat!(
5704 "Offset of field: ",
5705 stringify!(uv_udp_send_s),
5706 "::",
5707 stringify!(cb)
5708 )
5709 );
5710 assert_eq!(
5711 unsafe { &(*(::std::ptr::null::<uv_udp_send_s>())).queue as *const _ as usize },
5712 80usize,
5713 concat!(
5714 "Offset of field: ",
5715 stringify!(uv_udp_send_s),
5716 "::",
5717 stringify!(queue)
5718 )
5719 );
5720 assert_eq!(
5721 unsafe { &(*(::std::ptr::null::<uv_udp_send_s>())).addr as *const _ as usize },
5722 96usize,
5723 concat!(
5724 "Offset of field: ",
5725 stringify!(uv_udp_send_s),
5726 "::",
5727 stringify!(addr)
5728 )
5729 );
5730 assert_eq!(
5731 unsafe { &(*(::std::ptr::null::<uv_udp_send_s>())).nbufs as *const _ as usize },
5732 224usize,
5733 concat!(
5734 "Offset of field: ",
5735 stringify!(uv_udp_send_s),
5736 "::",
5737 stringify!(nbufs)
5738 )
5739 );
5740 assert_eq!(
5741 unsafe { &(*(::std::ptr::null::<uv_udp_send_s>())).bufs as *const _ as usize },
5742 232usize,
5743 concat!(
5744 "Offset of field: ",
5745 stringify!(uv_udp_send_s),
5746 "::",
5747 stringify!(bufs)
5748 )
5749 );
5750 assert_eq!(
5751 unsafe { &(*(::std::ptr::null::<uv_udp_send_s>())).status as *const _ as usize },
5752 240usize,
5753 concat!(
5754 "Offset of field: ",
5755 stringify!(uv_udp_send_s),
5756 "::",
5757 stringify!(status)
5758 )
5759 );
5760 assert_eq!(
5761 unsafe { &(*(::std::ptr::null::<uv_udp_send_s>())).send_cb as *const _ as usize },
5762 248usize,
5763 concat!(
5764 "Offset of field: ",
5765 stringify!(uv_udp_send_s),
5766 "::",
5767 stringify!(send_cb)
5768 )
5769 );
5770 assert_eq!(
5771 unsafe { &(*(::std::ptr::null::<uv_udp_send_s>())).bufsml as *const _ as usize },
5772 256usize,
5773 concat!(
5774 "Offset of field: ",
5775 stringify!(uv_udp_send_s),
5776 "::",
5777 stringify!(bufsml)
5778 )
5779 );
5780}
5781impl Default for uv_udp_send_s {
5782 fn default() -> Self {
5783 unsafe { ::std::mem::zeroed() }
5784 }
5785}
5786extern "C" {
5787 pub fn uv_udp_init(arg1: *mut uv_loop_t, handle: *mut uv_udp_t) -> ::std::os::raw::c_int;
5788}
5789extern "C" {
5790 pub fn uv_udp_init_ex(
5791 arg1: *mut uv_loop_t,
5792 handle: *mut uv_udp_t,
5793 flags: ::std::os::raw::c_uint,
5794 ) -> ::std::os::raw::c_int;
5795}
5796extern "C" {
5797 pub fn uv_udp_open(handle: *mut uv_udp_t, sock: uv_os_sock_t) -> ::std::os::raw::c_int;
5798}
5799extern "C" {
5800 pub fn uv_udp_bind(
5801 handle: *mut uv_udp_t,
5802 addr: *const sockaddr,
5803 flags: ::std::os::raw::c_uint,
5804 ) -> ::std::os::raw::c_int;
5805}
5806extern "C" {
5807 pub fn uv_udp_connect(handle: *mut uv_udp_t, addr: *const sockaddr) -> ::std::os::raw::c_int;
5808}
5809extern "C" {
5810 pub fn uv_udp_getpeername(
5811 handle: *const uv_udp_t,
5812 name: *mut sockaddr,
5813 namelen: *mut ::std::os::raw::c_int,
5814 ) -> ::std::os::raw::c_int;
5815}
5816extern "C" {
5817 pub fn uv_udp_getsockname(
5818 handle: *const uv_udp_t,
5819 name: *mut sockaddr,
5820 namelen: *mut ::std::os::raw::c_int,
5821 ) -> ::std::os::raw::c_int;
5822}
5823extern "C" {
5824 pub fn uv_udp_set_membership(
5825 handle: *mut uv_udp_t,
5826 multicast_addr: *const ::std::os::raw::c_char,
5827 interface_addr: *const ::std::os::raw::c_char,
5828 membership: uv_membership,
5829 ) -> ::std::os::raw::c_int;
5830}
5831extern "C" {
5832 pub fn uv_udp_set_source_membership(
5833 handle: *mut uv_udp_t,
5834 multicast_addr: *const ::std::os::raw::c_char,
5835 interface_addr: *const ::std::os::raw::c_char,
5836 source_addr: *const ::std::os::raw::c_char,
5837 membership: uv_membership,
5838 ) -> ::std::os::raw::c_int;
5839}
5840extern "C" {
5841 pub fn uv_udp_set_multicast_loop(
5842 handle: *mut uv_udp_t,
5843 on: ::std::os::raw::c_int,
5844 ) -> ::std::os::raw::c_int;
5845}
5846extern "C" {
5847 pub fn uv_udp_set_multicast_ttl(
5848 handle: *mut uv_udp_t,
5849 ttl: ::std::os::raw::c_int,
5850 ) -> ::std::os::raw::c_int;
5851}
5852extern "C" {
5853 pub fn uv_udp_set_multicast_interface(
5854 handle: *mut uv_udp_t,
5855 interface_addr: *const ::std::os::raw::c_char,
5856 ) -> ::std::os::raw::c_int;
5857}
5858extern "C" {
5859 pub fn uv_udp_set_broadcast(
5860 handle: *mut uv_udp_t,
5861 on: ::std::os::raw::c_int,
5862 ) -> ::std::os::raw::c_int;
5863}
5864extern "C" {
5865 pub fn uv_udp_set_ttl(
5866 handle: *mut uv_udp_t,
5867 ttl: ::std::os::raw::c_int,
5868 ) -> ::std::os::raw::c_int;
5869}
5870extern "C" {
5871 pub fn uv_udp_send(
5872 req: *mut uv_udp_send_t,
5873 handle: *mut uv_udp_t,
5874 bufs: *const uv_buf_t,
5875 nbufs: ::std::os::raw::c_uint,
5876 addr: *const sockaddr,
5877 send_cb: uv_udp_send_cb,
5878 ) -> ::std::os::raw::c_int;
5879}
5880extern "C" {
5881 pub fn uv_udp_try_send(
5882 handle: *mut uv_udp_t,
5883 bufs: *const uv_buf_t,
5884 nbufs: ::std::os::raw::c_uint,
5885 addr: *const sockaddr,
5886 ) -> ::std::os::raw::c_int;
5887}
5888extern "C" {
5889 pub fn uv_udp_recv_start(
5890 handle: *mut uv_udp_t,
5891 alloc_cb: uv_alloc_cb,
5892 recv_cb: uv_udp_recv_cb,
5893 ) -> ::std::os::raw::c_int;
5894}
5895extern "C" {
5896 pub fn uv_udp_using_recvmmsg(handle: *const uv_udp_t) -> ::std::os::raw::c_int;
5897}
5898extern "C" {
5899 pub fn uv_udp_recv_stop(handle: *mut uv_udp_t) -> ::std::os::raw::c_int;
5900}
5901extern "C" {
5902 pub fn uv_udp_get_send_queue_size(handle: *const uv_udp_t) -> size_t;
5903}
5904extern "C" {
5905 pub fn uv_udp_get_send_queue_count(handle: *const uv_udp_t) -> size_t;
5906}
5907#[repr(C)]
5908#[derive(Copy, Clone)]
5909pub struct uv_tty_s {
5910 pub data: *mut ::std::os::raw::c_void,
5911 pub loop_: *mut uv_loop_t,
5912 pub type_: uv_handle_type,
5913 pub close_cb: uv_close_cb,
5914 pub handle_queue: [*mut ::std::os::raw::c_void; 2usize],
5915 pub u: uv_tty_s__bindgen_ty_1,
5916 pub next_closing: *mut uv_handle_t,
5917 pub flags: ::std::os::raw::c_uint,
5918 pub write_queue_size: size_t,
5919 pub alloc_cb: uv_alloc_cb,
5920 pub read_cb: uv_read_cb,
5921 pub connect_req: *mut uv_connect_t,
5922 pub shutdown_req: *mut uv_shutdown_t,
5923 pub io_watcher: uv__io_t,
5924 pub write_queue: [*mut ::std::os::raw::c_void; 2usize],
5925 pub write_completed_queue: [*mut ::std::os::raw::c_void; 2usize],
5926 pub connection_cb: uv_connection_cb,
5927 pub delayed_error: ::std::os::raw::c_int,
5928 pub accepted_fd: ::std::os::raw::c_int,
5929 pub queued_fds: *mut ::std::os::raw::c_void,
5930 pub select: *mut ::std::os::raw::c_void,
5931 pub orig_termios: termios,
5932 pub mode: ::std::os::raw::c_int,
5933}
5934#[repr(C)]
5935#[derive(Copy, Clone)]
5936pub union uv_tty_s__bindgen_ty_1 {
5937 pub fd: ::std::os::raw::c_int,
5938 pub reserved: [*mut ::std::os::raw::c_void; 4usize],
5939 _bindgen_union_align: [u64; 4usize],
5940}
5941#[test]
5942fn bindgen_test_layout_uv_tty_s__bindgen_ty_1() {
5943 assert_eq!(
5944 ::std::mem::size_of::<uv_tty_s__bindgen_ty_1>(),
5945 32usize,
5946 concat!("Size of: ", stringify!(uv_tty_s__bindgen_ty_1))
5947 );
5948 assert_eq!(
5949 ::std::mem::align_of::<uv_tty_s__bindgen_ty_1>(),
5950 8usize,
5951 concat!("Alignment of ", stringify!(uv_tty_s__bindgen_ty_1))
5952 );
5953 assert_eq!(
5954 unsafe { &(*(::std::ptr::null::<uv_tty_s__bindgen_ty_1>())).fd as *const _ as usize },
5955 0usize,
5956 concat!(
5957 "Offset of field: ",
5958 stringify!(uv_tty_s__bindgen_ty_1),
5959 "::",
5960 stringify!(fd)
5961 )
5962 );
5963 assert_eq!(
5964 unsafe { &(*(::std::ptr::null::<uv_tty_s__bindgen_ty_1>())).reserved as *const _ as usize },
5965 0usize,
5966 concat!(
5967 "Offset of field: ",
5968 stringify!(uv_tty_s__bindgen_ty_1),
5969 "::",
5970 stringify!(reserved)
5971 )
5972 );
5973}
5974impl Default for uv_tty_s__bindgen_ty_1 {
5975 fn default() -> Self {
5976 unsafe { ::std::mem::zeroed() }
5977 }
5978}
5979#[test]
5980fn bindgen_test_layout_uv_tty_s() {
5981 assert_eq!(
5982 ::std::mem::size_of::<uv_tty_s>(),
5983 344usize,
5984 concat!("Size of: ", stringify!(uv_tty_s))
5985 );
5986 assert_eq!(
5987 ::std::mem::align_of::<uv_tty_s>(),
5988 8usize,
5989 concat!("Alignment of ", stringify!(uv_tty_s))
5990 );
5991 assert_eq!(
5992 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).data as *const _ as usize },
5993 0usize,
5994 concat!(
5995 "Offset of field: ",
5996 stringify!(uv_tty_s),
5997 "::",
5998 stringify!(data)
5999 )
6000 );
6001 assert_eq!(
6002 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).loop_ as *const _ as usize },
6003 8usize,
6004 concat!(
6005 "Offset of field: ",
6006 stringify!(uv_tty_s),
6007 "::",
6008 stringify!(loop_)
6009 )
6010 );
6011 assert_eq!(
6012 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).type_ as *const _ as usize },
6013 16usize,
6014 concat!(
6015 "Offset of field: ",
6016 stringify!(uv_tty_s),
6017 "::",
6018 stringify!(type_)
6019 )
6020 );
6021 assert_eq!(
6022 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).close_cb as *const _ as usize },
6023 24usize,
6024 concat!(
6025 "Offset of field: ",
6026 stringify!(uv_tty_s),
6027 "::",
6028 stringify!(close_cb)
6029 )
6030 );
6031 assert_eq!(
6032 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).handle_queue as *const _ as usize },
6033 32usize,
6034 concat!(
6035 "Offset of field: ",
6036 stringify!(uv_tty_s),
6037 "::",
6038 stringify!(handle_queue)
6039 )
6040 );
6041 assert_eq!(
6042 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).u as *const _ as usize },
6043 48usize,
6044 concat!(
6045 "Offset of field: ",
6046 stringify!(uv_tty_s),
6047 "::",
6048 stringify!(u)
6049 )
6050 );
6051 assert_eq!(
6052 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).next_closing as *const _ as usize },
6053 80usize,
6054 concat!(
6055 "Offset of field: ",
6056 stringify!(uv_tty_s),
6057 "::",
6058 stringify!(next_closing)
6059 )
6060 );
6061 assert_eq!(
6062 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).flags as *const _ as usize },
6063 88usize,
6064 concat!(
6065 "Offset of field: ",
6066 stringify!(uv_tty_s),
6067 "::",
6068 stringify!(flags)
6069 )
6070 );
6071 assert_eq!(
6072 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).write_queue_size as *const _ as usize },
6073 96usize,
6074 concat!(
6075 "Offset of field: ",
6076 stringify!(uv_tty_s),
6077 "::",
6078 stringify!(write_queue_size)
6079 )
6080 );
6081 assert_eq!(
6082 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).alloc_cb as *const _ as usize },
6083 104usize,
6084 concat!(
6085 "Offset of field: ",
6086 stringify!(uv_tty_s),
6087 "::",
6088 stringify!(alloc_cb)
6089 )
6090 );
6091 assert_eq!(
6092 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).read_cb as *const _ as usize },
6093 112usize,
6094 concat!(
6095 "Offset of field: ",
6096 stringify!(uv_tty_s),
6097 "::",
6098 stringify!(read_cb)
6099 )
6100 );
6101 assert_eq!(
6102 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).connect_req as *const _ as usize },
6103 120usize,
6104 concat!(
6105 "Offset of field: ",
6106 stringify!(uv_tty_s),
6107 "::",
6108 stringify!(connect_req)
6109 )
6110 );
6111 assert_eq!(
6112 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).shutdown_req as *const _ as usize },
6113 128usize,
6114 concat!(
6115 "Offset of field: ",
6116 stringify!(uv_tty_s),
6117 "::",
6118 stringify!(shutdown_req)
6119 )
6120 );
6121 assert_eq!(
6122 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).io_watcher as *const _ as usize },
6123 136usize,
6124 concat!(
6125 "Offset of field: ",
6126 stringify!(uv_tty_s),
6127 "::",
6128 stringify!(io_watcher)
6129 )
6130 );
6131 assert_eq!(
6132 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).write_queue as *const _ as usize },
6133 200usize,
6134 concat!(
6135 "Offset of field: ",
6136 stringify!(uv_tty_s),
6137 "::",
6138 stringify!(write_queue)
6139 )
6140 );
6141 assert_eq!(
6142 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).write_completed_queue as *const _ as usize },
6143 216usize,
6144 concat!(
6145 "Offset of field: ",
6146 stringify!(uv_tty_s),
6147 "::",
6148 stringify!(write_completed_queue)
6149 )
6150 );
6151 assert_eq!(
6152 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).connection_cb as *const _ as usize },
6153 232usize,
6154 concat!(
6155 "Offset of field: ",
6156 stringify!(uv_tty_s),
6157 "::",
6158 stringify!(connection_cb)
6159 )
6160 );
6161 assert_eq!(
6162 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).delayed_error as *const _ as usize },
6163 240usize,
6164 concat!(
6165 "Offset of field: ",
6166 stringify!(uv_tty_s),
6167 "::",
6168 stringify!(delayed_error)
6169 )
6170 );
6171 assert_eq!(
6172 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).accepted_fd as *const _ as usize },
6173 244usize,
6174 concat!(
6175 "Offset of field: ",
6176 stringify!(uv_tty_s),
6177 "::",
6178 stringify!(accepted_fd)
6179 )
6180 );
6181 assert_eq!(
6182 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).queued_fds as *const _ as usize },
6183 248usize,
6184 concat!(
6185 "Offset of field: ",
6186 stringify!(uv_tty_s),
6187 "::",
6188 stringify!(queued_fds)
6189 )
6190 );
6191 assert_eq!(
6192 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).select as *const _ as usize },
6193 256usize,
6194 concat!(
6195 "Offset of field: ",
6196 stringify!(uv_tty_s),
6197 "::",
6198 stringify!(select)
6199 )
6200 );
6201 assert_eq!(
6202 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).orig_termios as *const _ as usize },
6203 264usize,
6204 concat!(
6205 "Offset of field: ",
6206 stringify!(uv_tty_s),
6207 "::",
6208 stringify!(orig_termios)
6209 )
6210 );
6211 assert_eq!(
6212 unsafe { &(*(::std::ptr::null::<uv_tty_s>())).mode as *const _ as usize },
6213 336usize,
6214 concat!(
6215 "Offset of field: ",
6216 stringify!(uv_tty_s),
6217 "::",
6218 stringify!(mode)
6219 )
6220 );
6221}
6222impl Default for uv_tty_s {
6223 fn default() -> Self {
6224 unsafe { ::std::mem::zeroed() }
6225 }
6226}
6227#[repr(u32)]
6228#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
6229pub enum uv_tty_mode_t {
6230 UV_TTY_MODE_NORMAL = 0,
6231 UV_TTY_MODE_RAW = 1,
6232 UV_TTY_MODE_IO = 2,
6233}
6234#[repr(u32)]
6235#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
6236pub enum uv_tty_vtermstate_t {
6237 UV_TTY_SUPPORTED = 0,
6238 UV_TTY_UNSUPPORTED = 1,
6239}
6240extern "C" {
6241 pub fn uv_tty_init(
6242 arg1: *mut uv_loop_t,
6243 arg2: *mut uv_tty_t,
6244 fd: uv_file,
6245 readable: ::std::os::raw::c_int,
6246 ) -> ::std::os::raw::c_int;
6247}
6248extern "C" {
6249 pub fn uv_tty_set_mode(arg1: *mut uv_tty_t, mode: uv_tty_mode_t) -> ::std::os::raw::c_int;
6250}
6251extern "C" {
6252 pub fn uv_tty_reset_mode() -> ::std::os::raw::c_int;
6253}
6254extern "C" {
6255 pub fn uv_tty_get_winsize(
6256 arg1: *mut uv_tty_t,
6257 width: *mut ::std::os::raw::c_int,
6258 height: *mut ::std::os::raw::c_int,
6259 ) -> ::std::os::raw::c_int;
6260}
6261extern "C" {
6262 pub fn uv_tty_set_vterm_state(state: uv_tty_vtermstate_t);
6263}
6264extern "C" {
6265 pub fn uv_tty_get_vterm_state(state: *mut uv_tty_vtermstate_t) -> ::std::os::raw::c_int;
6266}
6267extern "C" {
6268 pub fn uv_guess_handle(file: uv_file) -> uv_handle_type;
6269}
6270#[repr(C)]
6271#[derive(Copy, Clone)]
6272pub struct uv_pipe_s {
6273 pub data: *mut ::std::os::raw::c_void,
6274 pub loop_: *mut uv_loop_t,
6275 pub type_: uv_handle_type,
6276 pub close_cb: uv_close_cb,
6277 pub handle_queue: [*mut ::std::os::raw::c_void; 2usize],
6278 pub u: uv_pipe_s__bindgen_ty_1,
6279 pub next_closing: *mut uv_handle_t,
6280 pub flags: ::std::os::raw::c_uint,
6281 pub write_queue_size: size_t,
6282 pub alloc_cb: uv_alloc_cb,
6283 pub read_cb: uv_read_cb,
6284 pub connect_req: *mut uv_connect_t,
6285 pub shutdown_req: *mut uv_shutdown_t,
6286 pub io_watcher: uv__io_t,
6287 pub write_queue: [*mut ::std::os::raw::c_void; 2usize],
6288 pub write_completed_queue: [*mut ::std::os::raw::c_void; 2usize],
6289 pub connection_cb: uv_connection_cb,
6290 pub delayed_error: ::std::os::raw::c_int,
6291 pub accepted_fd: ::std::os::raw::c_int,
6292 pub queued_fds: *mut ::std::os::raw::c_void,
6293 pub select: *mut ::std::os::raw::c_void,
6294 pub ipc: ::std::os::raw::c_int,
6295 pub pipe_fname: *const ::std::os::raw::c_char,
6296}
6297#[repr(C)]
6298#[derive(Copy, Clone)]
6299pub union uv_pipe_s__bindgen_ty_1 {
6300 pub fd: ::std::os::raw::c_int,
6301 pub reserved: [*mut ::std::os::raw::c_void; 4usize],
6302 _bindgen_union_align: [u64; 4usize],
6303}
6304#[test]
6305fn bindgen_test_layout_uv_pipe_s__bindgen_ty_1() {
6306 assert_eq!(
6307 ::std::mem::size_of::<uv_pipe_s__bindgen_ty_1>(),
6308 32usize,
6309 concat!("Size of: ", stringify!(uv_pipe_s__bindgen_ty_1))
6310 );
6311 assert_eq!(
6312 ::std::mem::align_of::<uv_pipe_s__bindgen_ty_1>(),
6313 8usize,
6314 concat!("Alignment of ", stringify!(uv_pipe_s__bindgen_ty_1))
6315 );
6316 assert_eq!(
6317 unsafe { &(*(::std::ptr::null::<uv_pipe_s__bindgen_ty_1>())).fd as *const _ as usize },
6318 0usize,
6319 concat!(
6320 "Offset of field: ",
6321 stringify!(uv_pipe_s__bindgen_ty_1),
6322 "::",
6323 stringify!(fd)
6324 )
6325 );
6326 assert_eq!(
6327 unsafe {
6328 &(*(::std::ptr::null::<uv_pipe_s__bindgen_ty_1>())).reserved as *const _ as usize
6329 },
6330 0usize,
6331 concat!(
6332 "Offset of field: ",
6333 stringify!(uv_pipe_s__bindgen_ty_1),
6334 "::",
6335 stringify!(reserved)
6336 )
6337 );
6338}
6339impl Default for uv_pipe_s__bindgen_ty_1 {
6340 fn default() -> Self {
6341 unsafe { ::std::mem::zeroed() }
6342 }
6343}
6344#[test]
6345fn bindgen_test_layout_uv_pipe_s() {
6346 assert_eq!(
6347 ::std::mem::size_of::<uv_pipe_s>(),
6348 280usize,
6349 concat!("Size of: ", stringify!(uv_pipe_s))
6350 );
6351 assert_eq!(
6352 ::std::mem::align_of::<uv_pipe_s>(),
6353 8usize,
6354 concat!("Alignment of ", stringify!(uv_pipe_s))
6355 );
6356 assert_eq!(
6357 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).data as *const _ as usize },
6358 0usize,
6359 concat!(
6360 "Offset of field: ",
6361 stringify!(uv_pipe_s),
6362 "::",
6363 stringify!(data)
6364 )
6365 );
6366 assert_eq!(
6367 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).loop_ as *const _ as usize },
6368 8usize,
6369 concat!(
6370 "Offset of field: ",
6371 stringify!(uv_pipe_s),
6372 "::",
6373 stringify!(loop_)
6374 )
6375 );
6376 assert_eq!(
6377 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).type_ as *const _ as usize },
6378 16usize,
6379 concat!(
6380 "Offset of field: ",
6381 stringify!(uv_pipe_s),
6382 "::",
6383 stringify!(type_)
6384 )
6385 );
6386 assert_eq!(
6387 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).close_cb as *const _ as usize },
6388 24usize,
6389 concat!(
6390 "Offset of field: ",
6391 stringify!(uv_pipe_s),
6392 "::",
6393 stringify!(close_cb)
6394 )
6395 );
6396 assert_eq!(
6397 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).handle_queue as *const _ as usize },
6398 32usize,
6399 concat!(
6400 "Offset of field: ",
6401 stringify!(uv_pipe_s),
6402 "::",
6403 stringify!(handle_queue)
6404 )
6405 );
6406 assert_eq!(
6407 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).u as *const _ as usize },
6408 48usize,
6409 concat!(
6410 "Offset of field: ",
6411 stringify!(uv_pipe_s),
6412 "::",
6413 stringify!(u)
6414 )
6415 );
6416 assert_eq!(
6417 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).next_closing as *const _ as usize },
6418 80usize,
6419 concat!(
6420 "Offset of field: ",
6421 stringify!(uv_pipe_s),
6422 "::",
6423 stringify!(next_closing)
6424 )
6425 );
6426 assert_eq!(
6427 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).flags as *const _ as usize },
6428 88usize,
6429 concat!(
6430 "Offset of field: ",
6431 stringify!(uv_pipe_s),
6432 "::",
6433 stringify!(flags)
6434 )
6435 );
6436 assert_eq!(
6437 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).write_queue_size as *const _ as usize },
6438 96usize,
6439 concat!(
6440 "Offset of field: ",
6441 stringify!(uv_pipe_s),
6442 "::",
6443 stringify!(write_queue_size)
6444 )
6445 );
6446 assert_eq!(
6447 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).alloc_cb as *const _ as usize },
6448 104usize,
6449 concat!(
6450 "Offset of field: ",
6451 stringify!(uv_pipe_s),
6452 "::",
6453 stringify!(alloc_cb)
6454 )
6455 );
6456 assert_eq!(
6457 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).read_cb as *const _ as usize },
6458 112usize,
6459 concat!(
6460 "Offset of field: ",
6461 stringify!(uv_pipe_s),
6462 "::",
6463 stringify!(read_cb)
6464 )
6465 );
6466 assert_eq!(
6467 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).connect_req as *const _ as usize },
6468 120usize,
6469 concat!(
6470 "Offset of field: ",
6471 stringify!(uv_pipe_s),
6472 "::",
6473 stringify!(connect_req)
6474 )
6475 );
6476 assert_eq!(
6477 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).shutdown_req as *const _ as usize },
6478 128usize,
6479 concat!(
6480 "Offset of field: ",
6481 stringify!(uv_pipe_s),
6482 "::",
6483 stringify!(shutdown_req)
6484 )
6485 );
6486 assert_eq!(
6487 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).io_watcher as *const _ as usize },
6488 136usize,
6489 concat!(
6490 "Offset of field: ",
6491 stringify!(uv_pipe_s),
6492 "::",
6493 stringify!(io_watcher)
6494 )
6495 );
6496 assert_eq!(
6497 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).write_queue as *const _ as usize },
6498 200usize,
6499 concat!(
6500 "Offset of field: ",
6501 stringify!(uv_pipe_s),
6502 "::",
6503 stringify!(write_queue)
6504 )
6505 );
6506 assert_eq!(
6507 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).write_completed_queue as *const _ as usize },
6508 216usize,
6509 concat!(
6510 "Offset of field: ",
6511 stringify!(uv_pipe_s),
6512 "::",
6513 stringify!(write_completed_queue)
6514 )
6515 );
6516 assert_eq!(
6517 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).connection_cb as *const _ as usize },
6518 232usize,
6519 concat!(
6520 "Offset of field: ",
6521 stringify!(uv_pipe_s),
6522 "::",
6523 stringify!(connection_cb)
6524 )
6525 );
6526 assert_eq!(
6527 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).delayed_error as *const _ as usize },
6528 240usize,
6529 concat!(
6530 "Offset of field: ",
6531 stringify!(uv_pipe_s),
6532 "::",
6533 stringify!(delayed_error)
6534 )
6535 );
6536 assert_eq!(
6537 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).accepted_fd as *const _ as usize },
6538 244usize,
6539 concat!(
6540 "Offset of field: ",
6541 stringify!(uv_pipe_s),
6542 "::",
6543 stringify!(accepted_fd)
6544 )
6545 );
6546 assert_eq!(
6547 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).queued_fds as *const _ as usize },
6548 248usize,
6549 concat!(
6550 "Offset of field: ",
6551 stringify!(uv_pipe_s),
6552 "::",
6553 stringify!(queued_fds)
6554 )
6555 );
6556 assert_eq!(
6557 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).select as *const _ as usize },
6558 256usize,
6559 concat!(
6560 "Offset of field: ",
6561 stringify!(uv_pipe_s),
6562 "::",
6563 stringify!(select)
6564 )
6565 );
6566 assert_eq!(
6567 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).ipc as *const _ as usize },
6568 264usize,
6569 concat!(
6570 "Offset of field: ",
6571 stringify!(uv_pipe_s),
6572 "::",
6573 stringify!(ipc)
6574 )
6575 );
6576 assert_eq!(
6577 unsafe { &(*(::std::ptr::null::<uv_pipe_s>())).pipe_fname as *const _ as usize },
6578 272usize,
6579 concat!(
6580 "Offset of field: ",
6581 stringify!(uv_pipe_s),
6582 "::",
6583 stringify!(pipe_fname)
6584 )
6585 );
6586}
6587impl Default for uv_pipe_s {
6588 fn default() -> Self {
6589 unsafe { ::std::mem::zeroed() }
6590 }
6591}
6592extern "C" {
6593 pub fn uv_pipe_init(
6594 arg1: *mut uv_loop_t,
6595 handle: *mut uv_pipe_t,
6596 ipc: ::std::os::raw::c_int,
6597 ) -> ::std::os::raw::c_int;
6598}
6599extern "C" {
6600 pub fn uv_pipe_open(arg1: *mut uv_pipe_t, file: uv_file) -> ::std::os::raw::c_int;
6601}
6602extern "C" {
6603 pub fn uv_pipe_bind(
6604 handle: *mut uv_pipe_t,
6605 name: *const ::std::os::raw::c_char,
6606 ) -> ::std::os::raw::c_int;
6607}
6608extern "C" {
6609 pub fn uv_pipe_connect(
6610 req: *mut uv_connect_t,
6611 handle: *mut uv_pipe_t,
6612 name: *const ::std::os::raw::c_char,
6613 cb: uv_connect_cb,
6614 );
6615}
6616extern "C" {
6617 pub fn uv_pipe_getsockname(
6618 handle: *const uv_pipe_t,
6619 buffer: *mut ::std::os::raw::c_char,
6620 size: *mut size_t,
6621 ) -> ::std::os::raw::c_int;
6622}
6623extern "C" {
6624 pub fn uv_pipe_getpeername(
6625 handle: *const uv_pipe_t,
6626 buffer: *mut ::std::os::raw::c_char,
6627 size: *mut size_t,
6628 ) -> ::std::os::raw::c_int;
6629}
6630extern "C" {
6631 pub fn uv_pipe_pending_instances(handle: *mut uv_pipe_t, count: ::std::os::raw::c_int);
6632}
6633extern "C" {
6634 pub fn uv_pipe_pending_count(handle: *mut uv_pipe_t) -> ::std::os::raw::c_int;
6635}
6636extern "C" {
6637 pub fn uv_pipe_pending_type(handle: *mut uv_pipe_t) -> uv_handle_type;
6638}
6639extern "C" {
6640 pub fn uv_pipe_chmod(
6641 handle: *mut uv_pipe_t,
6642 flags: ::std::os::raw::c_int,
6643 ) -> ::std::os::raw::c_int;
6644}
6645#[repr(C)]
6646#[derive(Copy, Clone)]
6647pub struct uv_poll_s {
6648 pub data: *mut ::std::os::raw::c_void,
6649 pub loop_: *mut uv_loop_t,
6650 pub type_: uv_handle_type,
6651 pub close_cb: uv_close_cb,
6652 pub handle_queue: [*mut ::std::os::raw::c_void; 2usize],
6653 pub u: uv_poll_s__bindgen_ty_1,
6654 pub next_closing: *mut uv_handle_t,
6655 pub flags: ::std::os::raw::c_uint,
6656 pub poll_cb: uv_poll_cb,
6657 pub io_watcher: uv__io_t,
6658}
6659#[repr(C)]
6660#[derive(Copy, Clone)]
6661pub union uv_poll_s__bindgen_ty_1 {
6662 pub fd: ::std::os::raw::c_int,
6663 pub reserved: [*mut ::std::os::raw::c_void; 4usize],
6664 _bindgen_union_align: [u64; 4usize],
6665}
6666#[test]
6667fn bindgen_test_layout_uv_poll_s__bindgen_ty_1() {
6668 assert_eq!(
6669 ::std::mem::size_of::<uv_poll_s__bindgen_ty_1>(),
6670 32usize,
6671 concat!("Size of: ", stringify!(uv_poll_s__bindgen_ty_1))
6672 );
6673 assert_eq!(
6674 ::std::mem::align_of::<uv_poll_s__bindgen_ty_1>(),
6675 8usize,
6676 concat!("Alignment of ", stringify!(uv_poll_s__bindgen_ty_1))
6677 );
6678 assert_eq!(
6679 unsafe { &(*(::std::ptr::null::<uv_poll_s__bindgen_ty_1>())).fd as *const _ as usize },
6680 0usize,
6681 concat!(
6682 "Offset of field: ",
6683 stringify!(uv_poll_s__bindgen_ty_1),
6684 "::",
6685 stringify!(fd)
6686 )
6687 );
6688 assert_eq!(
6689 unsafe {
6690 &(*(::std::ptr::null::<uv_poll_s__bindgen_ty_1>())).reserved as *const _ as usize
6691 },
6692 0usize,
6693 concat!(
6694 "Offset of field: ",
6695 stringify!(uv_poll_s__bindgen_ty_1),
6696 "::",
6697 stringify!(reserved)
6698 )
6699 );
6700}
6701impl Default for uv_poll_s__bindgen_ty_1 {
6702 fn default() -> Self {
6703 unsafe { ::std::mem::zeroed() }
6704 }
6705}
6706#[test]
6707fn bindgen_test_layout_uv_poll_s() {
6708 assert_eq!(
6709 ::std::mem::size_of::<uv_poll_s>(),
6710 168usize,
6711 concat!("Size of: ", stringify!(uv_poll_s))
6712 );
6713 assert_eq!(
6714 ::std::mem::align_of::<uv_poll_s>(),
6715 8usize,
6716 concat!("Alignment of ", stringify!(uv_poll_s))
6717 );
6718 assert_eq!(
6719 unsafe { &(*(::std::ptr::null::<uv_poll_s>())).data as *const _ as usize },
6720 0usize,
6721 concat!(
6722 "Offset of field: ",
6723 stringify!(uv_poll_s),
6724 "::",
6725 stringify!(data)
6726 )
6727 );
6728 assert_eq!(
6729 unsafe { &(*(::std::ptr::null::<uv_poll_s>())).loop_ as *const _ as usize },
6730 8usize,
6731 concat!(
6732 "Offset of field: ",
6733 stringify!(uv_poll_s),
6734 "::",
6735 stringify!(loop_)
6736 )
6737 );
6738 assert_eq!(
6739 unsafe { &(*(::std::ptr::null::<uv_poll_s>())).type_ as *const _ as usize },
6740 16usize,
6741 concat!(
6742 "Offset of field: ",
6743 stringify!(uv_poll_s),
6744 "::",
6745 stringify!(type_)
6746 )
6747 );
6748 assert_eq!(
6749 unsafe { &(*(::std::ptr::null::<uv_poll_s>())).close_cb as *const _ as usize },
6750 24usize,
6751 concat!(
6752 "Offset of field: ",
6753 stringify!(uv_poll_s),
6754 "::",
6755 stringify!(close_cb)
6756 )
6757 );
6758 assert_eq!(
6759 unsafe { &(*(::std::ptr::null::<uv_poll_s>())).handle_queue as *const _ as usize },
6760 32usize,
6761 concat!(
6762 "Offset of field: ",
6763 stringify!(uv_poll_s),
6764 "::",
6765 stringify!(handle_queue)
6766 )
6767 );
6768 assert_eq!(
6769 unsafe { &(*(::std::ptr::null::<uv_poll_s>())).u as *const _ as usize },
6770 48usize,
6771 concat!(
6772 "Offset of field: ",
6773 stringify!(uv_poll_s),
6774 "::",
6775 stringify!(u)
6776 )
6777 );
6778 assert_eq!(
6779 unsafe { &(*(::std::ptr::null::<uv_poll_s>())).next_closing as *const _ as usize },
6780 80usize,
6781 concat!(
6782 "Offset of field: ",
6783 stringify!(uv_poll_s),
6784 "::",
6785 stringify!(next_closing)
6786 )
6787 );
6788 assert_eq!(
6789 unsafe { &(*(::std::ptr::null::<uv_poll_s>())).flags as *const _ as usize },
6790 88usize,
6791 concat!(
6792 "Offset of field: ",
6793 stringify!(uv_poll_s),
6794 "::",
6795 stringify!(flags)
6796 )
6797 );
6798 assert_eq!(
6799 unsafe { &(*(::std::ptr::null::<uv_poll_s>())).poll_cb as *const _ as usize },
6800 96usize,
6801 concat!(
6802 "Offset of field: ",
6803 stringify!(uv_poll_s),
6804 "::",
6805 stringify!(poll_cb)
6806 )
6807 );
6808 assert_eq!(
6809 unsafe { &(*(::std::ptr::null::<uv_poll_s>())).io_watcher as *const _ as usize },
6810 104usize,
6811 concat!(
6812 "Offset of field: ",
6813 stringify!(uv_poll_s),
6814 "::",
6815 stringify!(io_watcher)
6816 )
6817 );
6818}
6819impl Default for uv_poll_s {
6820 fn default() -> Self {
6821 unsafe { ::std::mem::zeroed() }
6822 }
6823}
6824#[repr(u32)]
6825#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
6826pub enum uv_poll_event {
6827 UV_READABLE = 1,
6828 UV_WRITABLE = 2,
6829 UV_DISCONNECT = 4,
6830 UV_PRIORITIZED = 8,
6831}
6832extern "C" {
6833 pub fn uv_poll_init(
6834 loop_: *mut uv_loop_t,
6835 handle: *mut uv_poll_t,
6836 fd: ::std::os::raw::c_int,
6837 ) -> ::std::os::raw::c_int;
6838}
6839extern "C" {
6840 pub fn uv_poll_init_socket(
6841 loop_: *mut uv_loop_t,
6842 handle: *mut uv_poll_t,
6843 socket: uv_os_sock_t,
6844 ) -> ::std::os::raw::c_int;
6845}
6846extern "C" {
6847 pub fn uv_poll_start(
6848 handle: *mut uv_poll_t,
6849 events: ::std::os::raw::c_int,
6850 cb: uv_poll_cb,
6851 ) -> ::std::os::raw::c_int;
6852}
6853extern "C" {
6854 pub fn uv_poll_stop(handle: *mut uv_poll_t) -> ::std::os::raw::c_int;
6855}
6856#[repr(C)]
6857#[derive(Copy, Clone)]
6858pub struct uv_prepare_s {
6859 pub data: *mut ::std::os::raw::c_void,
6860 pub loop_: *mut uv_loop_t,
6861 pub type_: uv_handle_type,
6862 pub close_cb: uv_close_cb,
6863 pub handle_queue: [*mut ::std::os::raw::c_void; 2usize],
6864 pub u: uv_prepare_s__bindgen_ty_1,
6865 pub next_closing: *mut uv_handle_t,
6866 pub flags: ::std::os::raw::c_uint,
6867 pub prepare_cb: uv_prepare_cb,
6868 pub queue: [*mut ::std::os::raw::c_void; 2usize],
6869}
6870#[repr(C)]
6871#[derive(Copy, Clone)]
6872pub union uv_prepare_s__bindgen_ty_1 {
6873 pub fd: ::std::os::raw::c_int,
6874 pub reserved: [*mut ::std::os::raw::c_void; 4usize],
6875 _bindgen_union_align: [u64; 4usize],
6876}
6877#[test]
6878fn bindgen_test_layout_uv_prepare_s__bindgen_ty_1() {
6879 assert_eq!(
6880 ::std::mem::size_of::<uv_prepare_s__bindgen_ty_1>(),
6881 32usize,
6882 concat!("Size of: ", stringify!(uv_prepare_s__bindgen_ty_1))
6883 );
6884 assert_eq!(
6885 ::std::mem::align_of::<uv_prepare_s__bindgen_ty_1>(),
6886 8usize,
6887 concat!("Alignment of ", stringify!(uv_prepare_s__bindgen_ty_1))
6888 );
6889 assert_eq!(
6890 unsafe { &(*(::std::ptr::null::<uv_prepare_s__bindgen_ty_1>())).fd as *const _ as usize },
6891 0usize,
6892 concat!(
6893 "Offset of field: ",
6894 stringify!(uv_prepare_s__bindgen_ty_1),
6895 "::",
6896 stringify!(fd)
6897 )
6898 );
6899 assert_eq!(
6900 unsafe {
6901 &(*(::std::ptr::null::<uv_prepare_s__bindgen_ty_1>())).reserved as *const _ as usize
6902 },
6903 0usize,
6904 concat!(
6905 "Offset of field: ",
6906 stringify!(uv_prepare_s__bindgen_ty_1),
6907 "::",
6908 stringify!(reserved)
6909 )
6910 );
6911}
6912impl Default for uv_prepare_s__bindgen_ty_1 {
6913 fn default() -> Self {
6914 unsafe { ::std::mem::zeroed() }
6915 }
6916}
6917#[test]
6918fn bindgen_test_layout_uv_prepare_s() {
6919 assert_eq!(
6920 ::std::mem::size_of::<uv_prepare_s>(),
6921 120usize,
6922 concat!("Size of: ", stringify!(uv_prepare_s))
6923 );
6924 assert_eq!(
6925 ::std::mem::align_of::<uv_prepare_s>(),
6926 8usize,
6927 concat!("Alignment of ", stringify!(uv_prepare_s))
6928 );
6929 assert_eq!(
6930 unsafe { &(*(::std::ptr::null::<uv_prepare_s>())).data as *const _ as usize },
6931 0usize,
6932 concat!(
6933 "Offset of field: ",
6934 stringify!(uv_prepare_s),
6935 "::",
6936 stringify!(data)
6937 )
6938 );
6939 assert_eq!(
6940 unsafe { &(*(::std::ptr::null::<uv_prepare_s>())).loop_ as *const _ as usize },
6941 8usize,
6942 concat!(
6943 "Offset of field: ",
6944 stringify!(uv_prepare_s),
6945 "::",
6946 stringify!(loop_)
6947 )
6948 );
6949 assert_eq!(
6950 unsafe { &(*(::std::ptr::null::<uv_prepare_s>())).type_ as *const _ as usize },
6951 16usize,
6952 concat!(
6953 "Offset of field: ",
6954 stringify!(uv_prepare_s),
6955 "::",
6956 stringify!(type_)
6957 )
6958 );
6959 assert_eq!(
6960 unsafe { &(*(::std::ptr::null::<uv_prepare_s>())).close_cb as *const _ as usize },
6961 24usize,
6962 concat!(
6963 "Offset of field: ",
6964 stringify!(uv_prepare_s),
6965 "::",
6966 stringify!(close_cb)
6967 )
6968 );
6969 assert_eq!(
6970 unsafe { &(*(::std::ptr::null::<uv_prepare_s>())).handle_queue as *const _ as usize },
6971 32usize,
6972 concat!(
6973 "Offset of field: ",
6974 stringify!(uv_prepare_s),
6975 "::",
6976 stringify!(handle_queue)
6977 )
6978 );
6979 assert_eq!(
6980 unsafe { &(*(::std::ptr::null::<uv_prepare_s>())).u as *const _ as usize },
6981 48usize,
6982 concat!(
6983 "Offset of field: ",
6984 stringify!(uv_prepare_s),
6985 "::",
6986 stringify!(u)
6987 )
6988 );
6989 assert_eq!(
6990 unsafe { &(*(::std::ptr::null::<uv_prepare_s>())).next_closing as *const _ as usize },
6991 80usize,
6992 concat!(
6993 "Offset of field: ",
6994 stringify!(uv_prepare_s),
6995 "::",
6996 stringify!(next_closing)
6997 )
6998 );
6999 assert_eq!(
7000 unsafe { &(*(::std::ptr::null::<uv_prepare_s>())).flags as *const _ as usize },
7001 88usize,
7002 concat!(
7003 "Offset of field: ",
7004 stringify!(uv_prepare_s),
7005 "::",
7006 stringify!(flags)
7007 )
7008 );
7009 assert_eq!(
7010 unsafe { &(*(::std::ptr::null::<uv_prepare_s>())).prepare_cb as *const _ as usize },
7011 96usize,
7012 concat!(
7013 "Offset of field: ",
7014 stringify!(uv_prepare_s),
7015 "::",
7016 stringify!(prepare_cb)
7017 )
7018 );
7019 assert_eq!(
7020 unsafe { &(*(::std::ptr::null::<uv_prepare_s>())).queue as *const _ as usize },
7021 104usize,
7022 concat!(
7023 "Offset of field: ",
7024 stringify!(uv_prepare_s),
7025 "::",
7026 stringify!(queue)
7027 )
7028 );
7029}
7030impl Default for uv_prepare_s {
7031 fn default() -> Self {
7032 unsafe { ::std::mem::zeroed() }
7033 }
7034}
7035extern "C" {
7036 pub fn uv_prepare_init(
7037 arg1: *mut uv_loop_t,
7038 prepare: *mut uv_prepare_t,
7039 ) -> ::std::os::raw::c_int;
7040}
7041extern "C" {
7042 pub fn uv_prepare_start(prepare: *mut uv_prepare_t, cb: uv_prepare_cb)
7043 -> ::std::os::raw::c_int;
7044}
7045extern "C" {
7046 pub fn uv_prepare_stop(prepare: *mut uv_prepare_t) -> ::std::os::raw::c_int;
7047}
7048#[repr(C)]
7049#[derive(Copy, Clone)]
7050pub struct uv_check_s {
7051 pub data: *mut ::std::os::raw::c_void,
7052 pub loop_: *mut uv_loop_t,
7053 pub type_: uv_handle_type,
7054 pub close_cb: uv_close_cb,
7055 pub handle_queue: [*mut ::std::os::raw::c_void; 2usize],
7056 pub u: uv_check_s__bindgen_ty_1,
7057 pub next_closing: *mut uv_handle_t,
7058 pub flags: ::std::os::raw::c_uint,
7059 pub check_cb: uv_check_cb,
7060 pub queue: [*mut ::std::os::raw::c_void; 2usize],
7061}
7062#[repr(C)]
7063#[derive(Copy, Clone)]
7064pub union uv_check_s__bindgen_ty_1 {
7065 pub fd: ::std::os::raw::c_int,
7066 pub reserved: [*mut ::std::os::raw::c_void; 4usize],
7067 _bindgen_union_align: [u64; 4usize],
7068}
7069#[test]
7070fn bindgen_test_layout_uv_check_s__bindgen_ty_1() {
7071 assert_eq!(
7072 ::std::mem::size_of::<uv_check_s__bindgen_ty_1>(),
7073 32usize,
7074 concat!("Size of: ", stringify!(uv_check_s__bindgen_ty_1))
7075 );
7076 assert_eq!(
7077 ::std::mem::align_of::<uv_check_s__bindgen_ty_1>(),
7078 8usize,
7079 concat!("Alignment of ", stringify!(uv_check_s__bindgen_ty_1))
7080 );
7081 assert_eq!(
7082 unsafe { &(*(::std::ptr::null::<uv_check_s__bindgen_ty_1>())).fd as *const _ as usize },
7083 0usize,
7084 concat!(
7085 "Offset of field: ",
7086 stringify!(uv_check_s__bindgen_ty_1),
7087 "::",
7088 stringify!(fd)
7089 )
7090 );
7091 assert_eq!(
7092 unsafe {
7093 &(*(::std::ptr::null::<uv_check_s__bindgen_ty_1>())).reserved as *const _ as usize
7094 },
7095 0usize,
7096 concat!(
7097 "Offset of field: ",
7098 stringify!(uv_check_s__bindgen_ty_1),
7099 "::",
7100 stringify!(reserved)
7101 )
7102 );
7103}
7104impl Default for uv_check_s__bindgen_ty_1 {
7105 fn default() -> Self {
7106 unsafe { ::std::mem::zeroed() }
7107 }
7108}
7109#[test]
7110fn bindgen_test_layout_uv_check_s() {
7111 assert_eq!(
7112 ::std::mem::size_of::<uv_check_s>(),
7113 120usize,
7114 concat!("Size of: ", stringify!(uv_check_s))
7115 );
7116 assert_eq!(
7117 ::std::mem::align_of::<uv_check_s>(),
7118 8usize,
7119 concat!("Alignment of ", stringify!(uv_check_s))
7120 );
7121 assert_eq!(
7122 unsafe { &(*(::std::ptr::null::<uv_check_s>())).data as *const _ as usize },
7123 0usize,
7124 concat!(
7125 "Offset of field: ",
7126 stringify!(uv_check_s),
7127 "::",
7128 stringify!(data)
7129 )
7130 );
7131 assert_eq!(
7132 unsafe { &(*(::std::ptr::null::<uv_check_s>())).loop_ as *const _ as usize },
7133 8usize,
7134 concat!(
7135 "Offset of field: ",
7136 stringify!(uv_check_s),
7137 "::",
7138 stringify!(loop_)
7139 )
7140 );
7141 assert_eq!(
7142 unsafe { &(*(::std::ptr::null::<uv_check_s>())).type_ as *const _ as usize },
7143 16usize,
7144 concat!(
7145 "Offset of field: ",
7146 stringify!(uv_check_s),
7147 "::",
7148 stringify!(type_)
7149 )
7150 );
7151 assert_eq!(
7152 unsafe { &(*(::std::ptr::null::<uv_check_s>())).close_cb as *const _ as usize },
7153 24usize,
7154 concat!(
7155 "Offset of field: ",
7156 stringify!(uv_check_s),
7157 "::",
7158 stringify!(close_cb)
7159 )
7160 );
7161 assert_eq!(
7162 unsafe { &(*(::std::ptr::null::<uv_check_s>())).handle_queue as *const _ as usize },
7163 32usize,
7164 concat!(
7165 "Offset of field: ",
7166 stringify!(uv_check_s),
7167 "::",
7168 stringify!(handle_queue)
7169 )
7170 );
7171 assert_eq!(
7172 unsafe { &(*(::std::ptr::null::<uv_check_s>())).u as *const _ as usize },
7173 48usize,
7174 concat!(
7175 "Offset of field: ",
7176 stringify!(uv_check_s),
7177 "::",
7178 stringify!(u)
7179 )
7180 );
7181 assert_eq!(
7182 unsafe { &(*(::std::ptr::null::<uv_check_s>())).next_closing as *const _ as usize },
7183 80usize,
7184 concat!(
7185 "Offset of field: ",
7186 stringify!(uv_check_s),
7187 "::",
7188 stringify!(next_closing)
7189 )
7190 );
7191 assert_eq!(
7192 unsafe { &(*(::std::ptr::null::<uv_check_s>())).flags as *const _ as usize },
7193 88usize,
7194 concat!(
7195 "Offset of field: ",
7196 stringify!(uv_check_s),
7197 "::",
7198 stringify!(flags)
7199 )
7200 );
7201 assert_eq!(
7202 unsafe { &(*(::std::ptr::null::<uv_check_s>())).check_cb as *const _ as usize },
7203 96usize,
7204 concat!(
7205 "Offset of field: ",
7206 stringify!(uv_check_s),
7207 "::",
7208 stringify!(check_cb)
7209 )
7210 );
7211 assert_eq!(
7212 unsafe { &(*(::std::ptr::null::<uv_check_s>())).queue as *const _ as usize },
7213 104usize,
7214 concat!(
7215 "Offset of field: ",
7216 stringify!(uv_check_s),
7217 "::",
7218 stringify!(queue)
7219 )
7220 );
7221}
7222impl Default for uv_check_s {
7223 fn default() -> Self {
7224 unsafe { ::std::mem::zeroed() }
7225 }
7226}
7227extern "C" {
7228 pub fn uv_check_init(arg1: *mut uv_loop_t, check: *mut uv_check_t) -> ::std::os::raw::c_int;
7229}
7230extern "C" {
7231 pub fn uv_check_start(check: *mut uv_check_t, cb: uv_check_cb) -> ::std::os::raw::c_int;
7232}
7233extern "C" {
7234 pub fn uv_check_stop(check: *mut uv_check_t) -> ::std::os::raw::c_int;
7235}
7236#[repr(C)]
7237#[derive(Copy, Clone)]
7238pub struct uv_idle_s {
7239 pub data: *mut ::std::os::raw::c_void,
7240 pub loop_: *mut uv_loop_t,
7241 pub type_: uv_handle_type,
7242 pub close_cb: uv_close_cb,
7243 pub handle_queue: [*mut ::std::os::raw::c_void; 2usize],
7244 pub u: uv_idle_s__bindgen_ty_1,
7245 pub next_closing: *mut uv_handle_t,
7246 pub flags: ::std::os::raw::c_uint,
7247 pub idle_cb: uv_idle_cb,
7248 pub queue: [*mut ::std::os::raw::c_void; 2usize],
7249}
7250#[repr(C)]
7251#[derive(Copy, Clone)]
7252pub union uv_idle_s__bindgen_ty_1 {
7253 pub fd: ::std::os::raw::c_int,
7254 pub reserved: [*mut ::std::os::raw::c_void; 4usize],
7255 _bindgen_union_align: [u64; 4usize],
7256}
7257#[test]
7258fn bindgen_test_layout_uv_idle_s__bindgen_ty_1() {
7259 assert_eq!(
7260 ::std::mem::size_of::<uv_idle_s__bindgen_ty_1>(),
7261 32usize,
7262 concat!("Size of: ", stringify!(uv_idle_s__bindgen_ty_1))
7263 );
7264 assert_eq!(
7265 ::std::mem::align_of::<uv_idle_s__bindgen_ty_1>(),
7266 8usize,
7267 concat!("Alignment of ", stringify!(uv_idle_s__bindgen_ty_1))
7268 );
7269 assert_eq!(
7270 unsafe { &(*(::std::ptr::null::<uv_idle_s__bindgen_ty_1>())).fd as *const _ as usize },
7271 0usize,
7272 concat!(
7273 "Offset of field: ",
7274 stringify!(uv_idle_s__bindgen_ty_1),
7275 "::",
7276 stringify!(fd)
7277 )
7278 );
7279 assert_eq!(
7280 unsafe {
7281 &(*(::std::ptr::null::<uv_idle_s__bindgen_ty_1>())).reserved as *const _ as usize
7282 },
7283 0usize,
7284 concat!(
7285 "Offset of field: ",
7286 stringify!(uv_idle_s__bindgen_ty_1),
7287 "::",
7288 stringify!(reserved)
7289 )
7290 );
7291}
7292impl Default for uv_idle_s__bindgen_ty_1 {
7293 fn default() -> Self {
7294 unsafe { ::std::mem::zeroed() }
7295 }
7296}
7297#[test]
7298fn bindgen_test_layout_uv_idle_s() {
7299 assert_eq!(
7300 ::std::mem::size_of::<uv_idle_s>(),
7301 120usize,
7302 concat!("Size of: ", stringify!(uv_idle_s))
7303 );
7304 assert_eq!(
7305 ::std::mem::align_of::<uv_idle_s>(),
7306 8usize,
7307 concat!("Alignment of ", stringify!(uv_idle_s))
7308 );
7309 assert_eq!(
7310 unsafe { &(*(::std::ptr::null::<uv_idle_s>())).data as *const _ as usize },
7311 0usize,
7312 concat!(
7313 "Offset of field: ",
7314 stringify!(uv_idle_s),
7315 "::",
7316 stringify!(data)
7317 )
7318 );
7319 assert_eq!(
7320 unsafe { &(*(::std::ptr::null::<uv_idle_s>())).loop_ as *const _ as usize },
7321 8usize,
7322 concat!(
7323 "Offset of field: ",
7324 stringify!(uv_idle_s),
7325 "::",
7326 stringify!(loop_)
7327 )
7328 );
7329 assert_eq!(
7330 unsafe { &(*(::std::ptr::null::<uv_idle_s>())).type_ as *const _ as usize },
7331 16usize,
7332 concat!(
7333 "Offset of field: ",
7334 stringify!(uv_idle_s),
7335 "::",
7336 stringify!(type_)
7337 )
7338 );
7339 assert_eq!(
7340 unsafe { &(*(::std::ptr::null::<uv_idle_s>())).close_cb as *const _ as usize },
7341 24usize,
7342 concat!(
7343 "Offset of field: ",
7344 stringify!(uv_idle_s),
7345 "::",
7346 stringify!(close_cb)
7347 )
7348 );
7349 assert_eq!(
7350 unsafe { &(*(::std::ptr::null::<uv_idle_s>())).handle_queue as *const _ as usize },
7351 32usize,
7352 concat!(
7353 "Offset of field: ",
7354 stringify!(uv_idle_s),
7355 "::",
7356 stringify!(handle_queue)
7357 )
7358 );
7359 assert_eq!(
7360 unsafe { &(*(::std::ptr::null::<uv_idle_s>())).u as *const _ as usize },
7361 48usize,
7362 concat!(
7363 "Offset of field: ",
7364 stringify!(uv_idle_s),
7365 "::",
7366 stringify!(u)
7367 )
7368 );
7369 assert_eq!(
7370 unsafe { &(*(::std::ptr::null::<uv_idle_s>())).next_closing as *const _ as usize },
7371 80usize,
7372 concat!(
7373 "Offset of field: ",
7374 stringify!(uv_idle_s),
7375 "::",
7376 stringify!(next_closing)
7377 )
7378 );
7379 assert_eq!(
7380 unsafe { &(*(::std::ptr::null::<uv_idle_s>())).flags as *const _ as usize },
7381 88usize,
7382 concat!(
7383 "Offset of field: ",
7384 stringify!(uv_idle_s),
7385 "::",
7386 stringify!(flags)
7387 )
7388 );
7389 assert_eq!(
7390 unsafe { &(*(::std::ptr::null::<uv_idle_s>())).idle_cb as *const _ as usize },
7391 96usize,
7392 concat!(
7393 "Offset of field: ",
7394 stringify!(uv_idle_s),
7395 "::",
7396 stringify!(idle_cb)
7397 )
7398 );
7399 assert_eq!(
7400 unsafe { &(*(::std::ptr::null::<uv_idle_s>())).queue as *const _ as usize },
7401 104usize,
7402 concat!(
7403 "Offset of field: ",
7404 stringify!(uv_idle_s),
7405 "::",
7406 stringify!(queue)
7407 )
7408 );
7409}
7410impl Default for uv_idle_s {
7411 fn default() -> Self {
7412 unsafe { ::std::mem::zeroed() }
7413 }
7414}
7415extern "C" {
7416 pub fn uv_idle_init(arg1: *mut uv_loop_t, idle: *mut uv_idle_t) -> ::std::os::raw::c_int;
7417}
7418extern "C" {
7419 pub fn uv_idle_start(idle: *mut uv_idle_t, cb: uv_idle_cb) -> ::std::os::raw::c_int;
7420}
7421extern "C" {
7422 pub fn uv_idle_stop(idle: *mut uv_idle_t) -> ::std::os::raw::c_int;
7423}
7424#[repr(C)]
7425#[derive(Copy, Clone)]
7426pub struct uv_async_s {
7427 pub data: *mut ::std::os::raw::c_void,
7428 pub loop_: *mut uv_loop_t,
7429 pub type_: uv_handle_type,
7430 pub close_cb: uv_close_cb,
7431 pub handle_queue: [*mut ::std::os::raw::c_void; 2usize],
7432 pub u: uv_async_s__bindgen_ty_1,
7433 pub next_closing: *mut uv_handle_t,
7434 pub flags: ::std::os::raw::c_uint,
7435 pub async_cb: uv_async_cb,
7436 pub queue: [*mut ::std::os::raw::c_void; 2usize],
7437 pub pending: ::std::os::raw::c_int,
7438}
7439#[repr(C)]
7440#[derive(Copy, Clone)]
7441pub union uv_async_s__bindgen_ty_1 {
7442 pub fd: ::std::os::raw::c_int,
7443 pub reserved: [*mut ::std::os::raw::c_void; 4usize],
7444 _bindgen_union_align: [u64; 4usize],
7445}
7446#[test]
7447fn bindgen_test_layout_uv_async_s__bindgen_ty_1() {
7448 assert_eq!(
7449 ::std::mem::size_of::<uv_async_s__bindgen_ty_1>(),
7450 32usize,
7451 concat!("Size of: ", stringify!(uv_async_s__bindgen_ty_1))
7452 );
7453 assert_eq!(
7454 ::std::mem::align_of::<uv_async_s__bindgen_ty_1>(),
7455 8usize,
7456 concat!("Alignment of ", stringify!(uv_async_s__bindgen_ty_1))
7457 );
7458 assert_eq!(
7459 unsafe { &(*(::std::ptr::null::<uv_async_s__bindgen_ty_1>())).fd as *const _ as usize },
7460 0usize,
7461 concat!(
7462 "Offset of field: ",
7463 stringify!(uv_async_s__bindgen_ty_1),
7464 "::",
7465 stringify!(fd)
7466 )
7467 );
7468 assert_eq!(
7469 unsafe {
7470 &(*(::std::ptr::null::<uv_async_s__bindgen_ty_1>())).reserved as *const _ as usize
7471 },
7472 0usize,
7473 concat!(
7474 "Offset of field: ",
7475 stringify!(uv_async_s__bindgen_ty_1),
7476 "::",
7477 stringify!(reserved)
7478 )
7479 );
7480}
7481impl Default for uv_async_s__bindgen_ty_1 {
7482 fn default() -> Self {
7483 unsafe { ::std::mem::zeroed() }
7484 }
7485}
7486#[test]
7487fn bindgen_test_layout_uv_async_s() {
7488 assert_eq!(
7489 ::std::mem::size_of::<uv_async_s>(),
7490 128usize,
7491 concat!("Size of: ", stringify!(uv_async_s))
7492 );
7493 assert_eq!(
7494 ::std::mem::align_of::<uv_async_s>(),
7495 8usize,
7496 concat!("Alignment of ", stringify!(uv_async_s))
7497 );
7498 assert_eq!(
7499 unsafe { &(*(::std::ptr::null::<uv_async_s>())).data as *const _ as usize },
7500 0usize,
7501 concat!(
7502 "Offset of field: ",
7503 stringify!(uv_async_s),
7504 "::",
7505 stringify!(data)
7506 )
7507 );
7508 assert_eq!(
7509 unsafe { &(*(::std::ptr::null::<uv_async_s>())).loop_ as *const _ as usize },
7510 8usize,
7511 concat!(
7512 "Offset of field: ",
7513 stringify!(uv_async_s),
7514 "::",
7515 stringify!(loop_)
7516 )
7517 );
7518 assert_eq!(
7519 unsafe { &(*(::std::ptr::null::<uv_async_s>())).type_ as *const _ as usize },
7520 16usize,
7521 concat!(
7522 "Offset of field: ",
7523 stringify!(uv_async_s),
7524 "::",
7525 stringify!(type_)
7526 )
7527 );
7528 assert_eq!(
7529 unsafe { &(*(::std::ptr::null::<uv_async_s>())).close_cb as *const _ as usize },
7530 24usize,
7531 concat!(
7532 "Offset of field: ",
7533 stringify!(uv_async_s),
7534 "::",
7535 stringify!(close_cb)
7536 )
7537 );
7538 assert_eq!(
7539 unsafe { &(*(::std::ptr::null::<uv_async_s>())).handle_queue as *const _ as usize },
7540 32usize,
7541 concat!(
7542 "Offset of field: ",
7543 stringify!(uv_async_s),
7544 "::",
7545 stringify!(handle_queue)
7546 )
7547 );
7548 assert_eq!(
7549 unsafe { &(*(::std::ptr::null::<uv_async_s>())).u as *const _ as usize },
7550 48usize,
7551 concat!(
7552 "Offset of field: ",
7553 stringify!(uv_async_s),
7554 "::",
7555 stringify!(u)
7556 )
7557 );
7558 assert_eq!(
7559 unsafe { &(*(::std::ptr::null::<uv_async_s>())).next_closing as *const _ as usize },
7560 80usize,
7561 concat!(
7562 "Offset of field: ",
7563 stringify!(uv_async_s),
7564 "::",
7565 stringify!(next_closing)
7566 )
7567 );
7568 assert_eq!(
7569 unsafe { &(*(::std::ptr::null::<uv_async_s>())).flags as *const _ as usize },
7570 88usize,
7571 concat!(
7572 "Offset of field: ",
7573 stringify!(uv_async_s),
7574 "::",
7575 stringify!(flags)
7576 )
7577 );
7578 assert_eq!(
7579 unsafe { &(*(::std::ptr::null::<uv_async_s>())).async_cb as *const _ as usize },
7580 96usize,
7581 concat!(
7582 "Offset of field: ",
7583 stringify!(uv_async_s),
7584 "::",
7585 stringify!(async_cb)
7586 )
7587 );
7588 assert_eq!(
7589 unsafe { &(*(::std::ptr::null::<uv_async_s>())).queue as *const _ as usize },
7590 104usize,
7591 concat!(
7592 "Offset of field: ",
7593 stringify!(uv_async_s),
7594 "::",
7595 stringify!(queue)
7596 )
7597 );
7598 assert_eq!(
7599 unsafe { &(*(::std::ptr::null::<uv_async_s>())).pending as *const _ as usize },
7600 120usize,
7601 concat!(
7602 "Offset of field: ",
7603 stringify!(uv_async_s),
7604 "::",
7605 stringify!(pending)
7606 )
7607 );
7608}
7609impl Default for uv_async_s {
7610 fn default() -> Self {
7611 unsafe { ::std::mem::zeroed() }
7612 }
7613}
7614extern "C" {
7615 pub fn uv_async_init(
7616 arg1: *mut uv_loop_t,
7617 async_: *mut uv_async_t,
7618 async_cb: uv_async_cb,
7619 ) -> ::std::os::raw::c_int;
7620}
7621extern "C" {
7622 pub fn uv_async_send(async_: *mut uv_async_t) -> ::std::os::raw::c_int;
7623}
7624#[repr(C)]
7625#[derive(Copy, Clone)]
7626pub struct uv_timer_s {
7627 pub data: *mut ::std::os::raw::c_void,
7628 pub loop_: *mut uv_loop_t,
7629 pub type_: uv_handle_type,
7630 pub close_cb: uv_close_cb,
7631 pub handle_queue: [*mut ::std::os::raw::c_void; 2usize],
7632 pub u: uv_timer_s__bindgen_ty_1,
7633 pub next_closing: *mut uv_handle_t,
7634 pub flags: ::std::os::raw::c_uint,
7635 pub timer_cb: uv_timer_cb,
7636 pub heap_node: [*mut ::std::os::raw::c_void; 3usize],
7637 pub timeout: u64,
7638 pub repeat: u64,
7639 pub start_id: u64,
7640}
7641#[repr(C)]
7642#[derive(Copy, Clone)]
7643pub union uv_timer_s__bindgen_ty_1 {
7644 pub fd: ::std::os::raw::c_int,
7645 pub reserved: [*mut ::std::os::raw::c_void; 4usize],
7646 _bindgen_union_align: [u64; 4usize],
7647}
7648#[test]
7649fn bindgen_test_layout_uv_timer_s__bindgen_ty_1() {
7650 assert_eq!(
7651 ::std::mem::size_of::<uv_timer_s__bindgen_ty_1>(),
7652 32usize,
7653 concat!("Size of: ", stringify!(uv_timer_s__bindgen_ty_1))
7654 );
7655 assert_eq!(
7656 ::std::mem::align_of::<uv_timer_s__bindgen_ty_1>(),
7657 8usize,
7658 concat!("Alignment of ", stringify!(uv_timer_s__bindgen_ty_1))
7659 );
7660 assert_eq!(
7661 unsafe { &(*(::std::ptr::null::<uv_timer_s__bindgen_ty_1>())).fd as *const _ as usize },
7662 0usize,
7663 concat!(
7664 "Offset of field: ",
7665 stringify!(uv_timer_s__bindgen_ty_1),
7666 "::",
7667 stringify!(fd)
7668 )
7669 );
7670 assert_eq!(
7671 unsafe {
7672 &(*(::std::ptr::null::<uv_timer_s__bindgen_ty_1>())).reserved as *const _ as usize
7673 },
7674 0usize,
7675 concat!(
7676 "Offset of field: ",
7677 stringify!(uv_timer_s__bindgen_ty_1),
7678 "::",
7679 stringify!(reserved)
7680 )
7681 );
7682}
7683impl Default for uv_timer_s__bindgen_ty_1 {
7684 fn default() -> Self {
7685 unsafe { ::std::mem::zeroed() }
7686 }
7687}
7688#[test]
7689fn bindgen_test_layout_uv_timer_s() {
7690 assert_eq!(
7691 ::std::mem::size_of::<uv_timer_s>(),
7692 152usize,
7693 concat!("Size of: ", stringify!(uv_timer_s))
7694 );
7695 assert_eq!(
7696 ::std::mem::align_of::<uv_timer_s>(),
7697 8usize,
7698 concat!("Alignment of ", stringify!(uv_timer_s))
7699 );
7700 assert_eq!(
7701 unsafe { &(*(::std::ptr::null::<uv_timer_s>())).data as *const _ as usize },
7702 0usize,
7703 concat!(
7704 "Offset of field: ",
7705 stringify!(uv_timer_s),
7706 "::",
7707 stringify!(data)
7708 )
7709 );
7710 assert_eq!(
7711 unsafe { &(*(::std::ptr::null::<uv_timer_s>())).loop_ as *const _ as usize },
7712 8usize,
7713 concat!(
7714 "Offset of field: ",
7715 stringify!(uv_timer_s),
7716 "::",
7717 stringify!(loop_)
7718 )
7719 );
7720 assert_eq!(
7721 unsafe { &(*(::std::ptr::null::<uv_timer_s>())).type_ as *const _ as usize },
7722 16usize,
7723 concat!(
7724 "Offset of field: ",
7725 stringify!(uv_timer_s),
7726 "::",
7727 stringify!(type_)
7728 )
7729 );
7730 assert_eq!(
7731 unsafe { &(*(::std::ptr::null::<uv_timer_s>())).close_cb as *const _ as usize },
7732 24usize,
7733 concat!(
7734 "Offset of field: ",
7735 stringify!(uv_timer_s),
7736 "::",
7737 stringify!(close_cb)
7738 )
7739 );
7740 assert_eq!(
7741 unsafe { &(*(::std::ptr::null::<uv_timer_s>())).handle_queue as *const _ as usize },
7742 32usize,
7743 concat!(
7744 "Offset of field: ",
7745 stringify!(uv_timer_s),
7746 "::",
7747 stringify!(handle_queue)
7748 )
7749 );
7750 assert_eq!(
7751 unsafe { &(*(::std::ptr::null::<uv_timer_s>())).u as *const _ as usize },
7752 48usize,
7753 concat!(
7754 "Offset of field: ",
7755 stringify!(uv_timer_s),
7756 "::",
7757 stringify!(u)
7758 )
7759 );
7760 assert_eq!(
7761 unsafe { &(*(::std::ptr::null::<uv_timer_s>())).next_closing as *const _ as usize },
7762 80usize,
7763 concat!(
7764 "Offset of field: ",
7765 stringify!(uv_timer_s),
7766 "::",
7767 stringify!(next_closing)
7768 )
7769 );
7770 assert_eq!(
7771 unsafe { &(*(::std::ptr::null::<uv_timer_s>())).flags as *const _ as usize },
7772 88usize,
7773 concat!(
7774 "Offset of field: ",
7775 stringify!(uv_timer_s),
7776 "::",
7777 stringify!(flags)
7778 )
7779 );
7780 assert_eq!(
7781 unsafe { &(*(::std::ptr::null::<uv_timer_s>())).timer_cb as *const _ as usize },
7782 96usize,
7783 concat!(
7784 "Offset of field: ",
7785 stringify!(uv_timer_s),
7786 "::",
7787 stringify!(timer_cb)
7788 )
7789 );
7790 assert_eq!(
7791 unsafe { &(*(::std::ptr::null::<uv_timer_s>())).heap_node as *const _ as usize },
7792 104usize,
7793 concat!(
7794 "Offset of field: ",
7795 stringify!(uv_timer_s),
7796 "::",
7797 stringify!(heap_node)
7798 )
7799 );
7800 assert_eq!(
7801 unsafe { &(*(::std::ptr::null::<uv_timer_s>())).timeout as *const _ as usize },
7802 128usize,
7803 concat!(
7804 "Offset of field: ",
7805 stringify!(uv_timer_s),
7806 "::",
7807 stringify!(timeout)
7808 )
7809 );
7810 assert_eq!(
7811 unsafe { &(*(::std::ptr::null::<uv_timer_s>())).repeat as *const _ as usize },
7812 136usize,
7813 concat!(
7814 "Offset of field: ",
7815 stringify!(uv_timer_s),
7816 "::",
7817 stringify!(repeat)
7818 )
7819 );
7820 assert_eq!(
7821 unsafe { &(*(::std::ptr::null::<uv_timer_s>())).start_id as *const _ as usize },
7822 144usize,
7823 concat!(
7824 "Offset of field: ",
7825 stringify!(uv_timer_s),
7826 "::",
7827 stringify!(start_id)
7828 )
7829 );
7830}
7831impl Default for uv_timer_s {
7832 fn default() -> Self {
7833 unsafe { ::std::mem::zeroed() }
7834 }
7835}
7836extern "C" {
7837 pub fn uv_timer_init(arg1: *mut uv_loop_t, handle: *mut uv_timer_t) -> ::std::os::raw::c_int;
7838}
7839extern "C" {
7840 pub fn uv_timer_start(
7841 handle: *mut uv_timer_t,
7842 cb: uv_timer_cb,
7843 timeout: u64,
7844 repeat: u64,
7845 ) -> ::std::os::raw::c_int;
7846}
7847extern "C" {
7848 pub fn uv_timer_stop(handle: *mut uv_timer_t) -> ::std::os::raw::c_int;
7849}
7850extern "C" {
7851 pub fn uv_timer_again(handle: *mut uv_timer_t) -> ::std::os::raw::c_int;
7852}
7853extern "C" {
7854 pub fn uv_timer_set_repeat(handle: *mut uv_timer_t, repeat: u64);
7855}
7856extern "C" {
7857 pub fn uv_timer_get_repeat(handle: *const uv_timer_t) -> u64;
7858}
7859extern "C" {
7860 pub fn uv_timer_get_due_in(handle: *const uv_timer_t) -> u64;
7861}
7862#[repr(C)]
7863#[derive(Debug, Copy, Clone)]
7864pub struct uv_getaddrinfo_s {
7865 pub data: *mut ::std::os::raw::c_void,
7866 pub type_: uv_req_type,
7867 pub reserved: [*mut ::std::os::raw::c_void; 6usize],
7868 pub loop_: *mut uv_loop_t,
7869 pub work_req: uv__work,
7870 pub cb: uv_getaddrinfo_cb,
7871 pub hints: *mut addrinfo,
7872 pub hostname: *mut ::std::os::raw::c_char,
7873 pub service: *mut ::std::os::raw::c_char,
7874 pub addrinfo: *mut addrinfo,
7875 pub retcode: ::std::os::raw::c_int,
7876}
7877#[test]
7878fn bindgen_test_layout_uv_getaddrinfo_s() {
7879 assert_eq!(
7880 ::std::mem::size_of::<uv_getaddrinfo_s>(),
7881 160usize,
7882 concat!("Size of: ", stringify!(uv_getaddrinfo_s))
7883 );
7884 assert_eq!(
7885 ::std::mem::align_of::<uv_getaddrinfo_s>(),
7886 8usize,
7887 concat!("Alignment of ", stringify!(uv_getaddrinfo_s))
7888 );
7889 assert_eq!(
7890 unsafe { &(*(::std::ptr::null::<uv_getaddrinfo_s>())).data as *const _ as usize },
7891 0usize,
7892 concat!(
7893 "Offset of field: ",
7894 stringify!(uv_getaddrinfo_s),
7895 "::",
7896 stringify!(data)
7897 )
7898 );
7899 assert_eq!(
7900 unsafe { &(*(::std::ptr::null::<uv_getaddrinfo_s>())).type_ as *const _ as usize },
7901 8usize,
7902 concat!(
7903 "Offset of field: ",
7904 stringify!(uv_getaddrinfo_s),
7905 "::",
7906 stringify!(type_)
7907 )
7908 );
7909 assert_eq!(
7910 unsafe { &(*(::std::ptr::null::<uv_getaddrinfo_s>())).reserved as *const _ as usize },
7911 16usize,
7912 concat!(
7913 "Offset of field: ",
7914 stringify!(uv_getaddrinfo_s),
7915 "::",
7916 stringify!(reserved)
7917 )
7918 );
7919 assert_eq!(
7920 unsafe { &(*(::std::ptr::null::<uv_getaddrinfo_s>())).loop_ as *const _ as usize },
7921 64usize,
7922 concat!(
7923 "Offset of field: ",
7924 stringify!(uv_getaddrinfo_s),
7925 "::",
7926 stringify!(loop_)
7927 )
7928 );
7929 assert_eq!(
7930 unsafe { &(*(::std::ptr::null::<uv_getaddrinfo_s>())).work_req as *const _ as usize },
7931 72usize,
7932 concat!(
7933 "Offset of field: ",
7934 stringify!(uv_getaddrinfo_s),
7935 "::",
7936 stringify!(work_req)
7937 )
7938 );
7939 assert_eq!(
7940 unsafe { &(*(::std::ptr::null::<uv_getaddrinfo_s>())).cb as *const _ as usize },
7941 112usize,
7942 concat!(
7943 "Offset of field: ",
7944 stringify!(uv_getaddrinfo_s),
7945 "::",
7946 stringify!(cb)
7947 )
7948 );
7949 assert_eq!(
7950 unsafe { &(*(::std::ptr::null::<uv_getaddrinfo_s>())).hints as *const _ as usize },
7951 120usize,
7952 concat!(
7953 "Offset of field: ",
7954 stringify!(uv_getaddrinfo_s),
7955 "::",
7956 stringify!(hints)
7957 )
7958 );
7959 assert_eq!(
7960 unsafe { &(*(::std::ptr::null::<uv_getaddrinfo_s>())).hostname as *const _ as usize },
7961 128usize,
7962 concat!(
7963 "Offset of field: ",
7964 stringify!(uv_getaddrinfo_s),
7965 "::",
7966 stringify!(hostname)
7967 )
7968 );
7969 assert_eq!(
7970 unsafe { &(*(::std::ptr::null::<uv_getaddrinfo_s>())).service as *const _ as usize },
7971 136usize,
7972 concat!(
7973 "Offset of field: ",
7974 stringify!(uv_getaddrinfo_s),
7975 "::",
7976 stringify!(service)
7977 )
7978 );
7979 assert_eq!(
7980 unsafe { &(*(::std::ptr::null::<uv_getaddrinfo_s>())).addrinfo as *const _ as usize },
7981 144usize,
7982 concat!(
7983 "Offset of field: ",
7984 stringify!(uv_getaddrinfo_s),
7985 "::",
7986 stringify!(addrinfo)
7987 )
7988 );
7989 assert_eq!(
7990 unsafe { &(*(::std::ptr::null::<uv_getaddrinfo_s>())).retcode as *const _ as usize },
7991 152usize,
7992 concat!(
7993 "Offset of field: ",
7994 stringify!(uv_getaddrinfo_s),
7995 "::",
7996 stringify!(retcode)
7997 )
7998 );
7999}
8000impl Default for uv_getaddrinfo_s {
8001 fn default() -> Self {
8002 unsafe { ::std::mem::zeroed() }
8003 }
8004}
8005extern "C" {
8006 pub fn uv_getaddrinfo(
8007 loop_: *mut uv_loop_t,
8008 req: *mut uv_getaddrinfo_t,
8009 getaddrinfo_cb: uv_getaddrinfo_cb,
8010 node: *const ::std::os::raw::c_char,
8011 service: *const ::std::os::raw::c_char,
8012 hints: *const addrinfo,
8013 ) -> ::std::os::raw::c_int;
8014}
8015extern "C" {
8016 pub fn uv_freeaddrinfo(ai: *mut addrinfo);
8017}
8018#[repr(C)]
8019#[derive(Copy, Clone)]
8020pub struct uv_getnameinfo_s {
8021 pub data: *mut ::std::os::raw::c_void,
8022 pub type_: uv_req_type,
8023 pub reserved: [*mut ::std::os::raw::c_void; 6usize],
8024 pub loop_: *mut uv_loop_t,
8025 pub work_req: uv__work,
8026 pub getnameinfo_cb: uv_getnameinfo_cb,
8027 pub storage: sockaddr_storage,
8028 pub flags: ::std::os::raw::c_int,
8029 pub host: [::std::os::raw::c_char; 1025usize],
8030 pub service: [::std::os::raw::c_char; 32usize],
8031 pub retcode: ::std::os::raw::c_int,
8032}
8033#[test]
8034fn bindgen_test_layout_uv_getnameinfo_s() {
8035 assert_eq!(
8036 ::std::mem::size_of::<uv_getnameinfo_s>(),
8037 1320usize,
8038 concat!("Size of: ", stringify!(uv_getnameinfo_s))
8039 );
8040 assert_eq!(
8041 ::std::mem::align_of::<uv_getnameinfo_s>(),
8042 8usize,
8043 concat!("Alignment of ", stringify!(uv_getnameinfo_s))
8044 );
8045 assert_eq!(
8046 unsafe { &(*(::std::ptr::null::<uv_getnameinfo_s>())).data as *const _ as usize },
8047 0usize,
8048 concat!(
8049 "Offset of field: ",
8050 stringify!(uv_getnameinfo_s),
8051 "::",
8052 stringify!(data)
8053 )
8054 );
8055 assert_eq!(
8056 unsafe { &(*(::std::ptr::null::<uv_getnameinfo_s>())).type_ as *const _ as usize },
8057 8usize,
8058 concat!(
8059 "Offset of field: ",
8060 stringify!(uv_getnameinfo_s),
8061 "::",
8062 stringify!(type_)
8063 )
8064 );
8065 assert_eq!(
8066 unsafe { &(*(::std::ptr::null::<uv_getnameinfo_s>())).reserved as *const _ as usize },
8067 16usize,
8068 concat!(
8069 "Offset of field: ",
8070 stringify!(uv_getnameinfo_s),
8071 "::",
8072 stringify!(reserved)
8073 )
8074 );
8075 assert_eq!(
8076 unsafe { &(*(::std::ptr::null::<uv_getnameinfo_s>())).loop_ as *const _ as usize },
8077 64usize,
8078 concat!(
8079 "Offset of field: ",
8080 stringify!(uv_getnameinfo_s),
8081 "::",
8082 stringify!(loop_)
8083 )
8084 );
8085 assert_eq!(
8086 unsafe { &(*(::std::ptr::null::<uv_getnameinfo_s>())).work_req as *const _ as usize },
8087 72usize,
8088 concat!(
8089 "Offset of field: ",
8090 stringify!(uv_getnameinfo_s),
8091 "::",
8092 stringify!(work_req)
8093 )
8094 );
8095 assert_eq!(
8096 unsafe { &(*(::std::ptr::null::<uv_getnameinfo_s>())).getnameinfo_cb as *const _ as usize },
8097 112usize,
8098 concat!(
8099 "Offset of field: ",
8100 stringify!(uv_getnameinfo_s),
8101 "::",
8102 stringify!(getnameinfo_cb)
8103 )
8104 );
8105 assert_eq!(
8106 unsafe { &(*(::std::ptr::null::<uv_getnameinfo_s>())).storage as *const _ as usize },
8107 120usize,
8108 concat!(
8109 "Offset of field: ",
8110 stringify!(uv_getnameinfo_s),
8111 "::",
8112 stringify!(storage)
8113 )
8114 );
8115 assert_eq!(
8116 unsafe { &(*(::std::ptr::null::<uv_getnameinfo_s>())).flags as *const _ as usize },
8117 248usize,
8118 concat!(
8119 "Offset of field: ",
8120 stringify!(uv_getnameinfo_s),
8121 "::",
8122 stringify!(flags)
8123 )
8124 );
8125 assert_eq!(
8126 unsafe { &(*(::std::ptr::null::<uv_getnameinfo_s>())).host as *const _ as usize },
8127 252usize,
8128 concat!(
8129 "Offset of field: ",
8130 stringify!(uv_getnameinfo_s),
8131 "::",
8132 stringify!(host)
8133 )
8134 );
8135 assert_eq!(
8136 unsafe { &(*(::std::ptr::null::<uv_getnameinfo_s>())).service as *const _ as usize },
8137 1277usize,
8138 concat!(
8139 "Offset of field: ",
8140 stringify!(uv_getnameinfo_s),
8141 "::",
8142 stringify!(service)
8143 )
8144 );
8145 assert_eq!(
8146 unsafe { &(*(::std::ptr::null::<uv_getnameinfo_s>())).retcode as *const _ as usize },
8147 1312usize,
8148 concat!(
8149 "Offset of field: ",
8150 stringify!(uv_getnameinfo_s),
8151 "::",
8152 stringify!(retcode)
8153 )
8154 );
8155}
8156impl Default for uv_getnameinfo_s {
8157 fn default() -> Self {
8158 unsafe { ::std::mem::zeroed() }
8159 }
8160}
8161extern "C" {
8162 pub fn uv_getnameinfo(
8163 loop_: *mut uv_loop_t,
8164 req: *mut uv_getnameinfo_t,
8165 getnameinfo_cb: uv_getnameinfo_cb,
8166 addr: *const sockaddr,
8167 flags: ::std::os::raw::c_int,
8168 ) -> ::std::os::raw::c_int;
8169}
8170impl uv_stdio_flags {
8171 pub const UV_OVERLAPPED_PIPE: uv_stdio_flags = uv_stdio_flags::UV_NONBLOCK_PIPE;
8172}
8173#[repr(u32)]
8174#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
8175pub enum uv_stdio_flags {
8176 UV_IGNORE = 0,
8177 UV_CREATE_PIPE = 1,
8178 UV_INHERIT_FD = 2,
8179 UV_INHERIT_STREAM = 4,
8180 UV_READABLE_PIPE = 16,
8181 UV_WRITABLE_PIPE = 32,
8182 UV_NONBLOCK_PIPE = 64,
8183}
8184#[repr(C)]
8185#[derive(Copy, Clone)]
8186pub struct uv_stdio_container_s {
8187 pub flags: uv_stdio_flags,
8188 pub data: uv_stdio_container_s__bindgen_ty_1,
8189}
8190#[repr(C)]
8191#[derive(Copy, Clone)]
8192pub union uv_stdio_container_s__bindgen_ty_1 {
8193 pub stream: *mut uv_stream_t,
8194 pub fd: ::std::os::raw::c_int,
8195 _bindgen_union_align: u64,
8196}
8197#[test]
8198fn bindgen_test_layout_uv_stdio_container_s__bindgen_ty_1() {
8199 assert_eq!(
8200 ::std::mem::size_of::<uv_stdio_container_s__bindgen_ty_1>(),
8201 8usize,
8202 concat!("Size of: ", stringify!(uv_stdio_container_s__bindgen_ty_1))
8203 );
8204 assert_eq!(
8205 ::std::mem::align_of::<uv_stdio_container_s__bindgen_ty_1>(),
8206 8usize,
8207 concat!(
8208 "Alignment of ",
8209 stringify!(uv_stdio_container_s__bindgen_ty_1)
8210 )
8211 );
8212 assert_eq!(
8213 unsafe {
8214 &(*(::std::ptr::null::<uv_stdio_container_s__bindgen_ty_1>())).stream as *const _
8215 as usize
8216 },
8217 0usize,
8218 concat!(
8219 "Offset of field: ",
8220 stringify!(uv_stdio_container_s__bindgen_ty_1),
8221 "::",
8222 stringify!(stream)
8223 )
8224 );
8225 assert_eq!(
8226 unsafe {
8227 &(*(::std::ptr::null::<uv_stdio_container_s__bindgen_ty_1>())).fd as *const _ as usize
8228 },
8229 0usize,
8230 concat!(
8231 "Offset of field: ",
8232 stringify!(uv_stdio_container_s__bindgen_ty_1),
8233 "::",
8234 stringify!(fd)
8235 )
8236 );
8237}
8238impl Default for uv_stdio_container_s__bindgen_ty_1 {
8239 fn default() -> Self {
8240 unsafe { ::std::mem::zeroed() }
8241 }
8242}
8243#[test]
8244fn bindgen_test_layout_uv_stdio_container_s() {
8245 assert_eq!(
8246 ::std::mem::size_of::<uv_stdio_container_s>(),
8247 16usize,
8248 concat!("Size of: ", stringify!(uv_stdio_container_s))
8249 );
8250 assert_eq!(
8251 ::std::mem::align_of::<uv_stdio_container_s>(),
8252 8usize,
8253 concat!("Alignment of ", stringify!(uv_stdio_container_s))
8254 );
8255 assert_eq!(
8256 unsafe { &(*(::std::ptr::null::<uv_stdio_container_s>())).flags as *const _ as usize },
8257 0usize,
8258 concat!(
8259 "Offset of field: ",
8260 stringify!(uv_stdio_container_s),
8261 "::",
8262 stringify!(flags)
8263 )
8264 );
8265 assert_eq!(
8266 unsafe { &(*(::std::ptr::null::<uv_stdio_container_s>())).data as *const _ as usize },
8267 8usize,
8268 concat!(
8269 "Offset of field: ",
8270 stringify!(uv_stdio_container_s),
8271 "::",
8272 stringify!(data)
8273 )
8274 );
8275}
8276impl Default for uv_stdio_container_s {
8277 fn default() -> Self {
8278 unsafe { ::std::mem::zeroed() }
8279 }
8280}
8281pub type uv_stdio_container_t = uv_stdio_container_s;
8282#[repr(C)]
8283#[derive(Debug, Copy, Clone)]
8284pub struct uv_process_options_s {
8285 pub exit_cb: uv_exit_cb,
8286 pub file: *const ::std::os::raw::c_char,
8287 pub args: *mut *mut ::std::os::raw::c_char,
8288 pub env: *mut *mut ::std::os::raw::c_char,
8289 pub cwd: *const ::std::os::raw::c_char,
8290 pub flags: ::std::os::raw::c_uint,
8291 pub stdio_count: ::std::os::raw::c_int,
8292 pub stdio: *mut uv_stdio_container_t,
8293 pub uid: uv_uid_t,
8294 pub gid: uv_gid_t,
8295}
8296#[test]
8297fn bindgen_test_layout_uv_process_options_s() {
8298 assert_eq!(
8299 ::std::mem::size_of::<uv_process_options_s>(),
8300 64usize,
8301 concat!("Size of: ", stringify!(uv_process_options_s))
8302 );
8303 assert_eq!(
8304 ::std::mem::align_of::<uv_process_options_s>(),
8305 8usize,
8306 concat!("Alignment of ", stringify!(uv_process_options_s))
8307 );
8308 assert_eq!(
8309 unsafe { &(*(::std::ptr::null::<uv_process_options_s>())).exit_cb as *const _ as usize },
8310 0usize,
8311 concat!(
8312 "Offset of field: ",
8313 stringify!(uv_process_options_s),
8314 "::",
8315 stringify!(exit_cb)
8316 )
8317 );
8318 assert_eq!(
8319 unsafe { &(*(::std::ptr::null::<uv_process_options_s>())).file as *const _ as usize },
8320 8usize,
8321 concat!(
8322 "Offset of field: ",
8323 stringify!(uv_process_options_s),
8324 "::",
8325 stringify!(file)
8326 )
8327 );
8328 assert_eq!(
8329 unsafe { &(*(::std::ptr::null::<uv_process_options_s>())).args as *const _ as usize },
8330 16usize,
8331 concat!(
8332 "Offset of field: ",
8333 stringify!(uv_process_options_s),
8334 "::",
8335 stringify!(args)
8336 )
8337 );
8338 assert_eq!(
8339 unsafe { &(*(::std::ptr::null::<uv_process_options_s>())).env as *const _ as usize },
8340 24usize,
8341 concat!(
8342 "Offset of field: ",
8343 stringify!(uv_process_options_s),
8344 "::",
8345 stringify!(env)
8346 )
8347 );
8348 assert_eq!(
8349 unsafe { &(*(::std::ptr::null::<uv_process_options_s>())).cwd as *const _ as usize },
8350 32usize,
8351 concat!(
8352 "Offset of field: ",
8353 stringify!(uv_process_options_s),
8354 "::",
8355 stringify!(cwd)
8356 )
8357 );
8358 assert_eq!(
8359 unsafe { &(*(::std::ptr::null::<uv_process_options_s>())).flags as *const _ as usize },
8360 40usize,
8361 concat!(
8362 "Offset of field: ",
8363 stringify!(uv_process_options_s),
8364 "::",
8365 stringify!(flags)
8366 )
8367 );
8368 assert_eq!(
8369 unsafe {
8370 &(*(::std::ptr::null::<uv_process_options_s>())).stdio_count as *const _ as usize
8371 },
8372 44usize,
8373 concat!(
8374 "Offset of field: ",
8375 stringify!(uv_process_options_s),
8376 "::",
8377 stringify!(stdio_count)
8378 )
8379 );
8380 assert_eq!(
8381 unsafe { &(*(::std::ptr::null::<uv_process_options_s>())).stdio as *const _ as usize },
8382 48usize,
8383 concat!(
8384 "Offset of field: ",
8385 stringify!(uv_process_options_s),
8386 "::",
8387 stringify!(stdio)
8388 )
8389 );
8390 assert_eq!(
8391 unsafe { &(*(::std::ptr::null::<uv_process_options_s>())).uid as *const _ as usize },
8392 56usize,
8393 concat!(
8394 "Offset of field: ",
8395 stringify!(uv_process_options_s),
8396 "::",
8397 stringify!(uid)
8398 )
8399 );
8400 assert_eq!(
8401 unsafe { &(*(::std::ptr::null::<uv_process_options_s>())).gid as *const _ as usize },
8402 60usize,
8403 concat!(
8404 "Offset of field: ",
8405 stringify!(uv_process_options_s),
8406 "::",
8407 stringify!(gid)
8408 )
8409 );
8410}
8411impl Default for uv_process_options_s {
8412 fn default() -> Self {
8413 unsafe { ::std::mem::zeroed() }
8414 }
8415}
8416pub type uv_process_options_t = uv_process_options_s;
8417#[repr(u32)]
8418#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
8419pub enum uv_process_flags {
8420 UV_PROCESS_SETUID = 1,
8421 UV_PROCESS_SETGID = 2,
8422 UV_PROCESS_WINDOWS_VERBATIM_ARGUMENTS = 4,
8423 UV_PROCESS_DETACHED = 8,
8424 UV_PROCESS_WINDOWS_HIDE = 16,
8425 UV_PROCESS_WINDOWS_HIDE_CONSOLE = 32,
8426 UV_PROCESS_WINDOWS_HIDE_GUI = 64,
8427}
8428#[repr(C)]
8429#[derive(Copy, Clone)]
8430pub struct uv_process_s {
8431 pub data: *mut ::std::os::raw::c_void,
8432 pub loop_: *mut uv_loop_t,
8433 pub type_: uv_handle_type,
8434 pub close_cb: uv_close_cb,
8435 pub handle_queue: [*mut ::std::os::raw::c_void; 2usize],
8436 pub u: uv_process_s__bindgen_ty_1,
8437 pub next_closing: *mut uv_handle_t,
8438 pub flags: ::std::os::raw::c_uint,
8439 pub exit_cb: uv_exit_cb,
8440 pub pid: ::std::os::raw::c_int,
8441 pub queue: [*mut ::std::os::raw::c_void; 2usize],
8442 pub status: ::std::os::raw::c_int,
8443}
8444#[repr(C)]
8445#[derive(Copy, Clone)]
8446pub union uv_process_s__bindgen_ty_1 {
8447 pub fd: ::std::os::raw::c_int,
8448 pub reserved: [*mut ::std::os::raw::c_void; 4usize],
8449 _bindgen_union_align: [u64; 4usize],
8450}
8451#[test]
8452fn bindgen_test_layout_uv_process_s__bindgen_ty_1() {
8453 assert_eq!(
8454 ::std::mem::size_of::<uv_process_s__bindgen_ty_1>(),
8455 32usize,
8456 concat!("Size of: ", stringify!(uv_process_s__bindgen_ty_1))
8457 );
8458 assert_eq!(
8459 ::std::mem::align_of::<uv_process_s__bindgen_ty_1>(),
8460 8usize,
8461 concat!("Alignment of ", stringify!(uv_process_s__bindgen_ty_1))
8462 );
8463 assert_eq!(
8464 unsafe { &(*(::std::ptr::null::<uv_process_s__bindgen_ty_1>())).fd as *const _ as usize },
8465 0usize,
8466 concat!(
8467 "Offset of field: ",
8468 stringify!(uv_process_s__bindgen_ty_1),
8469 "::",
8470 stringify!(fd)
8471 )
8472 );
8473 assert_eq!(
8474 unsafe {
8475 &(*(::std::ptr::null::<uv_process_s__bindgen_ty_1>())).reserved as *const _ as usize
8476 },
8477 0usize,
8478 concat!(
8479 "Offset of field: ",
8480 stringify!(uv_process_s__bindgen_ty_1),
8481 "::",
8482 stringify!(reserved)
8483 )
8484 );
8485}
8486impl Default for uv_process_s__bindgen_ty_1 {
8487 fn default() -> Self {
8488 unsafe { ::std::mem::zeroed() }
8489 }
8490}
8491#[test]
8492fn bindgen_test_layout_uv_process_s() {
8493 assert_eq!(
8494 ::std::mem::size_of::<uv_process_s>(),
8495 136usize,
8496 concat!("Size of: ", stringify!(uv_process_s))
8497 );
8498 assert_eq!(
8499 ::std::mem::align_of::<uv_process_s>(),
8500 8usize,
8501 concat!("Alignment of ", stringify!(uv_process_s))
8502 );
8503 assert_eq!(
8504 unsafe { &(*(::std::ptr::null::<uv_process_s>())).data as *const _ as usize },
8505 0usize,
8506 concat!(
8507 "Offset of field: ",
8508 stringify!(uv_process_s),
8509 "::",
8510 stringify!(data)
8511 )
8512 );
8513 assert_eq!(
8514 unsafe { &(*(::std::ptr::null::<uv_process_s>())).loop_ as *const _ as usize },
8515 8usize,
8516 concat!(
8517 "Offset of field: ",
8518 stringify!(uv_process_s),
8519 "::",
8520 stringify!(loop_)
8521 )
8522 );
8523 assert_eq!(
8524 unsafe { &(*(::std::ptr::null::<uv_process_s>())).type_ as *const _ as usize },
8525 16usize,
8526 concat!(
8527 "Offset of field: ",
8528 stringify!(uv_process_s),
8529 "::",
8530 stringify!(type_)
8531 )
8532 );
8533 assert_eq!(
8534 unsafe { &(*(::std::ptr::null::<uv_process_s>())).close_cb as *const _ as usize },
8535 24usize,
8536 concat!(
8537 "Offset of field: ",
8538 stringify!(uv_process_s),
8539 "::",
8540 stringify!(close_cb)
8541 )
8542 );
8543 assert_eq!(
8544 unsafe { &(*(::std::ptr::null::<uv_process_s>())).handle_queue as *const _ as usize },
8545 32usize,
8546 concat!(
8547 "Offset of field: ",
8548 stringify!(uv_process_s),
8549 "::",
8550 stringify!(handle_queue)
8551 )
8552 );
8553 assert_eq!(
8554 unsafe { &(*(::std::ptr::null::<uv_process_s>())).u as *const _ as usize },
8555 48usize,
8556 concat!(
8557 "Offset of field: ",
8558 stringify!(uv_process_s),
8559 "::",
8560 stringify!(u)
8561 )
8562 );
8563 assert_eq!(
8564 unsafe { &(*(::std::ptr::null::<uv_process_s>())).next_closing as *const _ as usize },
8565 80usize,
8566 concat!(
8567 "Offset of field: ",
8568 stringify!(uv_process_s),
8569 "::",
8570 stringify!(next_closing)
8571 )
8572 );
8573 assert_eq!(
8574 unsafe { &(*(::std::ptr::null::<uv_process_s>())).flags as *const _ as usize },
8575 88usize,
8576 concat!(
8577 "Offset of field: ",
8578 stringify!(uv_process_s),
8579 "::",
8580 stringify!(flags)
8581 )
8582 );
8583 assert_eq!(
8584 unsafe { &(*(::std::ptr::null::<uv_process_s>())).exit_cb as *const _ as usize },
8585 96usize,
8586 concat!(
8587 "Offset of field: ",
8588 stringify!(uv_process_s),
8589 "::",
8590 stringify!(exit_cb)
8591 )
8592 );
8593 assert_eq!(
8594 unsafe { &(*(::std::ptr::null::<uv_process_s>())).pid as *const _ as usize },
8595 104usize,
8596 concat!(
8597 "Offset of field: ",
8598 stringify!(uv_process_s),
8599 "::",
8600 stringify!(pid)
8601 )
8602 );
8603 assert_eq!(
8604 unsafe { &(*(::std::ptr::null::<uv_process_s>())).queue as *const _ as usize },
8605 112usize,
8606 concat!(
8607 "Offset of field: ",
8608 stringify!(uv_process_s),
8609 "::",
8610 stringify!(queue)
8611 )
8612 );
8613 assert_eq!(
8614 unsafe { &(*(::std::ptr::null::<uv_process_s>())).status as *const _ as usize },
8615 128usize,
8616 concat!(
8617 "Offset of field: ",
8618 stringify!(uv_process_s),
8619 "::",
8620 stringify!(status)
8621 )
8622 );
8623}
8624impl Default for uv_process_s {
8625 fn default() -> Self {
8626 unsafe { ::std::mem::zeroed() }
8627 }
8628}
8629extern "C" {
8630 pub fn uv_spawn(
8631 loop_: *mut uv_loop_t,
8632 handle: *mut uv_process_t,
8633 options: *const uv_process_options_t,
8634 ) -> ::std::os::raw::c_int;
8635}
8636extern "C" {
8637 pub fn uv_process_kill(
8638 arg1: *mut uv_process_t,
8639 signum: ::std::os::raw::c_int,
8640 ) -> ::std::os::raw::c_int;
8641}
8642extern "C" {
8643 pub fn uv_kill(
8644 pid: ::std::os::raw::c_int,
8645 signum: ::std::os::raw::c_int,
8646 ) -> ::std::os::raw::c_int;
8647}
8648extern "C" {
8649 pub fn uv_process_get_pid(arg1: *const uv_process_t) -> uv_pid_t;
8650}
8651#[repr(C)]
8652#[derive(Debug, Copy, Clone)]
8653pub struct uv_work_s {
8654 pub data: *mut ::std::os::raw::c_void,
8655 pub type_: uv_req_type,
8656 pub reserved: [*mut ::std::os::raw::c_void; 6usize],
8657 pub loop_: *mut uv_loop_t,
8658 pub work_cb: uv_work_cb,
8659 pub after_work_cb: uv_after_work_cb,
8660 pub work_req: uv__work,
8661}
8662#[test]
8663fn bindgen_test_layout_uv_work_s() {
8664 assert_eq!(
8665 ::std::mem::size_of::<uv_work_s>(),
8666 128usize,
8667 concat!("Size of: ", stringify!(uv_work_s))
8668 );
8669 assert_eq!(
8670 ::std::mem::align_of::<uv_work_s>(),
8671 8usize,
8672 concat!("Alignment of ", stringify!(uv_work_s))
8673 );
8674 assert_eq!(
8675 unsafe { &(*(::std::ptr::null::<uv_work_s>())).data as *const _ as usize },
8676 0usize,
8677 concat!(
8678 "Offset of field: ",
8679 stringify!(uv_work_s),
8680 "::",
8681 stringify!(data)
8682 )
8683 );
8684 assert_eq!(
8685 unsafe { &(*(::std::ptr::null::<uv_work_s>())).type_ as *const _ as usize },
8686 8usize,
8687 concat!(
8688 "Offset of field: ",
8689 stringify!(uv_work_s),
8690 "::",
8691 stringify!(type_)
8692 )
8693 );
8694 assert_eq!(
8695 unsafe { &(*(::std::ptr::null::<uv_work_s>())).reserved as *const _ as usize },
8696 16usize,
8697 concat!(
8698 "Offset of field: ",
8699 stringify!(uv_work_s),
8700 "::",
8701 stringify!(reserved)
8702 )
8703 );
8704 assert_eq!(
8705 unsafe { &(*(::std::ptr::null::<uv_work_s>())).loop_ as *const _ as usize },
8706 64usize,
8707 concat!(
8708 "Offset of field: ",
8709 stringify!(uv_work_s),
8710 "::",
8711 stringify!(loop_)
8712 )
8713 );
8714 assert_eq!(
8715 unsafe { &(*(::std::ptr::null::<uv_work_s>())).work_cb as *const _ as usize },
8716 72usize,
8717 concat!(
8718 "Offset of field: ",
8719 stringify!(uv_work_s),
8720 "::",
8721 stringify!(work_cb)
8722 )
8723 );
8724 assert_eq!(
8725 unsafe { &(*(::std::ptr::null::<uv_work_s>())).after_work_cb as *const _ as usize },
8726 80usize,
8727 concat!(
8728 "Offset of field: ",
8729 stringify!(uv_work_s),
8730 "::",
8731 stringify!(after_work_cb)
8732 )
8733 );
8734 assert_eq!(
8735 unsafe { &(*(::std::ptr::null::<uv_work_s>())).work_req as *const _ as usize },
8736 88usize,
8737 concat!(
8738 "Offset of field: ",
8739 stringify!(uv_work_s),
8740 "::",
8741 stringify!(work_req)
8742 )
8743 );
8744}
8745impl Default for uv_work_s {
8746 fn default() -> Self {
8747 unsafe { ::std::mem::zeroed() }
8748 }
8749}
8750extern "C" {
8751 pub fn uv_queue_work(
8752 loop_: *mut uv_loop_t,
8753 req: *mut uv_work_t,
8754 work_cb: uv_work_cb,
8755 after_work_cb: uv_after_work_cb,
8756 ) -> ::std::os::raw::c_int;
8757}
8758extern "C" {
8759 pub fn uv_cancel(req: *mut uv_req_t) -> ::std::os::raw::c_int;
8760}
8761#[repr(C)]
8762#[derive(Debug, Default, Copy, Clone)]
8763pub struct uv_cpu_times_s {
8764 pub user: u64,
8765 pub nice: u64,
8766 pub sys: u64,
8767 pub idle: u64,
8768 pub irq: u64,
8769}
8770#[test]
8771fn bindgen_test_layout_uv_cpu_times_s() {
8772 assert_eq!(
8773 ::std::mem::size_of::<uv_cpu_times_s>(),
8774 40usize,
8775 concat!("Size of: ", stringify!(uv_cpu_times_s))
8776 );
8777 assert_eq!(
8778 ::std::mem::align_of::<uv_cpu_times_s>(),
8779 8usize,
8780 concat!("Alignment of ", stringify!(uv_cpu_times_s))
8781 );
8782 assert_eq!(
8783 unsafe { &(*(::std::ptr::null::<uv_cpu_times_s>())).user as *const _ as usize },
8784 0usize,
8785 concat!(
8786 "Offset of field: ",
8787 stringify!(uv_cpu_times_s),
8788 "::",
8789 stringify!(user)
8790 )
8791 );
8792 assert_eq!(
8793 unsafe { &(*(::std::ptr::null::<uv_cpu_times_s>())).nice as *const _ as usize },
8794 8usize,
8795 concat!(
8796 "Offset of field: ",
8797 stringify!(uv_cpu_times_s),
8798 "::",
8799 stringify!(nice)
8800 )
8801 );
8802 assert_eq!(
8803 unsafe { &(*(::std::ptr::null::<uv_cpu_times_s>())).sys as *const _ as usize },
8804 16usize,
8805 concat!(
8806 "Offset of field: ",
8807 stringify!(uv_cpu_times_s),
8808 "::",
8809 stringify!(sys)
8810 )
8811 );
8812 assert_eq!(
8813 unsafe { &(*(::std::ptr::null::<uv_cpu_times_s>())).idle as *const _ as usize },
8814 24usize,
8815 concat!(
8816 "Offset of field: ",
8817 stringify!(uv_cpu_times_s),
8818 "::",
8819 stringify!(idle)
8820 )
8821 );
8822 assert_eq!(
8823 unsafe { &(*(::std::ptr::null::<uv_cpu_times_s>())).irq as *const _ as usize },
8824 32usize,
8825 concat!(
8826 "Offset of field: ",
8827 stringify!(uv_cpu_times_s),
8828 "::",
8829 stringify!(irq)
8830 )
8831 );
8832}
8833#[repr(C)]
8834#[derive(Debug, Copy, Clone)]
8835pub struct uv_cpu_info_s {
8836 pub model: *mut ::std::os::raw::c_char,
8837 pub speed: ::std::os::raw::c_int,
8838 pub cpu_times: uv_cpu_times_s,
8839}
8840#[test]
8841fn bindgen_test_layout_uv_cpu_info_s() {
8842 assert_eq!(
8843 ::std::mem::size_of::<uv_cpu_info_s>(),
8844 56usize,
8845 concat!("Size of: ", stringify!(uv_cpu_info_s))
8846 );
8847 assert_eq!(
8848 ::std::mem::align_of::<uv_cpu_info_s>(),
8849 8usize,
8850 concat!("Alignment of ", stringify!(uv_cpu_info_s))
8851 );
8852 assert_eq!(
8853 unsafe { &(*(::std::ptr::null::<uv_cpu_info_s>())).model as *const _ as usize },
8854 0usize,
8855 concat!(
8856 "Offset of field: ",
8857 stringify!(uv_cpu_info_s),
8858 "::",
8859 stringify!(model)
8860 )
8861 );
8862 assert_eq!(
8863 unsafe { &(*(::std::ptr::null::<uv_cpu_info_s>())).speed as *const _ as usize },
8864 8usize,
8865 concat!(
8866 "Offset of field: ",
8867 stringify!(uv_cpu_info_s),
8868 "::",
8869 stringify!(speed)
8870 )
8871 );
8872 assert_eq!(
8873 unsafe { &(*(::std::ptr::null::<uv_cpu_info_s>())).cpu_times as *const _ as usize },
8874 16usize,
8875 concat!(
8876 "Offset of field: ",
8877 stringify!(uv_cpu_info_s),
8878 "::",
8879 stringify!(cpu_times)
8880 )
8881 );
8882}
8883impl Default for uv_cpu_info_s {
8884 fn default() -> Self {
8885 unsafe { ::std::mem::zeroed() }
8886 }
8887}
8888#[repr(C)]
8889#[derive(Copy, Clone)]
8890pub struct uv_interface_address_s {
8891 pub name: *mut ::std::os::raw::c_char,
8892 pub phys_addr: [::std::os::raw::c_char; 6usize],
8893 pub is_internal: ::std::os::raw::c_int,
8894 pub address: uv_interface_address_s__bindgen_ty_1,
8895 pub netmask: uv_interface_address_s__bindgen_ty_2,
8896}
8897#[repr(C)]
8898#[derive(Copy, Clone)]
8899pub union uv_interface_address_s__bindgen_ty_1 {
8900 pub address4: sockaddr_in,
8901 pub address6: sockaddr_in6,
8902 _bindgen_union_align: [u32; 7usize],
8903}
8904#[test]
8905fn bindgen_test_layout_uv_interface_address_s__bindgen_ty_1() {
8906 assert_eq!(
8907 ::std::mem::size_of::<uv_interface_address_s__bindgen_ty_1>(),
8908 28usize,
8909 concat!(
8910 "Size of: ",
8911 stringify!(uv_interface_address_s__bindgen_ty_1)
8912 )
8913 );
8914 assert_eq!(
8915 ::std::mem::align_of::<uv_interface_address_s__bindgen_ty_1>(),
8916 4usize,
8917 concat!(
8918 "Alignment of ",
8919 stringify!(uv_interface_address_s__bindgen_ty_1)
8920 )
8921 );
8922 assert_eq!(
8923 unsafe {
8924 &(*(::std::ptr::null::<uv_interface_address_s__bindgen_ty_1>())).address4 as *const _
8925 as usize
8926 },
8927 0usize,
8928 concat!(
8929 "Offset of field: ",
8930 stringify!(uv_interface_address_s__bindgen_ty_1),
8931 "::",
8932 stringify!(address4)
8933 )
8934 );
8935 assert_eq!(
8936 unsafe {
8937 &(*(::std::ptr::null::<uv_interface_address_s__bindgen_ty_1>())).address6 as *const _
8938 as usize
8939 },
8940 0usize,
8941 concat!(
8942 "Offset of field: ",
8943 stringify!(uv_interface_address_s__bindgen_ty_1),
8944 "::",
8945 stringify!(address6)
8946 )
8947 );
8948}
8949impl Default for uv_interface_address_s__bindgen_ty_1 {
8950 fn default() -> Self {
8951 unsafe { ::std::mem::zeroed() }
8952 }
8953}
8954#[repr(C)]
8955#[derive(Copy, Clone)]
8956pub union uv_interface_address_s__bindgen_ty_2 {
8957 pub netmask4: sockaddr_in,
8958 pub netmask6: sockaddr_in6,
8959 _bindgen_union_align: [u32; 7usize],
8960}
8961#[test]
8962fn bindgen_test_layout_uv_interface_address_s__bindgen_ty_2() {
8963 assert_eq!(
8964 ::std::mem::size_of::<uv_interface_address_s__bindgen_ty_2>(),
8965 28usize,
8966 concat!(
8967 "Size of: ",
8968 stringify!(uv_interface_address_s__bindgen_ty_2)
8969 )
8970 );
8971 assert_eq!(
8972 ::std::mem::align_of::<uv_interface_address_s__bindgen_ty_2>(),
8973 4usize,
8974 concat!(
8975 "Alignment of ",
8976 stringify!(uv_interface_address_s__bindgen_ty_2)
8977 )
8978 );
8979 assert_eq!(
8980 unsafe {
8981 &(*(::std::ptr::null::<uv_interface_address_s__bindgen_ty_2>())).netmask4 as *const _
8982 as usize
8983 },
8984 0usize,
8985 concat!(
8986 "Offset of field: ",
8987 stringify!(uv_interface_address_s__bindgen_ty_2),
8988 "::",
8989 stringify!(netmask4)
8990 )
8991 );
8992 assert_eq!(
8993 unsafe {
8994 &(*(::std::ptr::null::<uv_interface_address_s__bindgen_ty_2>())).netmask6 as *const _
8995 as usize
8996 },
8997 0usize,
8998 concat!(
8999 "Offset of field: ",
9000 stringify!(uv_interface_address_s__bindgen_ty_2),
9001 "::",
9002 stringify!(netmask6)
9003 )
9004 );
9005}
9006impl Default for uv_interface_address_s__bindgen_ty_2 {
9007 fn default() -> Self {
9008 unsafe { ::std::mem::zeroed() }
9009 }
9010}
9011#[test]
9012fn bindgen_test_layout_uv_interface_address_s() {
9013 assert_eq!(
9014 ::std::mem::size_of::<uv_interface_address_s>(),
9015 80usize,
9016 concat!("Size of: ", stringify!(uv_interface_address_s))
9017 );
9018 assert_eq!(
9019 ::std::mem::align_of::<uv_interface_address_s>(),
9020 8usize,
9021 concat!("Alignment of ", stringify!(uv_interface_address_s))
9022 );
9023 assert_eq!(
9024 unsafe { &(*(::std::ptr::null::<uv_interface_address_s>())).name as *const _ as usize },
9025 0usize,
9026 concat!(
9027 "Offset of field: ",
9028 stringify!(uv_interface_address_s),
9029 "::",
9030 stringify!(name)
9031 )
9032 );
9033 assert_eq!(
9034 unsafe {
9035 &(*(::std::ptr::null::<uv_interface_address_s>())).phys_addr as *const _ as usize
9036 },
9037 8usize,
9038 concat!(
9039 "Offset of field: ",
9040 stringify!(uv_interface_address_s),
9041 "::",
9042 stringify!(phys_addr)
9043 )
9044 );
9045 assert_eq!(
9046 unsafe {
9047 &(*(::std::ptr::null::<uv_interface_address_s>())).is_internal as *const _ as usize
9048 },
9049 16usize,
9050 concat!(
9051 "Offset of field: ",
9052 stringify!(uv_interface_address_s),
9053 "::",
9054 stringify!(is_internal)
9055 )
9056 );
9057 assert_eq!(
9058 unsafe { &(*(::std::ptr::null::<uv_interface_address_s>())).address as *const _ as usize },
9059 20usize,
9060 concat!(
9061 "Offset of field: ",
9062 stringify!(uv_interface_address_s),
9063 "::",
9064 stringify!(address)
9065 )
9066 );
9067 assert_eq!(
9068 unsafe { &(*(::std::ptr::null::<uv_interface_address_s>())).netmask as *const _ as usize },
9069 48usize,
9070 concat!(
9071 "Offset of field: ",
9072 stringify!(uv_interface_address_s),
9073 "::",
9074 stringify!(netmask)
9075 )
9076 );
9077}
9078impl Default for uv_interface_address_s {
9079 fn default() -> Self {
9080 unsafe { ::std::mem::zeroed() }
9081 }
9082}
9083#[repr(C)]
9084#[derive(Debug, Copy, Clone)]
9085pub struct uv_passwd_s {
9086 pub username: *mut ::std::os::raw::c_char,
9087 pub uid: ::std::os::raw::c_long,
9088 pub gid: ::std::os::raw::c_long,
9089 pub shell: *mut ::std::os::raw::c_char,
9090 pub homedir: *mut ::std::os::raw::c_char,
9091}
9092#[test]
9093fn bindgen_test_layout_uv_passwd_s() {
9094 assert_eq!(
9095 ::std::mem::size_of::<uv_passwd_s>(),
9096 40usize,
9097 concat!("Size of: ", stringify!(uv_passwd_s))
9098 );
9099 assert_eq!(
9100 ::std::mem::align_of::<uv_passwd_s>(),
9101 8usize,
9102 concat!("Alignment of ", stringify!(uv_passwd_s))
9103 );
9104 assert_eq!(
9105 unsafe { &(*(::std::ptr::null::<uv_passwd_s>())).username as *const _ as usize },
9106 0usize,
9107 concat!(
9108 "Offset of field: ",
9109 stringify!(uv_passwd_s),
9110 "::",
9111 stringify!(username)
9112 )
9113 );
9114 assert_eq!(
9115 unsafe { &(*(::std::ptr::null::<uv_passwd_s>())).uid as *const _ as usize },
9116 8usize,
9117 concat!(
9118 "Offset of field: ",
9119 stringify!(uv_passwd_s),
9120 "::",
9121 stringify!(uid)
9122 )
9123 );
9124 assert_eq!(
9125 unsafe { &(*(::std::ptr::null::<uv_passwd_s>())).gid as *const _ as usize },
9126 16usize,
9127 concat!(
9128 "Offset of field: ",
9129 stringify!(uv_passwd_s),
9130 "::",
9131 stringify!(gid)
9132 )
9133 );
9134 assert_eq!(
9135 unsafe { &(*(::std::ptr::null::<uv_passwd_s>())).shell as *const _ as usize },
9136 24usize,
9137 concat!(
9138 "Offset of field: ",
9139 stringify!(uv_passwd_s),
9140 "::",
9141 stringify!(shell)
9142 )
9143 );
9144 assert_eq!(
9145 unsafe { &(*(::std::ptr::null::<uv_passwd_s>())).homedir as *const _ as usize },
9146 32usize,
9147 concat!(
9148 "Offset of field: ",
9149 stringify!(uv_passwd_s),
9150 "::",
9151 stringify!(homedir)
9152 )
9153 );
9154}
9155impl Default for uv_passwd_s {
9156 fn default() -> Self {
9157 unsafe { ::std::mem::zeroed() }
9158 }
9159}
9160#[repr(C)]
9161#[derive(Copy, Clone)]
9162pub struct uv_utsname_s {
9163 pub sysname: [::std::os::raw::c_char; 256usize],
9164 pub release: [::std::os::raw::c_char; 256usize],
9165 pub version: [::std::os::raw::c_char; 256usize],
9166 pub machine: [::std::os::raw::c_char; 256usize],
9167}
9168#[test]
9169fn bindgen_test_layout_uv_utsname_s() {
9170 assert_eq!(
9171 ::std::mem::size_of::<uv_utsname_s>(),
9172 1024usize,
9173 concat!("Size of: ", stringify!(uv_utsname_s))
9174 );
9175 assert_eq!(
9176 ::std::mem::align_of::<uv_utsname_s>(),
9177 1usize,
9178 concat!("Alignment of ", stringify!(uv_utsname_s))
9179 );
9180 assert_eq!(
9181 unsafe { &(*(::std::ptr::null::<uv_utsname_s>())).sysname as *const _ as usize },
9182 0usize,
9183 concat!(
9184 "Offset of field: ",
9185 stringify!(uv_utsname_s),
9186 "::",
9187 stringify!(sysname)
9188 )
9189 );
9190 assert_eq!(
9191 unsafe { &(*(::std::ptr::null::<uv_utsname_s>())).release as *const _ as usize },
9192 256usize,
9193 concat!(
9194 "Offset of field: ",
9195 stringify!(uv_utsname_s),
9196 "::",
9197 stringify!(release)
9198 )
9199 );
9200 assert_eq!(
9201 unsafe { &(*(::std::ptr::null::<uv_utsname_s>())).version as *const _ as usize },
9202 512usize,
9203 concat!(
9204 "Offset of field: ",
9205 stringify!(uv_utsname_s),
9206 "::",
9207 stringify!(version)
9208 )
9209 );
9210 assert_eq!(
9211 unsafe { &(*(::std::ptr::null::<uv_utsname_s>())).machine as *const _ as usize },
9212 768usize,
9213 concat!(
9214 "Offset of field: ",
9215 stringify!(uv_utsname_s),
9216 "::",
9217 stringify!(machine)
9218 )
9219 );
9220}
9221impl Default for uv_utsname_s {
9222 fn default() -> Self {
9223 unsafe { ::std::mem::zeroed() }
9224 }
9225}
9226#[repr(C)]
9227#[derive(Debug, Default, Copy, Clone)]
9228pub struct uv_statfs_s {
9229 pub f_type: u64,
9230 pub f_bsize: u64,
9231 pub f_blocks: u64,
9232 pub f_bfree: u64,
9233 pub f_bavail: u64,
9234 pub f_files: u64,
9235 pub f_ffree: u64,
9236 pub f_spare: [u64; 4usize],
9237}
9238#[test]
9239fn bindgen_test_layout_uv_statfs_s() {
9240 assert_eq!(
9241 ::std::mem::size_of::<uv_statfs_s>(),
9242 88usize,
9243 concat!("Size of: ", stringify!(uv_statfs_s))
9244 );
9245 assert_eq!(
9246 ::std::mem::align_of::<uv_statfs_s>(),
9247 8usize,
9248 concat!("Alignment of ", stringify!(uv_statfs_s))
9249 );
9250 assert_eq!(
9251 unsafe { &(*(::std::ptr::null::<uv_statfs_s>())).f_type as *const _ as usize },
9252 0usize,
9253 concat!(
9254 "Offset of field: ",
9255 stringify!(uv_statfs_s),
9256 "::",
9257 stringify!(f_type)
9258 )
9259 );
9260 assert_eq!(
9261 unsafe { &(*(::std::ptr::null::<uv_statfs_s>())).f_bsize as *const _ as usize },
9262 8usize,
9263 concat!(
9264 "Offset of field: ",
9265 stringify!(uv_statfs_s),
9266 "::",
9267 stringify!(f_bsize)
9268 )
9269 );
9270 assert_eq!(
9271 unsafe { &(*(::std::ptr::null::<uv_statfs_s>())).f_blocks as *const _ as usize },
9272 16usize,
9273 concat!(
9274 "Offset of field: ",
9275 stringify!(uv_statfs_s),
9276 "::",
9277 stringify!(f_blocks)
9278 )
9279 );
9280 assert_eq!(
9281 unsafe { &(*(::std::ptr::null::<uv_statfs_s>())).f_bfree as *const _ as usize },
9282 24usize,
9283 concat!(
9284 "Offset of field: ",
9285 stringify!(uv_statfs_s),
9286 "::",
9287 stringify!(f_bfree)
9288 )
9289 );
9290 assert_eq!(
9291 unsafe { &(*(::std::ptr::null::<uv_statfs_s>())).f_bavail as *const _ as usize },
9292 32usize,
9293 concat!(
9294 "Offset of field: ",
9295 stringify!(uv_statfs_s),
9296 "::",
9297 stringify!(f_bavail)
9298 )
9299 );
9300 assert_eq!(
9301 unsafe { &(*(::std::ptr::null::<uv_statfs_s>())).f_files as *const _ as usize },
9302 40usize,
9303 concat!(
9304 "Offset of field: ",
9305 stringify!(uv_statfs_s),
9306 "::",
9307 stringify!(f_files)
9308 )
9309 );
9310 assert_eq!(
9311 unsafe { &(*(::std::ptr::null::<uv_statfs_s>())).f_ffree as *const _ as usize },
9312 48usize,
9313 concat!(
9314 "Offset of field: ",
9315 stringify!(uv_statfs_s),
9316 "::",
9317 stringify!(f_ffree)
9318 )
9319 );
9320 assert_eq!(
9321 unsafe { &(*(::std::ptr::null::<uv_statfs_s>())).f_spare as *const _ as usize },
9322 56usize,
9323 concat!(
9324 "Offset of field: ",
9325 stringify!(uv_statfs_s),
9326 "::",
9327 stringify!(f_spare)
9328 )
9329 );
9330}
9331#[repr(u32)]
9332#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
9333pub enum uv_dirent_type_t {
9334 UV_DIRENT_UNKNOWN = 0,
9335 UV_DIRENT_FILE = 1,
9336 UV_DIRENT_DIR = 2,
9337 UV_DIRENT_LINK = 3,
9338 UV_DIRENT_FIFO = 4,
9339 UV_DIRENT_SOCKET = 5,
9340 UV_DIRENT_CHAR = 6,
9341 UV_DIRENT_BLOCK = 7,
9342}
9343#[repr(C)]
9344#[derive(Debug, Copy, Clone)]
9345pub struct uv_dirent_s {
9346 pub name: *const ::std::os::raw::c_char,
9347 pub type_: uv_dirent_type_t,
9348}
9349#[test]
9350fn bindgen_test_layout_uv_dirent_s() {
9351 assert_eq!(
9352 ::std::mem::size_of::<uv_dirent_s>(),
9353 16usize,
9354 concat!("Size of: ", stringify!(uv_dirent_s))
9355 );
9356 assert_eq!(
9357 ::std::mem::align_of::<uv_dirent_s>(),
9358 8usize,
9359 concat!("Alignment of ", stringify!(uv_dirent_s))
9360 );
9361 assert_eq!(
9362 unsafe { &(*(::std::ptr::null::<uv_dirent_s>())).name as *const _ as usize },
9363 0usize,
9364 concat!(
9365 "Offset of field: ",
9366 stringify!(uv_dirent_s),
9367 "::",
9368 stringify!(name)
9369 )
9370 );
9371 assert_eq!(
9372 unsafe { &(*(::std::ptr::null::<uv_dirent_s>())).type_ as *const _ as usize },
9373 8usize,
9374 concat!(
9375 "Offset of field: ",
9376 stringify!(uv_dirent_s),
9377 "::",
9378 stringify!(type_)
9379 )
9380 );
9381}
9382impl Default for uv_dirent_s {
9383 fn default() -> Self {
9384 unsafe { ::std::mem::zeroed() }
9385 }
9386}
9387extern "C" {
9388 pub fn uv_setup_args(
9389 argc: ::std::os::raw::c_int,
9390 argv: *mut *mut ::std::os::raw::c_char,
9391 ) -> *mut *mut ::std::os::raw::c_char;
9392}
9393extern "C" {
9394 pub fn uv_get_process_title(
9395 buffer: *mut ::std::os::raw::c_char,
9396 size: size_t,
9397 ) -> ::std::os::raw::c_int;
9398}
9399extern "C" {
9400 pub fn uv_set_process_title(title: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int;
9401}
9402extern "C" {
9403 pub fn uv_resident_set_memory(rss: *mut size_t) -> ::std::os::raw::c_int;
9404}
9405extern "C" {
9406 pub fn uv_uptime(uptime: *mut f64) -> ::std::os::raw::c_int;
9407}
9408extern "C" {
9409 pub fn uv_get_osfhandle(fd: ::std::os::raw::c_int) -> uv_os_fd_t;
9410}
9411extern "C" {
9412 pub fn uv_open_osfhandle(os_fd: uv_os_fd_t) -> ::std::os::raw::c_int;
9413}
9414#[repr(C)]
9415#[derive(Debug, Default, Copy, Clone)]
9416pub struct uv_timeval_t {
9417 pub tv_sec: ::std::os::raw::c_long,
9418 pub tv_usec: ::std::os::raw::c_long,
9419}
9420#[test]
9421fn bindgen_test_layout_uv_timeval_t() {
9422 assert_eq!(
9423 ::std::mem::size_of::<uv_timeval_t>(),
9424 16usize,
9425 concat!("Size of: ", stringify!(uv_timeval_t))
9426 );
9427 assert_eq!(
9428 ::std::mem::align_of::<uv_timeval_t>(),
9429 8usize,
9430 concat!("Alignment of ", stringify!(uv_timeval_t))
9431 );
9432 assert_eq!(
9433 unsafe { &(*(::std::ptr::null::<uv_timeval_t>())).tv_sec as *const _ as usize },
9434 0usize,
9435 concat!(
9436 "Offset of field: ",
9437 stringify!(uv_timeval_t),
9438 "::",
9439 stringify!(tv_sec)
9440 )
9441 );
9442 assert_eq!(
9443 unsafe { &(*(::std::ptr::null::<uv_timeval_t>())).tv_usec as *const _ as usize },
9444 8usize,
9445 concat!(
9446 "Offset of field: ",
9447 stringify!(uv_timeval_t),
9448 "::",
9449 stringify!(tv_usec)
9450 )
9451 );
9452}
9453#[repr(C)]
9454#[derive(Debug, Default, Copy, Clone)]
9455pub struct uv_timeval64_t {
9456 pub tv_sec: i64,
9457 pub tv_usec: i32,
9458}
9459#[test]
9460fn bindgen_test_layout_uv_timeval64_t() {
9461 assert_eq!(
9462 ::std::mem::size_of::<uv_timeval64_t>(),
9463 16usize,
9464 concat!("Size of: ", stringify!(uv_timeval64_t))
9465 );
9466 assert_eq!(
9467 ::std::mem::align_of::<uv_timeval64_t>(),
9468 8usize,
9469 concat!("Alignment of ", stringify!(uv_timeval64_t))
9470 );
9471 assert_eq!(
9472 unsafe { &(*(::std::ptr::null::<uv_timeval64_t>())).tv_sec as *const _ as usize },
9473 0usize,
9474 concat!(
9475 "Offset of field: ",
9476 stringify!(uv_timeval64_t),
9477 "::",
9478 stringify!(tv_sec)
9479 )
9480 );
9481 assert_eq!(
9482 unsafe { &(*(::std::ptr::null::<uv_timeval64_t>())).tv_usec as *const _ as usize },
9483 8usize,
9484 concat!(
9485 "Offset of field: ",
9486 stringify!(uv_timeval64_t),
9487 "::",
9488 stringify!(tv_usec)
9489 )
9490 );
9491}
9492#[repr(C)]
9493#[derive(Debug, Default, Copy, Clone)]
9494pub struct uv_rusage_t {
9495 pub ru_utime: uv_timeval_t,
9496 pub ru_stime: uv_timeval_t,
9497 pub ru_maxrss: u64,
9498 pub ru_ixrss: u64,
9499 pub ru_idrss: u64,
9500 pub ru_isrss: u64,
9501 pub ru_minflt: u64,
9502 pub ru_majflt: u64,
9503 pub ru_nswap: u64,
9504 pub ru_inblock: u64,
9505 pub ru_oublock: u64,
9506 pub ru_msgsnd: u64,
9507 pub ru_msgrcv: u64,
9508 pub ru_nsignals: u64,
9509 pub ru_nvcsw: u64,
9510 pub ru_nivcsw: u64,
9511}
9512#[test]
9513fn bindgen_test_layout_uv_rusage_t() {
9514 assert_eq!(
9515 ::std::mem::size_of::<uv_rusage_t>(),
9516 144usize,
9517 concat!("Size of: ", stringify!(uv_rusage_t))
9518 );
9519 assert_eq!(
9520 ::std::mem::align_of::<uv_rusage_t>(),
9521 8usize,
9522 concat!("Alignment of ", stringify!(uv_rusage_t))
9523 );
9524 assert_eq!(
9525 unsafe { &(*(::std::ptr::null::<uv_rusage_t>())).ru_utime as *const _ as usize },
9526 0usize,
9527 concat!(
9528 "Offset of field: ",
9529 stringify!(uv_rusage_t),
9530 "::",
9531 stringify!(ru_utime)
9532 )
9533 );
9534 assert_eq!(
9535 unsafe { &(*(::std::ptr::null::<uv_rusage_t>())).ru_stime as *const _ as usize },
9536 16usize,
9537 concat!(
9538 "Offset of field: ",
9539 stringify!(uv_rusage_t),
9540 "::",
9541 stringify!(ru_stime)
9542 )
9543 );
9544 assert_eq!(
9545 unsafe { &(*(::std::ptr::null::<uv_rusage_t>())).ru_maxrss as *const _ as usize },
9546 32usize,
9547 concat!(
9548 "Offset of field: ",
9549 stringify!(uv_rusage_t),
9550 "::",
9551 stringify!(ru_maxrss)
9552 )
9553 );
9554 assert_eq!(
9555 unsafe { &(*(::std::ptr::null::<uv_rusage_t>())).ru_ixrss as *const _ as usize },
9556 40usize,
9557 concat!(
9558 "Offset of field: ",
9559 stringify!(uv_rusage_t),
9560 "::",
9561 stringify!(ru_ixrss)
9562 )
9563 );
9564 assert_eq!(
9565 unsafe { &(*(::std::ptr::null::<uv_rusage_t>())).ru_idrss as *const _ as usize },
9566 48usize,
9567 concat!(
9568 "Offset of field: ",
9569 stringify!(uv_rusage_t),
9570 "::",
9571 stringify!(ru_idrss)
9572 )
9573 );
9574 assert_eq!(
9575 unsafe { &(*(::std::ptr::null::<uv_rusage_t>())).ru_isrss as *const _ as usize },
9576 56usize,
9577 concat!(
9578 "Offset of field: ",
9579 stringify!(uv_rusage_t),
9580 "::",
9581 stringify!(ru_isrss)
9582 )
9583 );
9584 assert_eq!(
9585 unsafe { &(*(::std::ptr::null::<uv_rusage_t>())).ru_minflt as *const _ as usize },
9586 64usize,
9587 concat!(
9588 "Offset of field: ",
9589 stringify!(uv_rusage_t),
9590 "::",
9591 stringify!(ru_minflt)
9592 )
9593 );
9594 assert_eq!(
9595 unsafe { &(*(::std::ptr::null::<uv_rusage_t>())).ru_majflt as *const _ as usize },
9596 72usize,
9597 concat!(
9598 "Offset of field: ",
9599 stringify!(uv_rusage_t),
9600 "::",
9601 stringify!(ru_majflt)
9602 )
9603 );
9604 assert_eq!(
9605 unsafe { &(*(::std::ptr::null::<uv_rusage_t>())).ru_nswap as *const _ as usize },
9606 80usize,
9607 concat!(
9608 "Offset of field: ",
9609 stringify!(uv_rusage_t),
9610 "::",
9611 stringify!(ru_nswap)
9612 )
9613 );
9614 assert_eq!(
9615 unsafe { &(*(::std::ptr::null::<uv_rusage_t>())).ru_inblock as *const _ as usize },
9616 88usize,
9617 concat!(
9618 "Offset of field: ",
9619 stringify!(uv_rusage_t),
9620 "::",
9621 stringify!(ru_inblock)
9622 )
9623 );
9624 assert_eq!(
9625 unsafe { &(*(::std::ptr::null::<uv_rusage_t>())).ru_oublock as *const _ as usize },
9626 96usize,
9627 concat!(
9628 "Offset of field: ",
9629 stringify!(uv_rusage_t),
9630 "::",
9631 stringify!(ru_oublock)
9632 )
9633 );
9634 assert_eq!(
9635 unsafe { &(*(::std::ptr::null::<uv_rusage_t>())).ru_msgsnd as *const _ as usize },
9636 104usize,
9637 concat!(
9638 "Offset of field: ",
9639 stringify!(uv_rusage_t),
9640 "::",
9641 stringify!(ru_msgsnd)
9642 )
9643 );
9644 assert_eq!(
9645 unsafe { &(*(::std::ptr::null::<uv_rusage_t>())).ru_msgrcv as *const _ as usize },
9646 112usize,
9647 concat!(
9648 "Offset of field: ",
9649 stringify!(uv_rusage_t),
9650 "::",
9651 stringify!(ru_msgrcv)
9652 )
9653 );
9654 assert_eq!(
9655 unsafe { &(*(::std::ptr::null::<uv_rusage_t>())).ru_nsignals as *const _ as usize },
9656 120usize,
9657 concat!(
9658 "Offset of field: ",
9659 stringify!(uv_rusage_t),
9660 "::",
9661 stringify!(ru_nsignals)
9662 )
9663 );
9664 assert_eq!(
9665 unsafe { &(*(::std::ptr::null::<uv_rusage_t>())).ru_nvcsw as *const _ as usize },
9666 128usize,
9667 concat!(
9668 "Offset of field: ",
9669 stringify!(uv_rusage_t),
9670 "::",
9671 stringify!(ru_nvcsw)
9672 )
9673 );
9674 assert_eq!(
9675 unsafe { &(*(::std::ptr::null::<uv_rusage_t>())).ru_nivcsw as *const _ as usize },
9676 136usize,
9677 concat!(
9678 "Offset of field: ",
9679 stringify!(uv_rusage_t),
9680 "::",
9681 stringify!(ru_nivcsw)
9682 )
9683 );
9684}
9685extern "C" {
9686 pub fn uv_getrusage(rusage: *mut uv_rusage_t) -> ::std::os::raw::c_int;
9687}
9688extern "C" {
9689 pub fn uv_os_homedir(
9690 buffer: *mut ::std::os::raw::c_char,
9691 size: *mut size_t,
9692 ) -> ::std::os::raw::c_int;
9693}
9694extern "C" {
9695 pub fn uv_os_tmpdir(
9696 buffer: *mut ::std::os::raw::c_char,
9697 size: *mut size_t,
9698 ) -> ::std::os::raw::c_int;
9699}
9700extern "C" {
9701 pub fn uv_os_get_passwd(pwd: *mut uv_passwd_t) -> ::std::os::raw::c_int;
9702}
9703extern "C" {
9704 pub fn uv_os_free_passwd(pwd: *mut uv_passwd_t);
9705}
9706extern "C" {
9707 pub fn uv_os_getpid() -> uv_pid_t;
9708}
9709extern "C" {
9710 pub fn uv_os_getppid() -> uv_pid_t;
9711}
9712extern "C" {
9713 pub fn uv_os_getpriority(
9714 pid: uv_pid_t,
9715 priority: *mut ::std::os::raw::c_int,
9716 ) -> ::std::os::raw::c_int;
9717}
9718extern "C" {
9719 pub fn uv_os_setpriority(
9720 pid: uv_pid_t,
9721 priority: ::std::os::raw::c_int,
9722 ) -> ::std::os::raw::c_int;
9723}
9724extern "C" {
9725 pub fn uv_cpu_info(
9726 cpu_infos: *mut *mut uv_cpu_info_t,
9727 count: *mut ::std::os::raw::c_int,
9728 ) -> ::std::os::raw::c_int;
9729}
9730extern "C" {
9731 pub fn uv_free_cpu_info(cpu_infos: *mut uv_cpu_info_t, count: ::std::os::raw::c_int);
9732}
9733extern "C" {
9734 pub fn uv_interface_addresses(
9735 addresses: *mut *mut uv_interface_address_t,
9736 count: *mut ::std::os::raw::c_int,
9737 ) -> ::std::os::raw::c_int;
9738}
9739extern "C" {
9740 pub fn uv_free_interface_addresses(
9741 addresses: *mut uv_interface_address_t,
9742 count: ::std::os::raw::c_int,
9743 );
9744}
9745#[repr(C)]
9746#[derive(Debug, Copy, Clone)]
9747pub struct uv_env_item_s {
9748 pub name: *mut ::std::os::raw::c_char,
9749 pub value: *mut ::std::os::raw::c_char,
9750}
9751#[test]
9752fn bindgen_test_layout_uv_env_item_s() {
9753 assert_eq!(
9754 ::std::mem::size_of::<uv_env_item_s>(),
9755 16usize,
9756 concat!("Size of: ", stringify!(uv_env_item_s))
9757 );
9758 assert_eq!(
9759 ::std::mem::align_of::<uv_env_item_s>(),
9760 8usize,
9761 concat!("Alignment of ", stringify!(uv_env_item_s))
9762 );
9763 assert_eq!(
9764 unsafe { &(*(::std::ptr::null::<uv_env_item_s>())).name as *const _ as usize },
9765 0usize,
9766 concat!(
9767 "Offset of field: ",
9768 stringify!(uv_env_item_s),
9769 "::",
9770 stringify!(name)
9771 )
9772 );
9773 assert_eq!(
9774 unsafe { &(*(::std::ptr::null::<uv_env_item_s>())).value as *const _ as usize },
9775 8usize,
9776 concat!(
9777 "Offset of field: ",
9778 stringify!(uv_env_item_s),
9779 "::",
9780 stringify!(value)
9781 )
9782 );
9783}
9784impl Default for uv_env_item_s {
9785 fn default() -> Self {
9786 unsafe { ::std::mem::zeroed() }
9787 }
9788}
9789extern "C" {
9790 pub fn uv_os_environ(
9791 envitems: *mut *mut uv_env_item_t,
9792 count: *mut ::std::os::raw::c_int,
9793 ) -> ::std::os::raw::c_int;
9794}
9795extern "C" {
9796 pub fn uv_os_free_environ(envitems: *mut uv_env_item_t, count: ::std::os::raw::c_int);
9797}
9798extern "C" {
9799 pub fn uv_os_getenv(
9800 name: *const ::std::os::raw::c_char,
9801 buffer: *mut ::std::os::raw::c_char,
9802 size: *mut size_t,
9803 ) -> ::std::os::raw::c_int;
9804}
9805extern "C" {
9806 pub fn uv_os_setenv(
9807 name: *const ::std::os::raw::c_char,
9808 value: *const ::std::os::raw::c_char,
9809 ) -> ::std::os::raw::c_int;
9810}
9811extern "C" {
9812 pub fn uv_os_unsetenv(name: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int;
9813}
9814extern "C" {
9815 pub fn uv_os_gethostname(
9816 buffer: *mut ::std::os::raw::c_char,
9817 size: *mut size_t,
9818 ) -> ::std::os::raw::c_int;
9819}
9820extern "C" {
9821 pub fn uv_os_uname(buffer: *mut uv_utsname_t) -> ::std::os::raw::c_int;
9822}
9823extern "C" {
9824 pub fn uv_metrics_idle_time(loop_: *mut uv_loop_t) -> u64;
9825}
9826#[repr(i32)]
9827#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
9828pub enum uv_fs_type {
9829 UV_FS_UNKNOWN = -1,
9830 UV_FS_CUSTOM = 0,
9831 UV_FS_OPEN = 1,
9832 UV_FS_CLOSE = 2,
9833 UV_FS_READ = 3,
9834 UV_FS_WRITE = 4,
9835 UV_FS_SENDFILE = 5,
9836 UV_FS_STAT = 6,
9837 UV_FS_LSTAT = 7,
9838 UV_FS_FSTAT = 8,
9839 UV_FS_FTRUNCATE = 9,
9840 UV_FS_UTIME = 10,
9841 UV_FS_FUTIME = 11,
9842 UV_FS_ACCESS = 12,
9843 UV_FS_CHMOD = 13,
9844 UV_FS_FCHMOD = 14,
9845 UV_FS_FSYNC = 15,
9846 UV_FS_FDATASYNC = 16,
9847 UV_FS_UNLINK = 17,
9848 UV_FS_RMDIR = 18,
9849 UV_FS_MKDIR = 19,
9850 UV_FS_MKDTEMP = 20,
9851 UV_FS_RENAME = 21,
9852 UV_FS_SCANDIR = 22,
9853 UV_FS_LINK = 23,
9854 UV_FS_SYMLINK = 24,
9855 UV_FS_READLINK = 25,
9856 UV_FS_CHOWN = 26,
9857 UV_FS_FCHOWN = 27,
9858 UV_FS_REALPATH = 28,
9859 UV_FS_COPYFILE = 29,
9860 UV_FS_LCHOWN = 30,
9861 UV_FS_OPENDIR = 31,
9862 UV_FS_READDIR = 32,
9863 UV_FS_CLOSEDIR = 33,
9864 UV_FS_STATFS = 34,
9865 UV_FS_MKSTEMP = 35,
9866 UV_FS_LUTIME = 36,
9867}
9868#[repr(C)]
9869#[derive(Debug, Copy, Clone)]
9870pub struct uv_dir_s {
9871 pub dirents: *mut uv_dirent_t,
9872 pub nentries: size_t,
9873 pub reserved: [*mut ::std::os::raw::c_void; 4usize],
9874 pub dir: *mut DIR,
9875}
9876#[test]
9877fn bindgen_test_layout_uv_dir_s() {
9878 assert_eq!(
9879 ::std::mem::size_of::<uv_dir_s>(),
9880 56usize,
9881 concat!("Size of: ", stringify!(uv_dir_s))
9882 );
9883 assert_eq!(
9884 ::std::mem::align_of::<uv_dir_s>(),
9885 8usize,
9886 concat!("Alignment of ", stringify!(uv_dir_s))
9887 );
9888 assert_eq!(
9889 unsafe { &(*(::std::ptr::null::<uv_dir_s>())).dirents as *const _ as usize },
9890 0usize,
9891 concat!(
9892 "Offset of field: ",
9893 stringify!(uv_dir_s),
9894 "::",
9895 stringify!(dirents)
9896 )
9897 );
9898 assert_eq!(
9899 unsafe { &(*(::std::ptr::null::<uv_dir_s>())).nentries as *const _ as usize },
9900 8usize,
9901 concat!(
9902 "Offset of field: ",
9903 stringify!(uv_dir_s),
9904 "::",
9905 stringify!(nentries)
9906 )
9907 );
9908 assert_eq!(
9909 unsafe { &(*(::std::ptr::null::<uv_dir_s>())).reserved as *const _ as usize },
9910 16usize,
9911 concat!(
9912 "Offset of field: ",
9913 stringify!(uv_dir_s),
9914 "::",
9915 stringify!(reserved)
9916 )
9917 );
9918 assert_eq!(
9919 unsafe { &(*(::std::ptr::null::<uv_dir_s>())).dir as *const _ as usize },
9920 48usize,
9921 concat!(
9922 "Offset of field: ",
9923 stringify!(uv_dir_s),
9924 "::",
9925 stringify!(dir)
9926 )
9927 );
9928}
9929impl Default for uv_dir_s {
9930 fn default() -> Self {
9931 unsafe { ::std::mem::zeroed() }
9932 }
9933}
9934#[repr(C)]
9935#[derive(Debug, Copy, Clone)]
9936pub struct uv_fs_s {
9937 pub data: *mut ::std::os::raw::c_void,
9938 pub type_: uv_req_type,
9939 pub reserved: [*mut ::std::os::raw::c_void; 6usize],
9940 pub fs_type: uv_fs_type,
9941 pub loop_: *mut uv_loop_t,
9942 pub cb: uv_fs_cb,
9943 pub result: ssize_t,
9944 pub ptr: *mut ::std::os::raw::c_void,
9945 pub path: *const ::std::os::raw::c_char,
9946 pub statbuf: uv_stat_t,
9947 pub new_path: *const ::std::os::raw::c_char,
9948 pub file: uv_file,
9949 pub flags: ::std::os::raw::c_int,
9950 pub mode: mode_t,
9951 pub nbufs: ::std::os::raw::c_uint,
9952 pub bufs: *mut uv_buf_t,
9953 pub off: off_t,
9954 pub uid: uv_uid_t,
9955 pub gid: uv_gid_t,
9956 pub atime: f64,
9957 pub mtime: f64,
9958 pub work_req: uv__work,
9959 pub bufsml: [uv_buf_t; 4usize],
9960}
9961#[test]
9962fn bindgen_test_layout_uv_fs_s() {
9963 assert_eq!(
9964 ::std::mem::size_of::<uv_fs_s>(),
9965 440usize,
9966 concat!("Size of: ", stringify!(uv_fs_s))
9967 );
9968 assert_eq!(
9969 ::std::mem::align_of::<uv_fs_s>(),
9970 8usize,
9971 concat!("Alignment of ", stringify!(uv_fs_s))
9972 );
9973 assert_eq!(
9974 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).data as *const _ as usize },
9975 0usize,
9976 concat!(
9977 "Offset of field: ",
9978 stringify!(uv_fs_s),
9979 "::",
9980 stringify!(data)
9981 )
9982 );
9983 assert_eq!(
9984 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).type_ as *const _ as usize },
9985 8usize,
9986 concat!(
9987 "Offset of field: ",
9988 stringify!(uv_fs_s),
9989 "::",
9990 stringify!(type_)
9991 )
9992 );
9993 assert_eq!(
9994 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).reserved as *const _ as usize },
9995 16usize,
9996 concat!(
9997 "Offset of field: ",
9998 stringify!(uv_fs_s),
9999 "::",
10000 stringify!(reserved)
10001 )
10002 );
10003 assert_eq!(
10004 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).fs_type as *const _ as usize },
10005 64usize,
10006 concat!(
10007 "Offset of field: ",
10008 stringify!(uv_fs_s),
10009 "::",
10010 stringify!(fs_type)
10011 )
10012 );
10013 assert_eq!(
10014 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).loop_ as *const _ as usize },
10015 72usize,
10016 concat!(
10017 "Offset of field: ",
10018 stringify!(uv_fs_s),
10019 "::",
10020 stringify!(loop_)
10021 )
10022 );
10023 assert_eq!(
10024 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).cb as *const _ as usize },
10025 80usize,
10026 concat!(
10027 "Offset of field: ",
10028 stringify!(uv_fs_s),
10029 "::",
10030 stringify!(cb)
10031 )
10032 );
10033 assert_eq!(
10034 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).result as *const _ as usize },
10035 88usize,
10036 concat!(
10037 "Offset of field: ",
10038 stringify!(uv_fs_s),
10039 "::",
10040 stringify!(result)
10041 )
10042 );
10043 assert_eq!(
10044 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).ptr as *const _ as usize },
10045 96usize,
10046 concat!(
10047 "Offset of field: ",
10048 stringify!(uv_fs_s),
10049 "::",
10050 stringify!(ptr)
10051 )
10052 );
10053 assert_eq!(
10054 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).path as *const _ as usize },
10055 104usize,
10056 concat!(
10057 "Offset of field: ",
10058 stringify!(uv_fs_s),
10059 "::",
10060 stringify!(path)
10061 )
10062 );
10063 assert_eq!(
10064 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).statbuf as *const _ as usize },
10065 112usize,
10066 concat!(
10067 "Offset of field: ",
10068 stringify!(uv_fs_s),
10069 "::",
10070 stringify!(statbuf)
10071 )
10072 );
10073 assert_eq!(
10074 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).new_path as *const _ as usize },
10075 272usize,
10076 concat!(
10077 "Offset of field: ",
10078 stringify!(uv_fs_s),
10079 "::",
10080 stringify!(new_path)
10081 )
10082 );
10083 assert_eq!(
10084 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).file as *const _ as usize },
10085 280usize,
10086 concat!(
10087 "Offset of field: ",
10088 stringify!(uv_fs_s),
10089 "::",
10090 stringify!(file)
10091 )
10092 );
10093 assert_eq!(
10094 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).flags as *const _ as usize },
10095 284usize,
10096 concat!(
10097 "Offset of field: ",
10098 stringify!(uv_fs_s),
10099 "::",
10100 stringify!(flags)
10101 )
10102 );
10103 assert_eq!(
10104 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).mode as *const _ as usize },
10105 288usize,
10106 concat!(
10107 "Offset of field: ",
10108 stringify!(uv_fs_s),
10109 "::",
10110 stringify!(mode)
10111 )
10112 );
10113 assert_eq!(
10114 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).nbufs as *const _ as usize },
10115 292usize,
10116 concat!(
10117 "Offset of field: ",
10118 stringify!(uv_fs_s),
10119 "::",
10120 stringify!(nbufs)
10121 )
10122 );
10123 assert_eq!(
10124 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).bufs as *const _ as usize },
10125 296usize,
10126 concat!(
10127 "Offset of field: ",
10128 stringify!(uv_fs_s),
10129 "::",
10130 stringify!(bufs)
10131 )
10132 );
10133 assert_eq!(
10134 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).off as *const _ as usize },
10135 304usize,
10136 concat!(
10137 "Offset of field: ",
10138 stringify!(uv_fs_s),
10139 "::",
10140 stringify!(off)
10141 )
10142 );
10143 assert_eq!(
10144 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).uid as *const _ as usize },
10145 312usize,
10146 concat!(
10147 "Offset of field: ",
10148 stringify!(uv_fs_s),
10149 "::",
10150 stringify!(uid)
10151 )
10152 );
10153 assert_eq!(
10154 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).gid as *const _ as usize },
10155 316usize,
10156 concat!(
10157 "Offset of field: ",
10158 stringify!(uv_fs_s),
10159 "::",
10160 stringify!(gid)
10161 )
10162 );
10163 assert_eq!(
10164 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).atime as *const _ as usize },
10165 320usize,
10166 concat!(
10167 "Offset of field: ",
10168 stringify!(uv_fs_s),
10169 "::",
10170 stringify!(atime)
10171 )
10172 );
10173 assert_eq!(
10174 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).mtime as *const _ as usize },
10175 328usize,
10176 concat!(
10177 "Offset of field: ",
10178 stringify!(uv_fs_s),
10179 "::",
10180 stringify!(mtime)
10181 )
10182 );
10183 assert_eq!(
10184 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).work_req as *const _ as usize },
10185 336usize,
10186 concat!(
10187 "Offset of field: ",
10188 stringify!(uv_fs_s),
10189 "::",
10190 stringify!(work_req)
10191 )
10192 );
10193 assert_eq!(
10194 unsafe { &(*(::std::ptr::null::<uv_fs_s>())).bufsml as *const _ as usize },
10195 376usize,
10196 concat!(
10197 "Offset of field: ",
10198 stringify!(uv_fs_s),
10199 "::",
10200 stringify!(bufsml)
10201 )
10202 );
10203}
10204impl Default for uv_fs_s {
10205 fn default() -> Self {
10206 unsafe { ::std::mem::zeroed() }
10207 }
10208}
10209extern "C" {
10210 pub fn uv_fs_get_type(arg1: *const uv_fs_t) -> uv_fs_type;
10211}
10212extern "C" {
10213 pub fn uv_fs_get_result(arg1: *const uv_fs_t) -> ssize_t;
10214}
10215extern "C" {
10216 pub fn uv_fs_get_system_error(arg1: *const uv_fs_t) -> ::std::os::raw::c_int;
10217}
10218extern "C" {
10219 pub fn uv_fs_get_ptr(arg1: *const uv_fs_t) -> *mut ::std::os::raw::c_void;
10220}
10221extern "C" {
10222 pub fn uv_fs_get_path(arg1: *const uv_fs_t) -> *const ::std::os::raw::c_char;
10223}
10224extern "C" {
10225 pub fn uv_fs_get_statbuf(arg1: *mut uv_fs_t) -> *mut uv_stat_t;
10226}
10227extern "C" {
10228 pub fn uv_fs_req_cleanup(req: *mut uv_fs_t);
10229}
10230extern "C" {
10231 pub fn uv_fs_close(
10232 loop_: *mut uv_loop_t,
10233 req: *mut uv_fs_t,
10234 file: uv_file,
10235 cb: uv_fs_cb,
10236 ) -> ::std::os::raw::c_int;
10237}
10238extern "C" {
10239 pub fn uv_fs_open(
10240 loop_: *mut uv_loop_t,
10241 req: *mut uv_fs_t,
10242 path: *const ::std::os::raw::c_char,
10243 flags: ::std::os::raw::c_int,
10244 mode: ::std::os::raw::c_int,
10245 cb: uv_fs_cb,
10246 ) -> ::std::os::raw::c_int;
10247}
10248extern "C" {
10249 pub fn uv_fs_read(
10250 loop_: *mut uv_loop_t,
10251 req: *mut uv_fs_t,
10252 file: uv_file,
10253 bufs: *const uv_buf_t,
10254 nbufs: ::std::os::raw::c_uint,
10255 offset: i64,
10256 cb: uv_fs_cb,
10257 ) -> ::std::os::raw::c_int;
10258}
10259extern "C" {
10260 pub fn uv_fs_unlink(
10261 loop_: *mut uv_loop_t,
10262 req: *mut uv_fs_t,
10263 path: *const ::std::os::raw::c_char,
10264 cb: uv_fs_cb,
10265 ) -> ::std::os::raw::c_int;
10266}
10267extern "C" {
10268 pub fn uv_fs_write(
10269 loop_: *mut uv_loop_t,
10270 req: *mut uv_fs_t,
10271 file: uv_file,
10272 bufs: *const uv_buf_t,
10273 nbufs: ::std::os::raw::c_uint,
10274 offset: i64,
10275 cb: uv_fs_cb,
10276 ) -> ::std::os::raw::c_int;
10277}
10278extern "C" {
10279 pub fn uv_fs_copyfile(
10280 loop_: *mut uv_loop_t,
10281 req: *mut uv_fs_t,
10282 path: *const ::std::os::raw::c_char,
10283 new_path: *const ::std::os::raw::c_char,
10284 flags: ::std::os::raw::c_int,
10285 cb: uv_fs_cb,
10286 ) -> ::std::os::raw::c_int;
10287}
10288extern "C" {
10289 pub fn uv_fs_mkdir(
10290 loop_: *mut uv_loop_t,
10291 req: *mut uv_fs_t,
10292 path: *const ::std::os::raw::c_char,
10293 mode: ::std::os::raw::c_int,
10294 cb: uv_fs_cb,
10295 ) -> ::std::os::raw::c_int;
10296}
10297extern "C" {
10298 pub fn uv_fs_mkdtemp(
10299 loop_: *mut uv_loop_t,
10300 req: *mut uv_fs_t,
10301 tpl: *const ::std::os::raw::c_char,
10302 cb: uv_fs_cb,
10303 ) -> ::std::os::raw::c_int;
10304}
10305extern "C" {
10306 pub fn uv_fs_mkstemp(
10307 loop_: *mut uv_loop_t,
10308 req: *mut uv_fs_t,
10309 tpl: *const ::std::os::raw::c_char,
10310 cb: uv_fs_cb,
10311 ) -> ::std::os::raw::c_int;
10312}
10313extern "C" {
10314 pub fn uv_fs_rmdir(
10315 loop_: *mut uv_loop_t,
10316 req: *mut uv_fs_t,
10317 path: *const ::std::os::raw::c_char,
10318 cb: uv_fs_cb,
10319 ) -> ::std::os::raw::c_int;
10320}
10321extern "C" {
10322 pub fn uv_fs_scandir(
10323 loop_: *mut uv_loop_t,
10324 req: *mut uv_fs_t,
10325 path: *const ::std::os::raw::c_char,
10326 flags: ::std::os::raw::c_int,
10327 cb: uv_fs_cb,
10328 ) -> ::std::os::raw::c_int;
10329}
10330extern "C" {
10331 pub fn uv_fs_scandir_next(req: *mut uv_fs_t, ent: *mut uv_dirent_t) -> ::std::os::raw::c_int;
10332}
10333extern "C" {
10334 pub fn uv_fs_opendir(
10335 loop_: *mut uv_loop_t,
10336 req: *mut uv_fs_t,
10337 path: *const ::std::os::raw::c_char,
10338 cb: uv_fs_cb,
10339 ) -> ::std::os::raw::c_int;
10340}
10341extern "C" {
10342 pub fn uv_fs_readdir(
10343 loop_: *mut uv_loop_t,
10344 req: *mut uv_fs_t,
10345 dir: *mut uv_dir_t,
10346 cb: uv_fs_cb,
10347 ) -> ::std::os::raw::c_int;
10348}
10349extern "C" {
10350 pub fn uv_fs_closedir(
10351 loop_: *mut uv_loop_t,
10352 req: *mut uv_fs_t,
10353 dir: *mut uv_dir_t,
10354 cb: uv_fs_cb,
10355 ) -> ::std::os::raw::c_int;
10356}
10357extern "C" {
10358 pub fn uv_fs_stat(
10359 loop_: *mut uv_loop_t,
10360 req: *mut uv_fs_t,
10361 path: *const ::std::os::raw::c_char,
10362 cb: uv_fs_cb,
10363 ) -> ::std::os::raw::c_int;
10364}
10365extern "C" {
10366 pub fn uv_fs_fstat(
10367 loop_: *mut uv_loop_t,
10368 req: *mut uv_fs_t,
10369 file: uv_file,
10370 cb: uv_fs_cb,
10371 ) -> ::std::os::raw::c_int;
10372}
10373extern "C" {
10374 pub fn uv_fs_rename(
10375 loop_: *mut uv_loop_t,
10376 req: *mut uv_fs_t,
10377 path: *const ::std::os::raw::c_char,
10378 new_path: *const ::std::os::raw::c_char,
10379 cb: uv_fs_cb,
10380 ) -> ::std::os::raw::c_int;
10381}
10382extern "C" {
10383 pub fn uv_fs_fsync(
10384 loop_: *mut uv_loop_t,
10385 req: *mut uv_fs_t,
10386 file: uv_file,
10387 cb: uv_fs_cb,
10388 ) -> ::std::os::raw::c_int;
10389}
10390extern "C" {
10391 pub fn uv_fs_fdatasync(
10392 loop_: *mut uv_loop_t,
10393 req: *mut uv_fs_t,
10394 file: uv_file,
10395 cb: uv_fs_cb,
10396 ) -> ::std::os::raw::c_int;
10397}
10398extern "C" {
10399 pub fn uv_fs_ftruncate(
10400 loop_: *mut uv_loop_t,
10401 req: *mut uv_fs_t,
10402 file: uv_file,
10403 offset: i64,
10404 cb: uv_fs_cb,
10405 ) -> ::std::os::raw::c_int;
10406}
10407extern "C" {
10408 pub fn uv_fs_sendfile(
10409 loop_: *mut uv_loop_t,
10410 req: *mut uv_fs_t,
10411 out_fd: uv_file,
10412 in_fd: uv_file,
10413 in_offset: i64,
10414 length: size_t,
10415 cb: uv_fs_cb,
10416 ) -> ::std::os::raw::c_int;
10417}
10418extern "C" {
10419 pub fn uv_fs_access(
10420 loop_: *mut uv_loop_t,
10421 req: *mut uv_fs_t,
10422 path: *const ::std::os::raw::c_char,
10423 mode: ::std::os::raw::c_int,
10424 cb: uv_fs_cb,
10425 ) -> ::std::os::raw::c_int;
10426}
10427extern "C" {
10428 pub fn uv_fs_chmod(
10429 loop_: *mut uv_loop_t,
10430 req: *mut uv_fs_t,
10431 path: *const ::std::os::raw::c_char,
10432 mode: ::std::os::raw::c_int,
10433 cb: uv_fs_cb,
10434 ) -> ::std::os::raw::c_int;
10435}
10436extern "C" {
10437 pub fn uv_fs_utime(
10438 loop_: *mut uv_loop_t,
10439 req: *mut uv_fs_t,
10440 path: *const ::std::os::raw::c_char,
10441 atime: f64,
10442 mtime: f64,
10443 cb: uv_fs_cb,
10444 ) -> ::std::os::raw::c_int;
10445}
10446extern "C" {
10447 pub fn uv_fs_futime(
10448 loop_: *mut uv_loop_t,
10449 req: *mut uv_fs_t,
10450 file: uv_file,
10451 atime: f64,
10452 mtime: f64,
10453 cb: uv_fs_cb,
10454 ) -> ::std::os::raw::c_int;
10455}
10456extern "C" {
10457 pub fn uv_fs_lutime(
10458 loop_: *mut uv_loop_t,
10459 req: *mut uv_fs_t,
10460 path: *const ::std::os::raw::c_char,
10461 atime: f64,
10462 mtime: f64,
10463 cb: uv_fs_cb,
10464 ) -> ::std::os::raw::c_int;
10465}
10466extern "C" {
10467 pub fn uv_fs_lstat(
10468 loop_: *mut uv_loop_t,
10469 req: *mut uv_fs_t,
10470 path: *const ::std::os::raw::c_char,
10471 cb: uv_fs_cb,
10472 ) -> ::std::os::raw::c_int;
10473}
10474extern "C" {
10475 pub fn uv_fs_link(
10476 loop_: *mut uv_loop_t,
10477 req: *mut uv_fs_t,
10478 path: *const ::std::os::raw::c_char,
10479 new_path: *const ::std::os::raw::c_char,
10480 cb: uv_fs_cb,
10481 ) -> ::std::os::raw::c_int;
10482}
10483extern "C" {
10484 pub fn uv_fs_symlink(
10485 loop_: *mut uv_loop_t,
10486 req: *mut uv_fs_t,
10487 path: *const ::std::os::raw::c_char,
10488 new_path: *const ::std::os::raw::c_char,
10489 flags: ::std::os::raw::c_int,
10490 cb: uv_fs_cb,
10491 ) -> ::std::os::raw::c_int;
10492}
10493extern "C" {
10494 pub fn uv_fs_readlink(
10495 loop_: *mut uv_loop_t,
10496 req: *mut uv_fs_t,
10497 path: *const ::std::os::raw::c_char,
10498 cb: uv_fs_cb,
10499 ) -> ::std::os::raw::c_int;
10500}
10501extern "C" {
10502 pub fn uv_fs_realpath(
10503 loop_: *mut uv_loop_t,
10504 req: *mut uv_fs_t,
10505 path: *const ::std::os::raw::c_char,
10506 cb: uv_fs_cb,
10507 ) -> ::std::os::raw::c_int;
10508}
10509extern "C" {
10510 pub fn uv_fs_fchmod(
10511 loop_: *mut uv_loop_t,
10512 req: *mut uv_fs_t,
10513 file: uv_file,
10514 mode: ::std::os::raw::c_int,
10515 cb: uv_fs_cb,
10516 ) -> ::std::os::raw::c_int;
10517}
10518extern "C" {
10519 pub fn uv_fs_chown(
10520 loop_: *mut uv_loop_t,
10521 req: *mut uv_fs_t,
10522 path: *const ::std::os::raw::c_char,
10523 uid: uv_uid_t,
10524 gid: uv_gid_t,
10525 cb: uv_fs_cb,
10526 ) -> ::std::os::raw::c_int;
10527}
10528extern "C" {
10529 pub fn uv_fs_fchown(
10530 loop_: *mut uv_loop_t,
10531 req: *mut uv_fs_t,
10532 file: uv_file,
10533 uid: uv_uid_t,
10534 gid: uv_gid_t,
10535 cb: uv_fs_cb,
10536 ) -> ::std::os::raw::c_int;
10537}
10538extern "C" {
10539 pub fn uv_fs_lchown(
10540 loop_: *mut uv_loop_t,
10541 req: *mut uv_fs_t,
10542 path: *const ::std::os::raw::c_char,
10543 uid: uv_uid_t,
10544 gid: uv_gid_t,
10545 cb: uv_fs_cb,
10546 ) -> ::std::os::raw::c_int;
10547}
10548extern "C" {
10549 pub fn uv_fs_statfs(
10550 loop_: *mut uv_loop_t,
10551 req: *mut uv_fs_t,
10552 path: *const ::std::os::raw::c_char,
10553 cb: uv_fs_cb,
10554 ) -> ::std::os::raw::c_int;
10555}
10556#[repr(u32)]
10557#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
10558pub enum uv_fs_event {
10559 UV_RENAME = 1,
10560 UV_CHANGE = 2,
10561}
10562#[repr(C)]
10563#[derive(Copy, Clone)]
10564pub struct uv_fs_event_s {
10565 pub data: *mut ::std::os::raw::c_void,
10566 pub loop_: *mut uv_loop_t,
10567 pub type_: uv_handle_type,
10568 pub close_cb: uv_close_cb,
10569 pub handle_queue: [*mut ::std::os::raw::c_void; 2usize],
10570 pub u: uv_fs_event_s__bindgen_ty_1,
10571 pub next_closing: *mut uv_handle_t,
10572 pub flags: ::std::os::raw::c_uint,
10573 pub path: *mut ::std::os::raw::c_char,
10574 pub cb: uv_fs_event_cb,
10575 pub event_watcher: uv__io_t,
10576 pub realpath: *mut ::std::os::raw::c_char,
10577 pub realpath_len: ::std::os::raw::c_int,
10578 pub cf_flags: ::std::os::raw::c_int,
10579 pub cf_cb: *mut uv_async_t,
10580 pub cf_events: [*mut ::std::os::raw::c_void; 2usize],
10581 pub cf_member: [*mut ::std::os::raw::c_void; 2usize],
10582 pub cf_error: ::std::os::raw::c_int,
10583 pub cf_mutex: uv_mutex_t,
10584}
10585#[repr(C)]
10586#[derive(Copy, Clone)]
10587pub union uv_fs_event_s__bindgen_ty_1 {
10588 pub fd: ::std::os::raw::c_int,
10589 pub reserved: [*mut ::std::os::raw::c_void; 4usize],
10590 _bindgen_union_align: [u64; 4usize],
10591}
10592#[test]
10593fn bindgen_test_layout_uv_fs_event_s__bindgen_ty_1() {
10594 assert_eq!(
10595 ::std::mem::size_of::<uv_fs_event_s__bindgen_ty_1>(),
10596 32usize,
10597 concat!("Size of: ", stringify!(uv_fs_event_s__bindgen_ty_1))
10598 );
10599 assert_eq!(
10600 ::std::mem::align_of::<uv_fs_event_s__bindgen_ty_1>(),
10601 8usize,
10602 concat!("Alignment of ", stringify!(uv_fs_event_s__bindgen_ty_1))
10603 );
10604 assert_eq!(
10605 unsafe { &(*(::std::ptr::null::<uv_fs_event_s__bindgen_ty_1>())).fd as *const _ as usize },
10606 0usize,
10607 concat!(
10608 "Offset of field: ",
10609 stringify!(uv_fs_event_s__bindgen_ty_1),
10610 "::",
10611 stringify!(fd)
10612 )
10613 );
10614 assert_eq!(
10615 unsafe {
10616 &(*(::std::ptr::null::<uv_fs_event_s__bindgen_ty_1>())).reserved as *const _ as usize
10617 },
10618 0usize,
10619 concat!(
10620 "Offset of field: ",
10621 stringify!(uv_fs_event_s__bindgen_ty_1),
10622 "::",
10623 stringify!(reserved)
10624 )
10625 );
10626}
10627impl Default for uv_fs_event_s__bindgen_ty_1 {
10628 fn default() -> Self {
10629 unsafe { ::std::mem::zeroed() }
10630 }
10631}
10632#[test]
10633fn bindgen_test_layout_uv_fs_event_s() {
10634 assert_eq!(
10635 ::std::mem::size_of::<uv_fs_event_s>(),
10636 304usize,
10637 concat!("Size of: ", stringify!(uv_fs_event_s))
10638 );
10639 assert_eq!(
10640 ::std::mem::align_of::<uv_fs_event_s>(),
10641 8usize,
10642 concat!("Alignment of ", stringify!(uv_fs_event_s))
10643 );
10644 assert_eq!(
10645 unsafe { &(*(::std::ptr::null::<uv_fs_event_s>())).data as *const _ as usize },
10646 0usize,
10647 concat!(
10648 "Offset of field: ",
10649 stringify!(uv_fs_event_s),
10650 "::",
10651 stringify!(data)
10652 )
10653 );
10654 assert_eq!(
10655 unsafe { &(*(::std::ptr::null::<uv_fs_event_s>())).loop_ as *const _ as usize },
10656 8usize,
10657 concat!(
10658 "Offset of field: ",
10659 stringify!(uv_fs_event_s),
10660 "::",
10661 stringify!(loop_)
10662 )
10663 );
10664 assert_eq!(
10665 unsafe { &(*(::std::ptr::null::<uv_fs_event_s>())).type_ as *const _ as usize },
10666 16usize,
10667 concat!(
10668 "Offset of field: ",
10669 stringify!(uv_fs_event_s),
10670 "::",
10671 stringify!(type_)
10672 )
10673 );
10674 assert_eq!(
10675 unsafe { &(*(::std::ptr::null::<uv_fs_event_s>())).close_cb as *const _ as usize },
10676 24usize,
10677 concat!(
10678 "Offset of field: ",
10679 stringify!(uv_fs_event_s),
10680 "::",
10681 stringify!(close_cb)
10682 )
10683 );
10684 assert_eq!(
10685 unsafe { &(*(::std::ptr::null::<uv_fs_event_s>())).handle_queue as *const _ as usize },
10686 32usize,
10687 concat!(
10688 "Offset of field: ",
10689 stringify!(uv_fs_event_s),
10690 "::",
10691 stringify!(handle_queue)
10692 )
10693 );
10694 assert_eq!(
10695 unsafe { &(*(::std::ptr::null::<uv_fs_event_s>())).u as *const _ as usize },
10696 48usize,
10697 concat!(
10698 "Offset of field: ",
10699 stringify!(uv_fs_event_s),
10700 "::",
10701 stringify!(u)
10702 )
10703 );
10704 assert_eq!(
10705 unsafe { &(*(::std::ptr::null::<uv_fs_event_s>())).next_closing as *const _ as usize },
10706 80usize,
10707 concat!(
10708 "Offset of field: ",
10709 stringify!(uv_fs_event_s),
10710 "::",
10711 stringify!(next_closing)
10712 )
10713 );
10714 assert_eq!(
10715 unsafe { &(*(::std::ptr::null::<uv_fs_event_s>())).flags as *const _ as usize },
10716 88usize,
10717 concat!(
10718 "Offset of field: ",
10719 stringify!(uv_fs_event_s),
10720 "::",
10721 stringify!(flags)
10722 )
10723 );
10724 assert_eq!(
10725 unsafe { &(*(::std::ptr::null::<uv_fs_event_s>())).path as *const _ as usize },
10726 96usize,
10727 concat!(
10728 "Offset of field: ",
10729 stringify!(uv_fs_event_s),
10730 "::",
10731 stringify!(path)
10732 )
10733 );
10734 assert_eq!(
10735 unsafe { &(*(::std::ptr::null::<uv_fs_event_s>())).cb as *const _ as usize },
10736 104usize,
10737 concat!(
10738 "Offset of field: ",
10739 stringify!(uv_fs_event_s),
10740 "::",
10741 stringify!(cb)
10742 )
10743 );
10744 assert_eq!(
10745 unsafe { &(*(::std::ptr::null::<uv_fs_event_s>())).event_watcher as *const _ as usize },
10746 112usize,
10747 concat!(
10748 "Offset of field: ",
10749 stringify!(uv_fs_event_s),
10750 "::",
10751 stringify!(event_watcher)
10752 )
10753 );
10754 assert_eq!(
10755 unsafe { &(*(::std::ptr::null::<uv_fs_event_s>())).realpath as *const _ as usize },
10756 176usize,
10757 concat!(
10758 "Offset of field: ",
10759 stringify!(uv_fs_event_s),
10760 "::",
10761 stringify!(realpath)
10762 )
10763 );
10764 assert_eq!(
10765 unsafe { &(*(::std::ptr::null::<uv_fs_event_s>())).realpath_len as *const _ as usize },
10766 184usize,
10767 concat!(
10768 "Offset of field: ",
10769 stringify!(uv_fs_event_s),
10770 "::",
10771 stringify!(realpath_len)
10772 )
10773 );
10774 assert_eq!(
10775 unsafe { &(*(::std::ptr::null::<uv_fs_event_s>())).cf_flags as *const _ as usize },
10776 188usize,
10777 concat!(
10778 "Offset of field: ",
10779 stringify!(uv_fs_event_s),
10780 "::",
10781 stringify!(cf_flags)
10782 )
10783 );
10784 assert_eq!(
10785 unsafe { &(*(::std::ptr::null::<uv_fs_event_s>())).cf_cb as *const _ as usize },
10786 192usize,
10787 concat!(
10788 "Offset of field: ",
10789 stringify!(uv_fs_event_s),
10790 "::",
10791 stringify!(cf_cb)
10792 )
10793 );
10794 assert_eq!(
10795 unsafe { &(*(::std::ptr::null::<uv_fs_event_s>())).cf_events as *const _ as usize },
10796 200usize,
10797 concat!(
10798 "Offset of field: ",
10799 stringify!(uv_fs_event_s),
10800 "::",
10801 stringify!(cf_events)
10802 )
10803 );
10804 assert_eq!(
10805 unsafe { &(*(::std::ptr::null::<uv_fs_event_s>())).cf_member as *const _ as usize },
10806 216usize,
10807 concat!(
10808 "Offset of field: ",
10809 stringify!(uv_fs_event_s),
10810 "::",
10811 stringify!(cf_member)
10812 )
10813 );
10814 assert_eq!(
10815 unsafe { &(*(::std::ptr::null::<uv_fs_event_s>())).cf_error as *const _ as usize },
10816 232usize,
10817 concat!(
10818 "Offset of field: ",
10819 stringify!(uv_fs_event_s),
10820 "::",
10821 stringify!(cf_error)
10822 )
10823 );
10824 assert_eq!(
10825 unsafe { &(*(::std::ptr::null::<uv_fs_event_s>())).cf_mutex as *const _ as usize },
10826 240usize,
10827 concat!(
10828 "Offset of field: ",
10829 stringify!(uv_fs_event_s),
10830 "::",
10831 stringify!(cf_mutex)
10832 )
10833 );
10834}
10835impl Default for uv_fs_event_s {
10836 fn default() -> Self {
10837 unsafe { ::std::mem::zeroed() }
10838 }
10839}
10840#[repr(C)]
10841#[derive(Copy, Clone)]
10842pub struct uv_fs_poll_s {
10843 pub data: *mut ::std::os::raw::c_void,
10844 pub loop_: *mut uv_loop_t,
10845 pub type_: uv_handle_type,
10846 pub close_cb: uv_close_cb,
10847 pub handle_queue: [*mut ::std::os::raw::c_void; 2usize],
10848 pub u: uv_fs_poll_s__bindgen_ty_1,
10849 pub next_closing: *mut uv_handle_t,
10850 pub flags: ::std::os::raw::c_uint,
10851 pub poll_ctx: *mut ::std::os::raw::c_void,
10852}
10853#[repr(C)]
10854#[derive(Copy, Clone)]
10855pub union uv_fs_poll_s__bindgen_ty_1 {
10856 pub fd: ::std::os::raw::c_int,
10857 pub reserved: [*mut ::std::os::raw::c_void; 4usize],
10858 _bindgen_union_align: [u64; 4usize],
10859}
10860#[test]
10861fn bindgen_test_layout_uv_fs_poll_s__bindgen_ty_1() {
10862 assert_eq!(
10863 ::std::mem::size_of::<uv_fs_poll_s__bindgen_ty_1>(),
10864 32usize,
10865 concat!("Size of: ", stringify!(uv_fs_poll_s__bindgen_ty_1))
10866 );
10867 assert_eq!(
10868 ::std::mem::align_of::<uv_fs_poll_s__bindgen_ty_1>(),
10869 8usize,
10870 concat!("Alignment of ", stringify!(uv_fs_poll_s__bindgen_ty_1))
10871 );
10872 assert_eq!(
10873 unsafe { &(*(::std::ptr::null::<uv_fs_poll_s__bindgen_ty_1>())).fd as *const _ as usize },
10874 0usize,
10875 concat!(
10876 "Offset of field: ",
10877 stringify!(uv_fs_poll_s__bindgen_ty_1),
10878 "::",
10879 stringify!(fd)
10880 )
10881 );
10882 assert_eq!(
10883 unsafe {
10884 &(*(::std::ptr::null::<uv_fs_poll_s__bindgen_ty_1>())).reserved as *const _ as usize
10885 },
10886 0usize,
10887 concat!(
10888 "Offset of field: ",
10889 stringify!(uv_fs_poll_s__bindgen_ty_1),
10890 "::",
10891 stringify!(reserved)
10892 )
10893 );
10894}
10895impl Default for uv_fs_poll_s__bindgen_ty_1 {
10896 fn default() -> Self {
10897 unsafe { ::std::mem::zeroed() }
10898 }
10899}
10900#[test]
10901fn bindgen_test_layout_uv_fs_poll_s() {
10902 assert_eq!(
10903 ::std::mem::size_of::<uv_fs_poll_s>(),
10904 104usize,
10905 concat!("Size of: ", stringify!(uv_fs_poll_s))
10906 );
10907 assert_eq!(
10908 ::std::mem::align_of::<uv_fs_poll_s>(),
10909 8usize,
10910 concat!("Alignment of ", stringify!(uv_fs_poll_s))
10911 );
10912 assert_eq!(
10913 unsafe { &(*(::std::ptr::null::<uv_fs_poll_s>())).data as *const _ as usize },
10914 0usize,
10915 concat!(
10916 "Offset of field: ",
10917 stringify!(uv_fs_poll_s),
10918 "::",
10919 stringify!(data)
10920 )
10921 );
10922 assert_eq!(
10923 unsafe { &(*(::std::ptr::null::<uv_fs_poll_s>())).loop_ as *const _ as usize },
10924 8usize,
10925 concat!(
10926 "Offset of field: ",
10927 stringify!(uv_fs_poll_s),
10928 "::",
10929 stringify!(loop_)
10930 )
10931 );
10932 assert_eq!(
10933 unsafe { &(*(::std::ptr::null::<uv_fs_poll_s>())).type_ as *const _ as usize },
10934 16usize,
10935 concat!(
10936 "Offset of field: ",
10937 stringify!(uv_fs_poll_s),
10938 "::",
10939 stringify!(type_)
10940 )
10941 );
10942 assert_eq!(
10943 unsafe { &(*(::std::ptr::null::<uv_fs_poll_s>())).close_cb as *const _ as usize },
10944 24usize,
10945 concat!(
10946 "Offset of field: ",
10947 stringify!(uv_fs_poll_s),
10948 "::",
10949 stringify!(close_cb)
10950 )
10951 );
10952 assert_eq!(
10953 unsafe { &(*(::std::ptr::null::<uv_fs_poll_s>())).handle_queue as *const _ as usize },
10954 32usize,
10955 concat!(
10956 "Offset of field: ",
10957 stringify!(uv_fs_poll_s),
10958 "::",
10959 stringify!(handle_queue)
10960 )
10961 );
10962 assert_eq!(
10963 unsafe { &(*(::std::ptr::null::<uv_fs_poll_s>())).u as *const _ as usize },
10964 48usize,
10965 concat!(
10966 "Offset of field: ",
10967 stringify!(uv_fs_poll_s),
10968 "::",
10969 stringify!(u)
10970 )
10971 );
10972 assert_eq!(
10973 unsafe { &(*(::std::ptr::null::<uv_fs_poll_s>())).next_closing as *const _ as usize },
10974 80usize,
10975 concat!(
10976 "Offset of field: ",
10977 stringify!(uv_fs_poll_s),
10978 "::",
10979 stringify!(next_closing)
10980 )
10981 );
10982 assert_eq!(
10983 unsafe { &(*(::std::ptr::null::<uv_fs_poll_s>())).flags as *const _ as usize },
10984 88usize,
10985 concat!(
10986 "Offset of field: ",
10987 stringify!(uv_fs_poll_s),
10988 "::",
10989 stringify!(flags)
10990 )
10991 );
10992 assert_eq!(
10993 unsafe { &(*(::std::ptr::null::<uv_fs_poll_s>())).poll_ctx as *const _ as usize },
10994 96usize,
10995 concat!(
10996 "Offset of field: ",
10997 stringify!(uv_fs_poll_s),
10998 "::",
10999 stringify!(poll_ctx)
11000 )
11001 );
11002}
11003impl Default for uv_fs_poll_s {
11004 fn default() -> Self {
11005 unsafe { ::std::mem::zeroed() }
11006 }
11007}
11008extern "C" {
11009 pub fn uv_fs_poll_init(
11010 loop_: *mut uv_loop_t,
11011 handle: *mut uv_fs_poll_t,
11012 ) -> ::std::os::raw::c_int;
11013}
11014extern "C" {
11015 pub fn uv_fs_poll_start(
11016 handle: *mut uv_fs_poll_t,
11017 poll_cb: uv_fs_poll_cb,
11018 path: *const ::std::os::raw::c_char,
11019 interval: ::std::os::raw::c_uint,
11020 ) -> ::std::os::raw::c_int;
11021}
11022extern "C" {
11023 pub fn uv_fs_poll_stop(handle: *mut uv_fs_poll_t) -> ::std::os::raw::c_int;
11024}
11025extern "C" {
11026 pub fn uv_fs_poll_getpath(
11027 handle: *mut uv_fs_poll_t,
11028 buffer: *mut ::std::os::raw::c_char,
11029 size: *mut size_t,
11030 ) -> ::std::os::raw::c_int;
11031}
11032#[repr(C)]
11033#[derive(Copy, Clone)]
11034pub struct uv_signal_s {
11035 pub data: *mut ::std::os::raw::c_void,
11036 pub loop_: *mut uv_loop_t,
11037 pub type_: uv_handle_type,
11038 pub close_cb: uv_close_cb,
11039 pub handle_queue: [*mut ::std::os::raw::c_void; 2usize],
11040 pub u: uv_signal_s__bindgen_ty_1,
11041 pub next_closing: *mut uv_handle_t,
11042 pub flags: ::std::os::raw::c_uint,
11043 pub signal_cb: uv_signal_cb,
11044 pub signum: ::std::os::raw::c_int,
11045 pub tree_entry: uv_signal_s__bindgen_ty_2,
11046 pub caught_signals: ::std::os::raw::c_uint,
11047 pub dispatched_signals: ::std::os::raw::c_uint,
11048}
11049#[repr(C)]
11050#[derive(Copy, Clone)]
11051pub union uv_signal_s__bindgen_ty_1 {
11052 pub fd: ::std::os::raw::c_int,
11053 pub reserved: [*mut ::std::os::raw::c_void; 4usize],
11054 _bindgen_union_align: [u64; 4usize],
11055}
11056#[test]
11057fn bindgen_test_layout_uv_signal_s__bindgen_ty_1() {
11058 assert_eq!(
11059 ::std::mem::size_of::<uv_signal_s__bindgen_ty_1>(),
11060 32usize,
11061 concat!("Size of: ", stringify!(uv_signal_s__bindgen_ty_1))
11062 );
11063 assert_eq!(
11064 ::std::mem::align_of::<uv_signal_s__bindgen_ty_1>(),
11065 8usize,
11066 concat!("Alignment of ", stringify!(uv_signal_s__bindgen_ty_1))
11067 );
11068 assert_eq!(
11069 unsafe { &(*(::std::ptr::null::<uv_signal_s__bindgen_ty_1>())).fd as *const _ as usize },
11070 0usize,
11071 concat!(
11072 "Offset of field: ",
11073 stringify!(uv_signal_s__bindgen_ty_1),
11074 "::",
11075 stringify!(fd)
11076 )
11077 );
11078 assert_eq!(
11079 unsafe {
11080 &(*(::std::ptr::null::<uv_signal_s__bindgen_ty_1>())).reserved as *const _ as usize
11081 },
11082 0usize,
11083 concat!(
11084 "Offset of field: ",
11085 stringify!(uv_signal_s__bindgen_ty_1),
11086 "::",
11087 stringify!(reserved)
11088 )
11089 );
11090}
11091impl Default for uv_signal_s__bindgen_ty_1 {
11092 fn default() -> Self {
11093 unsafe { ::std::mem::zeroed() }
11094 }
11095}
11096#[repr(C)]
11097#[derive(Debug, Copy, Clone)]
11098pub struct uv_signal_s__bindgen_ty_2 {
11099 pub rbe_left: *mut uv_signal_s,
11100 pub rbe_right: *mut uv_signal_s,
11101 pub rbe_parent: *mut uv_signal_s,
11102 pub rbe_color: ::std::os::raw::c_int,
11103}
11104#[test]
11105fn bindgen_test_layout_uv_signal_s__bindgen_ty_2() {
11106 assert_eq!(
11107 ::std::mem::size_of::<uv_signal_s__bindgen_ty_2>(),
11108 32usize,
11109 concat!("Size of: ", stringify!(uv_signal_s__bindgen_ty_2))
11110 );
11111 assert_eq!(
11112 ::std::mem::align_of::<uv_signal_s__bindgen_ty_2>(),
11113 8usize,
11114 concat!("Alignment of ", stringify!(uv_signal_s__bindgen_ty_2))
11115 );
11116 assert_eq!(
11117 unsafe {
11118 &(*(::std::ptr::null::<uv_signal_s__bindgen_ty_2>())).rbe_left as *const _ as usize
11119 },
11120 0usize,
11121 concat!(
11122 "Offset of field: ",
11123 stringify!(uv_signal_s__bindgen_ty_2),
11124 "::",
11125 stringify!(rbe_left)
11126 )
11127 );
11128 assert_eq!(
11129 unsafe {
11130 &(*(::std::ptr::null::<uv_signal_s__bindgen_ty_2>())).rbe_right as *const _ as usize
11131 },
11132 8usize,
11133 concat!(
11134 "Offset of field: ",
11135 stringify!(uv_signal_s__bindgen_ty_2),
11136 "::",
11137 stringify!(rbe_right)
11138 )
11139 );
11140 assert_eq!(
11141 unsafe {
11142 &(*(::std::ptr::null::<uv_signal_s__bindgen_ty_2>())).rbe_parent as *const _ as usize
11143 },
11144 16usize,
11145 concat!(
11146 "Offset of field: ",
11147 stringify!(uv_signal_s__bindgen_ty_2),
11148 "::",
11149 stringify!(rbe_parent)
11150 )
11151 );
11152 assert_eq!(
11153 unsafe {
11154 &(*(::std::ptr::null::<uv_signal_s__bindgen_ty_2>())).rbe_color as *const _ as usize
11155 },
11156 24usize,
11157 concat!(
11158 "Offset of field: ",
11159 stringify!(uv_signal_s__bindgen_ty_2),
11160 "::",
11161 stringify!(rbe_color)
11162 )
11163 );
11164}
11165impl Default for uv_signal_s__bindgen_ty_2 {
11166 fn default() -> Self {
11167 unsafe { ::std::mem::zeroed() }
11168 }
11169}
11170#[test]
11171fn bindgen_test_layout_uv_signal_s() {
11172 assert_eq!(
11173 ::std::mem::size_of::<uv_signal_s>(),
11174 152usize,
11175 concat!("Size of: ", stringify!(uv_signal_s))
11176 );
11177 assert_eq!(
11178 ::std::mem::align_of::<uv_signal_s>(),
11179 8usize,
11180 concat!("Alignment of ", stringify!(uv_signal_s))
11181 );
11182 assert_eq!(
11183 unsafe { &(*(::std::ptr::null::<uv_signal_s>())).data as *const _ as usize },
11184 0usize,
11185 concat!(
11186 "Offset of field: ",
11187 stringify!(uv_signal_s),
11188 "::",
11189 stringify!(data)
11190 )
11191 );
11192 assert_eq!(
11193 unsafe { &(*(::std::ptr::null::<uv_signal_s>())).loop_ as *const _ as usize },
11194 8usize,
11195 concat!(
11196 "Offset of field: ",
11197 stringify!(uv_signal_s),
11198 "::",
11199 stringify!(loop_)
11200 )
11201 );
11202 assert_eq!(
11203 unsafe { &(*(::std::ptr::null::<uv_signal_s>())).type_ as *const _ as usize },
11204 16usize,
11205 concat!(
11206 "Offset of field: ",
11207 stringify!(uv_signal_s),
11208 "::",
11209 stringify!(type_)
11210 )
11211 );
11212 assert_eq!(
11213 unsafe { &(*(::std::ptr::null::<uv_signal_s>())).close_cb as *const _ as usize },
11214 24usize,
11215 concat!(
11216 "Offset of field: ",
11217 stringify!(uv_signal_s),
11218 "::",
11219 stringify!(close_cb)
11220 )
11221 );
11222 assert_eq!(
11223 unsafe { &(*(::std::ptr::null::<uv_signal_s>())).handle_queue as *const _ as usize },
11224 32usize,
11225 concat!(
11226 "Offset of field: ",
11227 stringify!(uv_signal_s),
11228 "::",
11229 stringify!(handle_queue)
11230 )
11231 );
11232 assert_eq!(
11233 unsafe { &(*(::std::ptr::null::<uv_signal_s>())).u as *const _ as usize },
11234 48usize,
11235 concat!(
11236 "Offset of field: ",
11237 stringify!(uv_signal_s),
11238 "::",
11239 stringify!(u)
11240 )
11241 );
11242 assert_eq!(
11243 unsafe { &(*(::std::ptr::null::<uv_signal_s>())).next_closing as *const _ as usize },
11244 80usize,
11245 concat!(
11246 "Offset of field: ",
11247 stringify!(uv_signal_s),
11248 "::",
11249 stringify!(next_closing)
11250 )
11251 );
11252 assert_eq!(
11253 unsafe { &(*(::std::ptr::null::<uv_signal_s>())).flags as *const _ as usize },
11254 88usize,
11255 concat!(
11256 "Offset of field: ",
11257 stringify!(uv_signal_s),
11258 "::",
11259 stringify!(flags)
11260 )
11261 );
11262 assert_eq!(
11263 unsafe { &(*(::std::ptr::null::<uv_signal_s>())).signal_cb as *const _ as usize },
11264 96usize,
11265 concat!(
11266 "Offset of field: ",
11267 stringify!(uv_signal_s),
11268 "::",
11269 stringify!(signal_cb)
11270 )
11271 );
11272 assert_eq!(
11273 unsafe { &(*(::std::ptr::null::<uv_signal_s>())).signum as *const _ as usize },
11274 104usize,
11275 concat!(
11276 "Offset of field: ",
11277 stringify!(uv_signal_s),
11278 "::",
11279 stringify!(signum)
11280 )
11281 );
11282 assert_eq!(
11283 unsafe { &(*(::std::ptr::null::<uv_signal_s>())).tree_entry as *const _ as usize },
11284 112usize,
11285 concat!(
11286 "Offset of field: ",
11287 stringify!(uv_signal_s),
11288 "::",
11289 stringify!(tree_entry)
11290 )
11291 );
11292 assert_eq!(
11293 unsafe { &(*(::std::ptr::null::<uv_signal_s>())).caught_signals as *const _ as usize },
11294 144usize,
11295 concat!(
11296 "Offset of field: ",
11297 stringify!(uv_signal_s),
11298 "::",
11299 stringify!(caught_signals)
11300 )
11301 );
11302 assert_eq!(
11303 unsafe { &(*(::std::ptr::null::<uv_signal_s>())).dispatched_signals as *const _ as usize },
11304 148usize,
11305 concat!(
11306 "Offset of field: ",
11307 stringify!(uv_signal_s),
11308 "::",
11309 stringify!(dispatched_signals)
11310 )
11311 );
11312}
11313impl Default for uv_signal_s {
11314 fn default() -> Self {
11315 unsafe { ::std::mem::zeroed() }
11316 }
11317}
11318extern "C" {
11319 pub fn uv_signal_init(loop_: *mut uv_loop_t, handle: *mut uv_signal_t)
11320 -> ::std::os::raw::c_int;
11321}
11322extern "C" {
11323 pub fn uv_signal_start(
11324 handle: *mut uv_signal_t,
11325 signal_cb: uv_signal_cb,
11326 signum: ::std::os::raw::c_int,
11327 ) -> ::std::os::raw::c_int;
11328}
11329extern "C" {
11330 pub fn uv_signal_start_oneshot(
11331 handle: *mut uv_signal_t,
11332 signal_cb: uv_signal_cb,
11333 signum: ::std::os::raw::c_int,
11334 ) -> ::std::os::raw::c_int;
11335}
11336extern "C" {
11337 pub fn uv_signal_stop(handle: *mut uv_signal_t) -> ::std::os::raw::c_int;
11338}
11339extern "C" {
11340 pub fn uv_loadavg(avg: *mut f64);
11341}
11342#[repr(u32)]
11343#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
11344pub enum uv_fs_event_flags {
11345 UV_FS_EVENT_WATCH_ENTRY = 1,
11346 UV_FS_EVENT_STAT = 2,
11347 UV_FS_EVENT_RECURSIVE = 4,
11348}
11349extern "C" {
11350 pub fn uv_fs_event_init(
11351 loop_: *mut uv_loop_t,
11352 handle: *mut uv_fs_event_t,
11353 ) -> ::std::os::raw::c_int;
11354}
11355extern "C" {
11356 pub fn uv_fs_event_start(
11357 handle: *mut uv_fs_event_t,
11358 cb: uv_fs_event_cb,
11359 path: *const ::std::os::raw::c_char,
11360 flags: ::std::os::raw::c_uint,
11361 ) -> ::std::os::raw::c_int;
11362}
11363extern "C" {
11364 pub fn uv_fs_event_stop(handle: *mut uv_fs_event_t) -> ::std::os::raw::c_int;
11365}
11366extern "C" {
11367 pub fn uv_fs_event_getpath(
11368 handle: *mut uv_fs_event_t,
11369 buffer: *mut ::std::os::raw::c_char,
11370 size: *mut size_t,
11371 ) -> ::std::os::raw::c_int;
11372}
11373extern "C" {
11374 pub fn uv_ip4_addr(
11375 ip: *const ::std::os::raw::c_char,
11376 port: ::std::os::raw::c_int,
11377 addr: *mut sockaddr_in,
11378 ) -> ::std::os::raw::c_int;
11379}
11380extern "C" {
11381 pub fn uv_ip6_addr(
11382 ip: *const ::std::os::raw::c_char,
11383 port: ::std::os::raw::c_int,
11384 addr: *mut sockaddr_in6,
11385 ) -> ::std::os::raw::c_int;
11386}
11387extern "C" {
11388 pub fn uv_ip4_name(
11389 src: *const sockaddr_in,
11390 dst: *mut ::std::os::raw::c_char,
11391 size: size_t,
11392 ) -> ::std::os::raw::c_int;
11393}
11394extern "C" {
11395 pub fn uv_ip6_name(
11396 src: *const sockaddr_in6,
11397 dst: *mut ::std::os::raw::c_char,
11398 size: size_t,
11399 ) -> ::std::os::raw::c_int;
11400}
11401extern "C" {
11402 pub fn uv_inet_ntop(
11403 af: ::std::os::raw::c_int,
11404 src: *const ::std::os::raw::c_void,
11405 dst: *mut ::std::os::raw::c_char,
11406 size: size_t,
11407 ) -> ::std::os::raw::c_int;
11408}
11409extern "C" {
11410 pub fn uv_inet_pton(
11411 af: ::std::os::raw::c_int,
11412 src: *const ::std::os::raw::c_char,
11413 dst: *mut ::std::os::raw::c_void,
11414 ) -> ::std::os::raw::c_int;
11415}
11416#[repr(C)]
11417#[derive(Debug, Copy, Clone)]
11418pub struct uv_random_s {
11419 pub data: *mut ::std::os::raw::c_void,
11420 pub type_: uv_req_type,
11421 pub reserved: [*mut ::std::os::raw::c_void; 6usize],
11422 pub loop_: *mut uv_loop_t,
11423 pub status: ::std::os::raw::c_int,
11424 pub buf: *mut ::std::os::raw::c_void,
11425 pub buflen: size_t,
11426 pub cb: uv_random_cb,
11427 pub work_req: uv__work,
11428}
11429#[test]
11430fn bindgen_test_layout_uv_random_s() {
11431 assert_eq!(
11432 ::std::mem::size_of::<uv_random_s>(),
11433 144usize,
11434 concat!("Size of: ", stringify!(uv_random_s))
11435 );
11436 assert_eq!(
11437 ::std::mem::align_of::<uv_random_s>(),
11438 8usize,
11439 concat!("Alignment of ", stringify!(uv_random_s))
11440 );
11441 assert_eq!(
11442 unsafe { &(*(::std::ptr::null::<uv_random_s>())).data as *const _ as usize },
11443 0usize,
11444 concat!(
11445 "Offset of field: ",
11446 stringify!(uv_random_s),
11447 "::",
11448 stringify!(data)
11449 )
11450 );
11451 assert_eq!(
11452 unsafe { &(*(::std::ptr::null::<uv_random_s>())).type_ as *const _ as usize },
11453 8usize,
11454 concat!(
11455 "Offset of field: ",
11456 stringify!(uv_random_s),
11457 "::",
11458 stringify!(type_)
11459 )
11460 );
11461 assert_eq!(
11462 unsafe { &(*(::std::ptr::null::<uv_random_s>())).reserved as *const _ as usize },
11463 16usize,
11464 concat!(
11465 "Offset of field: ",
11466 stringify!(uv_random_s),
11467 "::",
11468 stringify!(reserved)
11469 )
11470 );
11471 assert_eq!(
11472 unsafe { &(*(::std::ptr::null::<uv_random_s>())).loop_ as *const _ as usize },
11473 64usize,
11474 concat!(
11475 "Offset of field: ",
11476 stringify!(uv_random_s),
11477 "::",
11478 stringify!(loop_)
11479 )
11480 );
11481 assert_eq!(
11482 unsafe { &(*(::std::ptr::null::<uv_random_s>())).status as *const _ as usize },
11483 72usize,
11484 concat!(
11485 "Offset of field: ",
11486 stringify!(uv_random_s),
11487 "::",
11488 stringify!(status)
11489 )
11490 );
11491 assert_eq!(
11492 unsafe { &(*(::std::ptr::null::<uv_random_s>())).buf as *const _ as usize },
11493 80usize,
11494 concat!(
11495 "Offset of field: ",
11496 stringify!(uv_random_s),
11497 "::",
11498 stringify!(buf)
11499 )
11500 );
11501 assert_eq!(
11502 unsafe { &(*(::std::ptr::null::<uv_random_s>())).buflen as *const _ as usize },
11503 88usize,
11504 concat!(
11505 "Offset of field: ",
11506 stringify!(uv_random_s),
11507 "::",
11508 stringify!(buflen)
11509 )
11510 );
11511 assert_eq!(
11512 unsafe { &(*(::std::ptr::null::<uv_random_s>())).cb as *const _ as usize },
11513 96usize,
11514 concat!(
11515 "Offset of field: ",
11516 stringify!(uv_random_s),
11517 "::",
11518 stringify!(cb)
11519 )
11520 );
11521 assert_eq!(
11522 unsafe { &(*(::std::ptr::null::<uv_random_s>())).work_req as *const _ as usize },
11523 104usize,
11524 concat!(
11525 "Offset of field: ",
11526 stringify!(uv_random_s),
11527 "::",
11528 stringify!(work_req)
11529 )
11530 );
11531}
11532impl Default for uv_random_s {
11533 fn default() -> Self {
11534 unsafe { ::std::mem::zeroed() }
11535 }
11536}
11537extern "C" {
11538 pub fn uv_random(
11539 loop_: *mut uv_loop_t,
11540 req: *mut uv_random_t,
11541 buf: *mut ::std::os::raw::c_void,
11542 buflen: size_t,
11543 flags: ::std::os::raw::c_uint,
11544 cb: uv_random_cb,
11545 ) -> ::std::os::raw::c_int;
11546}
11547extern "C" {
11548 pub fn uv_if_indextoname(
11549 ifindex: ::std::os::raw::c_uint,
11550 buffer: *mut ::std::os::raw::c_char,
11551 size: *mut size_t,
11552 ) -> ::std::os::raw::c_int;
11553}
11554extern "C" {
11555 pub fn uv_if_indextoiid(
11556 ifindex: ::std::os::raw::c_uint,
11557 buffer: *mut ::std::os::raw::c_char,
11558 size: *mut size_t,
11559 ) -> ::std::os::raw::c_int;
11560}
11561extern "C" {
11562 pub fn uv_exepath(
11563 buffer: *mut ::std::os::raw::c_char,
11564 size: *mut size_t,
11565 ) -> ::std::os::raw::c_int;
11566}
11567extern "C" {
11568 pub fn uv_cwd(buffer: *mut ::std::os::raw::c_char, size: *mut size_t) -> ::std::os::raw::c_int;
11569}
11570extern "C" {
11571 pub fn uv_chdir(dir: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int;
11572}
11573extern "C" {
11574 pub fn uv_get_free_memory() -> u64;
11575}
11576extern "C" {
11577 pub fn uv_get_total_memory() -> u64;
11578}
11579extern "C" {
11580 pub fn uv_get_constrained_memory() -> u64;
11581}
11582extern "C" {
11583 pub fn uv_hrtime() -> u64;
11584}
11585extern "C" {
11586 pub fn uv_sleep(msec: ::std::os::raw::c_uint);
11587}
11588extern "C" {
11589 pub fn uv_disable_stdio_inheritance();
11590}
11591extern "C" {
11592 pub fn uv_dlopen(
11593 filename: *const ::std::os::raw::c_char,
11594 lib: *mut uv_lib_t,
11595 ) -> ::std::os::raw::c_int;
11596}
11597extern "C" {
11598 pub fn uv_dlclose(lib: *mut uv_lib_t);
11599}
11600extern "C" {
11601 pub fn uv_dlsym(
11602 lib: *mut uv_lib_t,
11603 name: *const ::std::os::raw::c_char,
11604 ptr: *mut *mut ::std::os::raw::c_void,
11605 ) -> ::std::os::raw::c_int;
11606}
11607extern "C" {
11608 pub fn uv_dlerror(lib: *const uv_lib_t) -> *const ::std::os::raw::c_char;
11609}
11610extern "C" {
11611 pub fn uv_mutex_init(handle: *mut uv_mutex_t) -> ::std::os::raw::c_int;
11612}
11613extern "C" {
11614 pub fn uv_mutex_init_recursive(handle: *mut uv_mutex_t) -> ::std::os::raw::c_int;
11615}
11616extern "C" {
11617 pub fn uv_mutex_destroy(handle: *mut uv_mutex_t);
11618}
11619extern "C" {
11620 pub fn uv_mutex_lock(handle: *mut uv_mutex_t);
11621}
11622extern "C" {
11623 pub fn uv_mutex_trylock(handle: *mut uv_mutex_t) -> ::std::os::raw::c_int;
11624}
11625extern "C" {
11626 pub fn uv_mutex_unlock(handle: *mut uv_mutex_t);
11627}
11628extern "C" {
11629 pub fn uv_rwlock_init(rwlock: *mut uv_rwlock_t) -> ::std::os::raw::c_int;
11630}
11631extern "C" {
11632 pub fn uv_rwlock_destroy(rwlock: *mut uv_rwlock_t);
11633}
11634extern "C" {
11635 pub fn uv_rwlock_rdlock(rwlock: *mut uv_rwlock_t);
11636}
11637extern "C" {
11638 pub fn uv_rwlock_tryrdlock(rwlock: *mut uv_rwlock_t) -> ::std::os::raw::c_int;
11639}
11640extern "C" {
11641 pub fn uv_rwlock_rdunlock(rwlock: *mut uv_rwlock_t);
11642}
11643extern "C" {
11644 pub fn uv_rwlock_wrlock(rwlock: *mut uv_rwlock_t);
11645}
11646extern "C" {
11647 pub fn uv_rwlock_trywrlock(rwlock: *mut uv_rwlock_t) -> ::std::os::raw::c_int;
11648}
11649extern "C" {
11650 pub fn uv_rwlock_wrunlock(rwlock: *mut uv_rwlock_t);
11651}
11652extern "C" {
11653 pub fn uv_sem_init(sem: *mut uv_sem_t, value: ::std::os::raw::c_uint) -> ::std::os::raw::c_int;
11654}
11655extern "C" {
11656 pub fn uv_sem_destroy(sem: *mut uv_sem_t);
11657}
11658extern "C" {
11659 pub fn uv_sem_post(sem: *mut uv_sem_t);
11660}
11661extern "C" {
11662 pub fn uv_sem_wait(sem: *mut uv_sem_t);
11663}
11664extern "C" {
11665 pub fn uv_sem_trywait(sem: *mut uv_sem_t) -> ::std::os::raw::c_int;
11666}
11667extern "C" {
11668 pub fn uv_cond_init(cond: *mut uv_cond_t) -> ::std::os::raw::c_int;
11669}
11670extern "C" {
11671 pub fn uv_cond_destroy(cond: *mut uv_cond_t);
11672}
11673extern "C" {
11674 pub fn uv_cond_signal(cond: *mut uv_cond_t);
11675}
11676extern "C" {
11677 pub fn uv_cond_broadcast(cond: *mut uv_cond_t);
11678}
11679extern "C" {
11680 pub fn uv_barrier_init(
11681 barrier: *mut uv_barrier_t,
11682 count: ::std::os::raw::c_uint,
11683 ) -> ::std::os::raw::c_int;
11684}
11685extern "C" {
11686 pub fn uv_barrier_destroy(barrier: *mut uv_barrier_t);
11687}
11688extern "C" {
11689 pub fn uv_barrier_wait(barrier: *mut uv_barrier_t) -> ::std::os::raw::c_int;
11690}
11691extern "C" {
11692 pub fn uv_cond_wait(cond: *mut uv_cond_t, mutex: *mut uv_mutex_t);
11693}
11694extern "C" {
11695 pub fn uv_cond_timedwait(
11696 cond: *mut uv_cond_t,
11697 mutex: *mut uv_mutex_t,
11698 timeout: u64,
11699 ) -> ::std::os::raw::c_int;
11700}
11701extern "C" {
11702 pub fn uv_once(guard: *mut uv_once_t, callback: ::std::option::Option<unsafe extern "C" fn()>);
11703}
11704extern "C" {
11705 pub fn uv_key_create(key: *mut uv_key_t) -> ::std::os::raw::c_int;
11706}
11707extern "C" {
11708 pub fn uv_key_delete(key: *mut uv_key_t);
11709}
11710extern "C" {
11711 pub fn uv_key_get(key: *mut uv_key_t) -> *mut ::std::os::raw::c_void;
11712}
11713extern "C" {
11714 pub fn uv_key_set(key: *mut uv_key_t, value: *mut ::std::os::raw::c_void);
11715}
11716extern "C" {
11717 pub fn uv_gettimeofday(tv: *mut uv_timeval64_t) -> ::std::os::raw::c_int;
11718}
11719pub type uv_thread_cb =
11720 ::std::option::Option<unsafe extern "C" fn(arg: *mut ::std::os::raw::c_void)>;
11721extern "C" {
11722 pub fn uv_thread_create(
11723 tid: *mut uv_thread_t,
11724 entry: uv_thread_cb,
11725 arg: *mut ::std::os::raw::c_void,
11726 ) -> ::std::os::raw::c_int;
11727}
11728#[repr(u32)]
11729#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
11730pub enum uv_thread_create_flags {
11731 UV_THREAD_NO_FLAGS = 0,
11732 UV_THREAD_HAS_STACK_SIZE = 1,
11733}
11734#[repr(C)]
11735#[derive(Debug, Default, Copy, Clone)]
11736pub struct uv_thread_options_s {
11737 pub flags: ::std::os::raw::c_uint,
11738 pub stack_size: size_t,
11739}
11740#[test]
11741fn bindgen_test_layout_uv_thread_options_s() {
11742 assert_eq!(
11743 ::std::mem::size_of::<uv_thread_options_s>(),
11744 16usize,
11745 concat!("Size of: ", stringify!(uv_thread_options_s))
11746 );
11747 assert_eq!(
11748 ::std::mem::align_of::<uv_thread_options_s>(),
11749 8usize,
11750 concat!("Alignment of ", stringify!(uv_thread_options_s))
11751 );
11752 assert_eq!(
11753 unsafe { &(*(::std::ptr::null::<uv_thread_options_s>())).flags as *const _ as usize },
11754 0usize,
11755 concat!(
11756 "Offset of field: ",
11757 stringify!(uv_thread_options_s),
11758 "::",
11759 stringify!(flags)
11760 )
11761 );
11762 assert_eq!(
11763 unsafe { &(*(::std::ptr::null::<uv_thread_options_s>())).stack_size as *const _ as usize },
11764 8usize,
11765 concat!(
11766 "Offset of field: ",
11767 stringify!(uv_thread_options_s),
11768 "::",
11769 stringify!(stack_size)
11770 )
11771 );
11772}
11773pub type uv_thread_options_t = uv_thread_options_s;
11774extern "C" {
11775 pub fn uv_thread_create_ex(
11776 tid: *mut uv_thread_t,
11777 params: *const uv_thread_options_t,
11778 entry: uv_thread_cb,
11779 arg: *mut ::std::os::raw::c_void,
11780 ) -> ::std::os::raw::c_int;
11781}
11782extern "C" {
11783 pub fn uv_thread_self() -> uv_thread_t;
11784}
11785extern "C" {
11786 pub fn uv_thread_join(tid: *mut uv_thread_t) -> ::std::os::raw::c_int;
11787}
11788extern "C" {
11789 pub fn uv_thread_equal(t1: *const uv_thread_t, t2: *const uv_thread_t)
11790 -> ::std::os::raw::c_int;
11791}
11792#[repr(C)]
11793#[derive(Copy, Clone)]
11794pub union uv_any_handle {
11795 pub async_: uv_async_t,
11796 pub check: uv_check_t,
11797 pub fs_event: uv_fs_event_t,
11798 pub fs_poll: uv_fs_poll_t,
11799 pub handle: uv_handle_t,
11800 pub idle: uv_idle_t,
11801 pub pipe: uv_pipe_t,
11802 pub poll: uv_poll_t,
11803 pub prepare: uv_prepare_t,
11804 pub process: uv_process_t,
11805 pub stream: uv_stream_t,
11806 pub tcp: uv_tcp_t,
11807 pub timer: uv_timer_t,
11808 pub tty: uv_tty_t,
11809 pub udp: uv_udp_t,
11810 pub signal: uv_signal_t,
11811 _bindgen_union_align: [u64; 43usize],
11812}
11813#[test]
11814fn bindgen_test_layout_uv_any_handle() {
11815 assert_eq!(
11816 ::std::mem::size_of::<uv_any_handle>(),
11817 344usize,
11818 concat!("Size of: ", stringify!(uv_any_handle))
11819 );
11820 assert_eq!(
11821 ::std::mem::align_of::<uv_any_handle>(),
11822 8usize,
11823 concat!("Alignment of ", stringify!(uv_any_handle))
11824 );
11825 assert_eq!(
11826 unsafe { &(*(::std::ptr::null::<uv_any_handle>())).async_ as *const _ as usize },
11827 0usize,
11828 concat!(
11829 "Offset of field: ",
11830 stringify!(uv_any_handle),
11831 "::",
11832 stringify!(async_)
11833 )
11834 );
11835 assert_eq!(
11836 unsafe { &(*(::std::ptr::null::<uv_any_handle>())).check as *const _ as usize },
11837 0usize,
11838 concat!(
11839 "Offset of field: ",
11840 stringify!(uv_any_handle),
11841 "::",
11842 stringify!(check)
11843 )
11844 );
11845 assert_eq!(
11846 unsafe { &(*(::std::ptr::null::<uv_any_handle>())).fs_event as *const _ as usize },
11847 0usize,
11848 concat!(
11849 "Offset of field: ",
11850 stringify!(uv_any_handle),
11851 "::",
11852 stringify!(fs_event)
11853 )
11854 );
11855 assert_eq!(
11856 unsafe { &(*(::std::ptr::null::<uv_any_handle>())).fs_poll as *const _ as usize },
11857 0usize,
11858 concat!(
11859 "Offset of field: ",
11860 stringify!(uv_any_handle),
11861 "::",
11862 stringify!(fs_poll)
11863 )
11864 );
11865 assert_eq!(
11866 unsafe { &(*(::std::ptr::null::<uv_any_handle>())).handle as *const _ as usize },
11867 0usize,
11868 concat!(
11869 "Offset of field: ",
11870 stringify!(uv_any_handle),
11871 "::",
11872 stringify!(handle)
11873 )
11874 );
11875 assert_eq!(
11876 unsafe { &(*(::std::ptr::null::<uv_any_handle>())).idle as *const _ as usize },
11877 0usize,
11878 concat!(
11879 "Offset of field: ",
11880 stringify!(uv_any_handle),
11881 "::",
11882 stringify!(idle)
11883 )
11884 );
11885 assert_eq!(
11886 unsafe { &(*(::std::ptr::null::<uv_any_handle>())).pipe as *const _ as usize },
11887 0usize,
11888 concat!(
11889 "Offset of field: ",
11890 stringify!(uv_any_handle),
11891 "::",
11892 stringify!(pipe)
11893 )
11894 );
11895 assert_eq!(
11896 unsafe { &(*(::std::ptr::null::<uv_any_handle>())).poll as *const _ as usize },
11897 0usize,
11898 concat!(
11899 "Offset of field: ",
11900 stringify!(uv_any_handle),
11901 "::",
11902 stringify!(poll)
11903 )
11904 );
11905 assert_eq!(
11906 unsafe { &(*(::std::ptr::null::<uv_any_handle>())).prepare as *const _ as usize },
11907 0usize,
11908 concat!(
11909 "Offset of field: ",
11910 stringify!(uv_any_handle),
11911 "::",
11912 stringify!(prepare)
11913 )
11914 );
11915 assert_eq!(
11916 unsafe { &(*(::std::ptr::null::<uv_any_handle>())).process as *const _ as usize },
11917 0usize,
11918 concat!(
11919 "Offset of field: ",
11920 stringify!(uv_any_handle),
11921 "::",
11922 stringify!(process)
11923 )
11924 );
11925 assert_eq!(
11926 unsafe { &(*(::std::ptr::null::<uv_any_handle>())).stream as *const _ as usize },
11927 0usize,
11928 concat!(
11929 "Offset of field: ",
11930 stringify!(uv_any_handle),
11931 "::",
11932 stringify!(stream)
11933 )
11934 );
11935 assert_eq!(
11936 unsafe { &(*(::std::ptr::null::<uv_any_handle>())).tcp as *const _ as usize },
11937 0usize,
11938 concat!(
11939 "Offset of field: ",
11940 stringify!(uv_any_handle),
11941 "::",
11942 stringify!(tcp)
11943 )
11944 );
11945 assert_eq!(
11946 unsafe { &(*(::std::ptr::null::<uv_any_handle>())).timer as *const _ as usize },
11947 0usize,
11948 concat!(
11949 "Offset of field: ",
11950 stringify!(uv_any_handle),
11951 "::",
11952 stringify!(timer)
11953 )
11954 );
11955 assert_eq!(
11956 unsafe { &(*(::std::ptr::null::<uv_any_handle>())).tty as *const _ as usize },
11957 0usize,
11958 concat!(
11959 "Offset of field: ",
11960 stringify!(uv_any_handle),
11961 "::",
11962 stringify!(tty)
11963 )
11964 );
11965 assert_eq!(
11966 unsafe { &(*(::std::ptr::null::<uv_any_handle>())).udp as *const _ as usize },
11967 0usize,
11968 concat!(
11969 "Offset of field: ",
11970 stringify!(uv_any_handle),
11971 "::",
11972 stringify!(udp)
11973 )
11974 );
11975 assert_eq!(
11976 unsafe { &(*(::std::ptr::null::<uv_any_handle>())).signal as *const _ as usize },
11977 0usize,
11978 concat!(
11979 "Offset of field: ",
11980 stringify!(uv_any_handle),
11981 "::",
11982 stringify!(signal)
11983 )
11984 );
11985}
11986impl Default for uv_any_handle {
11987 fn default() -> Self {
11988 unsafe { ::std::mem::zeroed() }
11989 }
11990}
11991#[repr(C)]
11992#[derive(Copy, Clone)]
11993pub union uv_any_req {
11994 pub req: uv_req_t,
11995 pub connect: uv_connect_t,
11996 pub write: uv_write_t,
11997 pub shutdown: uv_shutdown_t,
11998 pub udp_send: uv_udp_send_t,
11999 pub fs: uv_fs_t,
12000 pub work: uv_work_t,
12001 pub getaddrinfo: uv_getaddrinfo_t,
12002 pub getnameinfo: uv_getnameinfo_t,
12003 pub random: uv_random_t,
12004 _bindgen_union_align: [u64; 165usize],
12005}
12006#[test]
12007fn bindgen_test_layout_uv_any_req() {
12008 assert_eq!(
12009 ::std::mem::size_of::<uv_any_req>(),
12010 1320usize,
12011 concat!("Size of: ", stringify!(uv_any_req))
12012 );
12013 assert_eq!(
12014 ::std::mem::align_of::<uv_any_req>(),
12015 8usize,
12016 concat!("Alignment of ", stringify!(uv_any_req))
12017 );
12018 assert_eq!(
12019 unsafe { &(*(::std::ptr::null::<uv_any_req>())).req as *const _ as usize },
12020 0usize,
12021 concat!(
12022 "Offset of field: ",
12023 stringify!(uv_any_req),
12024 "::",
12025 stringify!(req)
12026 )
12027 );
12028 assert_eq!(
12029 unsafe { &(*(::std::ptr::null::<uv_any_req>())).connect as *const _ as usize },
12030 0usize,
12031 concat!(
12032 "Offset of field: ",
12033 stringify!(uv_any_req),
12034 "::",
12035 stringify!(connect)
12036 )
12037 );
12038 assert_eq!(
12039 unsafe { &(*(::std::ptr::null::<uv_any_req>())).write as *const _ as usize },
12040 0usize,
12041 concat!(
12042 "Offset of field: ",
12043 stringify!(uv_any_req),
12044 "::",
12045 stringify!(write)
12046 )
12047 );
12048 assert_eq!(
12049 unsafe { &(*(::std::ptr::null::<uv_any_req>())).shutdown as *const _ as usize },
12050 0usize,
12051 concat!(
12052 "Offset of field: ",
12053 stringify!(uv_any_req),
12054 "::",
12055 stringify!(shutdown)
12056 )
12057 );
12058 assert_eq!(
12059 unsafe { &(*(::std::ptr::null::<uv_any_req>())).udp_send as *const _ as usize },
12060 0usize,
12061 concat!(
12062 "Offset of field: ",
12063 stringify!(uv_any_req),
12064 "::",
12065 stringify!(udp_send)
12066 )
12067 );
12068 assert_eq!(
12069 unsafe { &(*(::std::ptr::null::<uv_any_req>())).fs as *const _ as usize },
12070 0usize,
12071 concat!(
12072 "Offset of field: ",
12073 stringify!(uv_any_req),
12074 "::",
12075 stringify!(fs)
12076 )
12077 );
12078 assert_eq!(
12079 unsafe { &(*(::std::ptr::null::<uv_any_req>())).work as *const _ as usize },
12080 0usize,
12081 concat!(
12082 "Offset of field: ",
12083 stringify!(uv_any_req),
12084 "::",
12085 stringify!(work)
12086 )
12087 );
12088 assert_eq!(
12089 unsafe { &(*(::std::ptr::null::<uv_any_req>())).getaddrinfo as *const _ as usize },
12090 0usize,
12091 concat!(
12092 "Offset of field: ",
12093 stringify!(uv_any_req),
12094 "::",
12095 stringify!(getaddrinfo)
12096 )
12097 );
12098 assert_eq!(
12099 unsafe { &(*(::std::ptr::null::<uv_any_req>())).getnameinfo as *const _ as usize },
12100 0usize,
12101 concat!(
12102 "Offset of field: ",
12103 stringify!(uv_any_req),
12104 "::",
12105 stringify!(getnameinfo)
12106 )
12107 );
12108 assert_eq!(
12109 unsafe { &(*(::std::ptr::null::<uv_any_req>())).random as *const _ as usize },
12110 0usize,
12111 concat!(
12112 "Offset of field: ",
12113 stringify!(uv_any_req),
12114 "::",
12115 stringify!(random)
12116 )
12117 );
12118}
12119impl Default for uv_any_req {
12120 fn default() -> Self {
12121 unsafe { ::std::mem::zeroed() }
12122 }
12123}
12124#[repr(C)]
12125#[derive(Copy, Clone)]
12126pub struct uv_loop_s {
12127 pub data: *mut ::std::os::raw::c_void,
12128 pub active_handles: ::std::os::raw::c_uint,
12129 pub handle_queue: [*mut ::std::os::raw::c_void; 2usize],
12130 pub active_reqs: uv_loop_s__bindgen_ty_1,
12131 pub internal_fields: *mut ::std::os::raw::c_void,
12132 pub stop_flag: ::std::os::raw::c_uint,
12133 pub flags: ::std::os::raw::c_ulong,
12134 pub backend_fd: ::std::os::raw::c_int,
12135 pub pending_queue: [*mut ::std::os::raw::c_void; 2usize],
12136 pub watcher_queue: [*mut ::std::os::raw::c_void; 2usize],
12137 pub watchers: *mut *mut uv__io_t,
12138 pub nwatchers: ::std::os::raw::c_uint,
12139 pub nfds: ::std::os::raw::c_uint,
12140 pub wq: [*mut ::std::os::raw::c_void; 2usize],
12141 pub wq_mutex: uv_mutex_t,
12142 pub wq_async: uv_async_t,
12143 pub cloexec_lock: uv_rwlock_t,
12144 pub closing_handles: *mut uv_handle_t,
12145 pub process_handles: [*mut ::std::os::raw::c_void; 2usize],
12146 pub prepare_handles: [*mut ::std::os::raw::c_void; 2usize],
12147 pub check_handles: [*mut ::std::os::raw::c_void; 2usize],
12148 pub idle_handles: [*mut ::std::os::raw::c_void; 2usize],
12149 pub async_handles: [*mut ::std::os::raw::c_void; 2usize],
12150 pub async_unused: ::std::option::Option<unsafe extern "C" fn()>,
12151 pub async_io_watcher: uv__io_t,
12152 pub async_wfd: ::std::os::raw::c_int,
12153 pub timer_heap: uv_loop_s__bindgen_ty_2,
12154 pub timer_counter: u64,
12155 pub time: u64,
12156 pub signal_pipefd: [::std::os::raw::c_int; 2usize],
12157 pub signal_io_watcher: uv__io_t,
12158 pub child_watcher: uv_signal_t,
12159 pub emfile_fd: ::std::os::raw::c_int,
12160 pub cf_thread: uv_thread_t,
12161 pub _cf_reserved: *mut ::std::os::raw::c_void,
12162 pub cf_state: *mut ::std::os::raw::c_void,
12163 pub cf_mutex: uv_mutex_t,
12164 pub cf_sem: uv_sem_t,
12165 pub cf_signals: [*mut ::std::os::raw::c_void; 2usize],
12166}
12167#[repr(C)]
12168#[derive(Copy, Clone)]
12169pub union uv_loop_s__bindgen_ty_1 {
12170 pub unused: *mut ::std::os::raw::c_void,
12171 pub count: ::std::os::raw::c_uint,
12172 _bindgen_union_align: u64,
12173}
12174#[test]
12175fn bindgen_test_layout_uv_loop_s__bindgen_ty_1() {
12176 assert_eq!(
12177 ::std::mem::size_of::<uv_loop_s__bindgen_ty_1>(),
12178 8usize,
12179 concat!("Size of: ", stringify!(uv_loop_s__bindgen_ty_1))
12180 );
12181 assert_eq!(
12182 ::std::mem::align_of::<uv_loop_s__bindgen_ty_1>(),
12183 8usize,
12184 concat!("Alignment of ", stringify!(uv_loop_s__bindgen_ty_1))
12185 );
12186 assert_eq!(
12187 unsafe { &(*(::std::ptr::null::<uv_loop_s__bindgen_ty_1>())).unused as *const _ as usize },
12188 0usize,
12189 concat!(
12190 "Offset of field: ",
12191 stringify!(uv_loop_s__bindgen_ty_1),
12192 "::",
12193 stringify!(unused)
12194 )
12195 );
12196 assert_eq!(
12197 unsafe { &(*(::std::ptr::null::<uv_loop_s__bindgen_ty_1>())).count as *const _ as usize },
12198 0usize,
12199 concat!(
12200 "Offset of field: ",
12201 stringify!(uv_loop_s__bindgen_ty_1),
12202 "::",
12203 stringify!(count)
12204 )
12205 );
12206}
12207impl Default for uv_loop_s__bindgen_ty_1 {
12208 fn default() -> Self {
12209 unsafe { ::std::mem::zeroed() }
12210 }
12211}
12212#[repr(C)]
12213#[derive(Debug, Copy, Clone)]
12214pub struct uv_loop_s__bindgen_ty_2 {
12215 pub min: *mut ::std::os::raw::c_void,
12216 pub nelts: ::std::os::raw::c_uint,
12217}
12218#[test]
12219fn bindgen_test_layout_uv_loop_s__bindgen_ty_2() {
12220 assert_eq!(
12221 ::std::mem::size_of::<uv_loop_s__bindgen_ty_2>(),
12222 16usize,
12223 concat!("Size of: ", stringify!(uv_loop_s__bindgen_ty_2))
12224 );
12225 assert_eq!(
12226 ::std::mem::align_of::<uv_loop_s__bindgen_ty_2>(),
12227 8usize,
12228 concat!("Alignment of ", stringify!(uv_loop_s__bindgen_ty_2))
12229 );
12230 assert_eq!(
12231 unsafe { &(*(::std::ptr::null::<uv_loop_s__bindgen_ty_2>())).min as *const _ as usize },
12232 0usize,
12233 concat!(
12234 "Offset of field: ",
12235 stringify!(uv_loop_s__bindgen_ty_2),
12236 "::",
12237 stringify!(min)
12238 )
12239 );
12240 assert_eq!(
12241 unsafe { &(*(::std::ptr::null::<uv_loop_s__bindgen_ty_2>())).nelts as *const _ as usize },
12242 8usize,
12243 concat!(
12244 "Offset of field: ",
12245 stringify!(uv_loop_s__bindgen_ty_2),
12246 "::",
12247 stringify!(nelts)
12248 )
12249 );
12250}
12251impl Default for uv_loop_s__bindgen_ty_2 {
12252 fn default() -> Self {
12253 unsafe { ::std::mem::zeroed() }
12254 }
12255}
12256#[test]
12257fn bindgen_test_layout_uv_loop_s() {
12258 assert_eq!(
12259 ::std::mem::size_of::<uv_loop_s>(),
12260 1072usize,
12261 concat!("Size of: ", stringify!(uv_loop_s))
12262 );
12263 assert_eq!(
12264 ::std::mem::align_of::<uv_loop_s>(),
12265 8usize,
12266 concat!("Alignment of ", stringify!(uv_loop_s))
12267 );
12268 assert_eq!(
12269 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).data as *const _ as usize },
12270 0usize,
12271 concat!(
12272 "Offset of field: ",
12273 stringify!(uv_loop_s),
12274 "::",
12275 stringify!(data)
12276 )
12277 );
12278 assert_eq!(
12279 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).active_handles as *const _ as usize },
12280 8usize,
12281 concat!(
12282 "Offset of field: ",
12283 stringify!(uv_loop_s),
12284 "::",
12285 stringify!(active_handles)
12286 )
12287 );
12288 assert_eq!(
12289 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).handle_queue as *const _ as usize },
12290 16usize,
12291 concat!(
12292 "Offset of field: ",
12293 stringify!(uv_loop_s),
12294 "::",
12295 stringify!(handle_queue)
12296 )
12297 );
12298 assert_eq!(
12299 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).active_reqs as *const _ as usize },
12300 32usize,
12301 concat!(
12302 "Offset of field: ",
12303 stringify!(uv_loop_s),
12304 "::",
12305 stringify!(active_reqs)
12306 )
12307 );
12308 assert_eq!(
12309 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).internal_fields as *const _ as usize },
12310 40usize,
12311 concat!(
12312 "Offset of field: ",
12313 stringify!(uv_loop_s),
12314 "::",
12315 stringify!(internal_fields)
12316 )
12317 );
12318 assert_eq!(
12319 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).stop_flag as *const _ as usize },
12320 48usize,
12321 concat!(
12322 "Offset of field: ",
12323 stringify!(uv_loop_s),
12324 "::",
12325 stringify!(stop_flag)
12326 )
12327 );
12328 assert_eq!(
12329 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).flags as *const _ as usize },
12330 56usize,
12331 concat!(
12332 "Offset of field: ",
12333 stringify!(uv_loop_s),
12334 "::",
12335 stringify!(flags)
12336 )
12337 );
12338 assert_eq!(
12339 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).backend_fd as *const _ as usize },
12340 64usize,
12341 concat!(
12342 "Offset of field: ",
12343 stringify!(uv_loop_s),
12344 "::",
12345 stringify!(backend_fd)
12346 )
12347 );
12348 assert_eq!(
12349 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).pending_queue as *const _ as usize },
12350 72usize,
12351 concat!(
12352 "Offset of field: ",
12353 stringify!(uv_loop_s),
12354 "::",
12355 stringify!(pending_queue)
12356 )
12357 );
12358 assert_eq!(
12359 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).watcher_queue as *const _ as usize },
12360 88usize,
12361 concat!(
12362 "Offset of field: ",
12363 stringify!(uv_loop_s),
12364 "::",
12365 stringify!(watcher_queue)
12366 )
12367 );
12368 assert_eq!(
12369 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).watchers as *const _ as usize },
12370 104usize,
12371 concat!(
12372 "Offset of field: ",
12373 stringify!(uv_loop_s),
12374 "::",
12375 stringify!(watchers)
12376 )
12377 );
12378 assert_eq!(
12379 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).nwatchers as *const _ as usize },
12380 112usize,
12381 concat!(
12382 "Offset of field: ",
12383 stringify!(uv_loop_s),
12384 "::",
12385 stringify!(nwatchers)
12386 )
12387 );
12388 assert_eq!(
12389 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).nfds as *const _ as usize },
12390 116usize,
12391 concat!(
12392 "Offset of field: ",
12393 stringify!(uv_loop_s),
12394 "::",
12395 stringify!(nfds)
12396 )
12397 );
12398 assert_eq!(
12399 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).wq as *const _ as usize },
12400 120usize,
12401 concat!(
12402 "Offset of field: ",
12403 stringify!(uv_loop_s),
12404 "::",
12405 stringify!(wq)
12406 )
12407 );
12408 assert_eq!(
12409 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).wq_mutex as *const _ as usize },
12410 136usize,
12411 concat!(
12412 "Offset of field: ",
12413 stringify!(uv_loop_s),
12414 "::",
12415 stringify!(wq_mutex)
12416 )
12417 );
12418 assert_eq!(
12419 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).wq_async as *const _ as usize },
12420 200usize,
12421 concat!(
12422 "Offset of field: ",
12423 stringify!(uv_loop_s),
12424 "::",
12425 stringify!(wq_async)
12426 )
12427 );
12428 assert_eq!(
12429 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).cloexec_lock as *const _ as usize },
12430 328usize,
12431 concat!(
12432 "Offset of field: ",
12433 stringify!(uv_loop_s),
12434 "::",
12435 stringify!(cloexec_lock)
12436 )
12437 );
12438 assert_eq!(
12439 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).closing_handles as *const _ as usize },
12440 528usize,
12441 concat!(
12442 "Offset of field: ",
12443 stringify!(uv_loop_s),
12444 "::",
12445 stringify!(closing_handles)
12446 )
12447 );
12448 assert_eq!(
12449 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).process_handles as *const _ as usize },
12450 536usize,
12451 concat!(
12452 "Offset of field: ",
12453 stringify!(uv_loop_s),
12454 "::",
12455 stringify!(process_handles)
12456 )
12457 );
12458 assert_eq!(
12459 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).prepare_handles as *const _ as usize },
12460 552usize,
12461 concat!(
12462 "Offset of field: ",
12463 stringify!(uv_loop_s),
12464 "::",
12465 stringify!(prepare_handles)
12466 )
12467 );
12468 assert_eq!(
12469 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).check_handles as *const _ as usize },
12470 568usize,
12471 concat!(
12472 "Offset of field: ",
12473 stringify!(uv_loop_s),
12474 "::",
12475 stringify!(check_handles)
12476 )
12477 );
12478 assert_eq!(
12479 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).idle_handles as *const _ as usize },
12480 584usize,
12481 concat!(
12482 "Offset of field: ",
12483 stringify!(uv_loop_s),
12484 "::",
12485 stringify!(idle_handles)
12486 )
12487 );
12488 assert_eq!(
12489 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).async_handles as *const _ as usize },
12490 600usize,
12491 concat!(
12492 "Offset of field: ",
12493 stringify!(uv_loop_s),
12494 "::",
12495 stringify!(async_handles)
12496 )
12497 );
12498 assert_eq!(
12499 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).async_unused as *const _ as usize },
12500 616usize,
12501 concat!(
12502 "Offset of field: ",
12503 stringify!(uv_loop_s),
12504 "::",
12505 stringify!(async_unused)
12506 )
12507 );
12508 assert_eq!(
12509 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).async_io_watcher as *const _ as usize },
12510 624usize,
12511 concat!(
12512 "Offset of field: ",
12513 stringify!(uv_loop_s),
12514 "::",
12515 stringify!(async_io_watcher)
12516 )
12517 );
12518 assert_eq!(
12519 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).async_wfd as *const _ as usize },
12520 688usize,
12521 concat!(
12522 "Offset of field: ",
12523 stringify!(uv_loop_s),
12524 "::",
12525 stringify!(async_wfd)
12526 )
12527 );
12528 assert_eq!(
12529 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).timer_heap as *const _ as usize },
12530 696usize,
12531 concat!(
12532 "Offset of field: ",
12533 stringify!(uv_loop_s),
12534 "::",
12535 stringify!(timer_heap)
12536 )
12537 );
12538 assert_eq!(
12539 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).timer_counter as *const _ as usize },
12540 712usize,
12541 concat!(
12542 "Offset of field: ",
12543 stringify!(uv_loop_s),
12544 "::",
12545 stringify!(timer_counter)
12546 )
12547 );
12548 assert_eq!(
12549 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).time as *const _ as usize },
12550 720usize,
12551 concat!(
12552 "Offset of field: ",
12553 stringify!(uv_loop_s),
12554 "::",
12555 stringify!(time)
12556 )
12557 );
12558 assert_eq!(
12559 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).signal_pipefd as *const _ as usize },
12560 728usize,
12561 concat!(
12562 "Offset of field: ",
12563 stringify!(uv_loop_s),
12564 "::",
12565 stringify!(signal_pipefd)
12566 )
12567 );
12568 assert_eq!(
12569 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).signal_io_watcher as *const _ as usize },
12570 736usize,
12571 concat!(
12572 "Offset of field: ",
12573 stringify!(uv_loop_s),
12574 "::",
12575 stringify!(signal_io_watcher)
12576 )
12577 );
12578 assert_eq!(
12579 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).child_watcher as *const _ as usize },
12580 800usize,
12581 concat!(
12582 "Offset of field: ",
12583 stringify!(uv_loop_s),
12584 "::",
12585 stringify!(child_watcher)
12586 )
12587 );
12588 assert_eq!(
12589 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).emfile_fd as *const _ as usize },
12590 952usize,
12591 concat!(
12592 "Offset of field: ",
12593 stringify!(uv_loop_s),
12594 "::",
12595 stringify!(emfile_fd)
12596 )
12597 );
12598 assert_eq!(
12599 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).cf_thread as *const _ as usize },
12600 960usize,
12601 concat!(
12602 "Offset of field: ",
12603 stringify!(uv_loop_s),
12604 "::",
12605 stringify!(cf_thread)
12606 )
12607 );
12608 assert_eq!(
12609 unsafe { &(*(::std::ptr::null::<uv_loop_s>()))._cf_reserved as *const _ as usize },
12610 968usize,
12611 concat!(
12612 "Offset of field: ",
12613 stringify!(uv_loop_s),
12614 "::",
12615 stringify!(_cf_reserved)
12616 )
12617 );
12618 assert_eq!(
12619 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).cf_state as *const _ as usize },
12620 976usize,
12621 concat!(
12622 "Offset of field: ",
12623 stringify!(uv_loop_s),
12624 "::",
12625 stringify!(cf_state)
12626 )
12627 );
12628 assert_eq!(
12629 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).cf_mutex as *const _ as usize },
12630 984usize,
12631 concat!(
12632 "Offset of field: ",
12633 stringify!(uv_loop_s),
12634 "::",
12635 stringify!(cf_mutex)
12636 )
12637 );
12638 assert_eq!(
12639 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).cf_sem as *const _ as usize },
12640 1048usize,
12641 concat!(
12642 "Offset of field: ",
12643 stringify!(uv_loop_s),
12644 "::",
12645 stringify!(cf_sem)
12646 )
12647 );
12648 assert_eq!(
12649 unsafe { &(*(::std::ptr::null::<uv_loop_s>())).cf_signals as *const _ as usize },
12650 1056usize,
12651 concat!(
12652 "Offset of field: ",
12653 stringify!(uv_loop_s),
12654 "::",
12655 stringify!(cf_signals)
12656 )
12657 );
12658}
12659impl Default for uv_loop_s {
12660 fn default() -> Self {
12661 unsafe { ::std::mem::zeroed() }
12662 }
12663}
12664extern "C" {
12665 pub fn uv_loop_get_data(arg1: *const uv_loop_t) -> *mut ::std::os::raw::c_void;
12666}
12667extern "C" {
12668 pub fn uv_loop_set_data(arg1: *mut uv_loop_t, data: *mut ::std::os::raw::c_void);
12669}