1#![allow(non_upper_case_globals)]
2#![allow(non_camel_case_types)]
3#![allow(non_snake_case)]
4#[repr(C)]
7#[derive(Copy, Clone, Debug, Default, Eq, Hash, Ord, PartialEq, PartialOrd)]
8pub struct __BindgenBitfieldUnit<Storage, Align>
9where
10 Storage: AsRef<[u8]> + AsMut<[u8]>,
11{
12 storage: Storage,
13 align: [Align; 0],
14}
15
16impl<Storage, Align> __BindgenBitfieldUnit<Storage, Align>
17where
18 Storage: AsRef<[u8]> + AsMut<[u8]>,
19{
20 #[inline]
21 pub fn new(storage: Storage) -> Self {
22 Self { storage, align: [] }
23 }
24
25 #[inline]
26 pub fn get_bit(&self, index: usize) -> bool {
27 debug_assert!(index / 8 < self.storage.as_ref().len());
28
29 let byte_index = index / 8;
30 let byte = self.storage.as_ref()[byte_index];
31
32 let bit_index = index % 8;
33 let mask = 1 << bit_index;
34
35 byte & mask == mask
36 }
37
38 #[inline]
39 pub fn set_bit(&mut self, index: usize, val: bool) {
40 debug_assert!(index / 8 < self.storage.as_ref().len());
41
42 let byte_index = index / 8;
43 let byte = &mut self.storage.as_mut()[byte_index];
44
45 let bit_index = index % 8;
46 let mask = 1 << bit_index;
47
48 if val {
49 *byte |= mask;
50 } else {
51 *byte &= !mask;
52 }
53 }
54
55 #[inline]
56 pub fn get(&self, bit_offset: usize, bit_width: u8) -> u64 {
57 debug_assert!(bit_width <= 64);
58 debug_assert!(bit_offset / 8 < self.storage.as_ref().len());
59 debug_assert!((bit_offset + (bit_width as usize)) / 8 <= self.storage.as_ref().len());
60
61 let mut val = 0;
62
63 for i in 0..(bit_width as usize) {
64 if self.get_bit(i + bit_offset) {
65 val |= 1 << i;
66 }
67 }
68
69 val
70 }
71
72 #[inline]
73 pub fn set(&mut self, bit_offset: usize, bit_width: u8, val: u64) {
74 debug_assert!(bit_width <= 64);
75 debug_assert!(bit_offset / 8 < self.storage.as_ref().len());
76 debug_assert!((bit_offset + (bit_width as usize)) / 8 <= self.storage.as_ref().len());
77
78 for i in 0..(bit_width as usize) {
79 let mask = 1 << i;
80 let val_bit_is_set = val & mask == mask;
81 self.set_bit(i + bit_offset, val_bit_is_set);
82 }
83 }
84}
85#[repr(C)]
86#[derive(Debug, Copy, Clone)]
87pub struct __sigset_t {
88 pub __val: [usize; 16usize],
89}
90#[test]
91fn bindgen_test_layout___sigset_t() {
92 assert_eq!(
93 ::std::mem::size_of::<__sigset_t>(),
94 128usize,
95 concat!("Size of: ", stringify!(__sigset_t))
96 );
97 assert_eq!(
98 ::std::mem::align_of::<__sigset_t>(),
99 8usize,
100 concat!("Alignment of ", stringify!(__sigset_t))
101 );
102 assert_eq!(
103 unsafe { &(*(::std::ptr::null::<__sigset_t>())).__val as *const _ as usize },
104 0usize,
105 concat!(
106 "Offset of field: ",
107 stringify!(__sigset_t),
108 "::",
109 stringify!(__val)
110 )
111 );
112}
113pub type pthread_t = usize;
114#[repr(C)]
115#[derive(Debug, Copy, Clone)]
116pub struct __pthread_internal_list {
117 pub __prev: *mut __pthread_internal_list,
118 pub __next: *mut __pthread_internal_list,
119}
120#[test]
121fn bindgen_test_layout___pthread_internal_list() {
122 assert_eq!(
123 ::std::mem::size_of::<__pthread_internal_list>(),
124 16usize,
125 concat!("Size of: ", stringify!(__pthread_internal_list))
126 );
127 assert_eq!(
128 ::std::mem::align_of::<__pthread_internal_list>(),
129 8usize,
130 concat!("Alignment of ", stringify!(__pthread_internal_list))
131 );
132 assert_eq!(
133 unsafe { &(*(::std::ptr::null::<__pthread_internal_list>())).__prev as *const _ as usize },
134 0usize,
135 concat!(
136 "Offset of field: ",
137 stringify!(__pthread_internal_list),
138 "::",
139 stringify!(__prev)
140 )
141 );
142 assert_eq!(
143 unsafe { &(*(::std::ptr::null::<__pthread_internal_list>())).__next as *const _ as usize },
144 8usize,
145 concat!(
146 "Offset of field: ",
147 stringify!(__pthread_internal_list),
148 "::",
149 stringify!(__next)
150 )
151 );
152}
153pub type __pthread_list_t = __pthread_internal_list;
154#[repr(C)]
155#[derive(Copy, Clone)]
156pub union pthread_mutex_t {
157 pub __data: pthread_mutex_t___pthread_mutex_s,
158 pub __size: [::std::os::raw::c_char; 40usize],
159 pub __align: ::std::os::raw::c_long,
160 _bindgen_union_align: [u64; 5usize],
161}
162#[repr(C)]
163#[derive(Debug, Copy, Clone)]
164pub struct pthread_mutex_t___pthread_mutex_s {
165 pub __lock: ::std::os::raw::c_int,
166 pub __count: ::std::os::raw::c_uint,
167 pub __owner: ::std::os::raw::c_int,
168 pub __nusers: ::std::os::raw::c_uint,
169 pub __kind: ::std::os::raw::c_int,
170 pub __spins: ::std::os::raw::c_short,
171 pub __elision: ::std::os::raw::c_short,
172 pub __list: __pthread_list_t,
173}
174#[test]
175fn bindgen_test_layout_pthread_mutex_t___pthread_mutex_s() {
176 assert_eq!(
177 ::std::mem::size_of::<pthread_mutex_t___pthread_mutex_s>(),
178 40usize,
179 concat!("Size of: ", stringify!(pthread_mutex_t___pthread_mutex_s))
180 );
181 assert_eq!(
182 ::std::mem::align_of::<pthread_mutex_t___pthread_mutex_s>(),
183 8usize,
184 concat!(
185 "Alignment of ",
186 stringify!(pthread_mutex_t___pthread_mutex_s)
187 )
188 );
189 assert_eq!(
190 unsafe {
191 &(*(::std::ptr::null::<pthread_mutex_t___pthread_mutex_s>())).__lock as *const _
192 as usize
193 },
194 0usize,
195 concat!(
196 "Offset of field: ",
197 stringify!(pthread_mutex_t___pthread_mutex_s),
198 "::",
199 stringify!(__lock)
200 )
201 );
202 assert_eq!(
203 unsafe {
204 &(*(::std::ptr::null::<pthread_mutex_t___pthread_mutex_s>())).__count as *const _
205 as usize
206 },
207 4usize,
208 concat!(
209 "Offset of field: ",
210 stringify!(pthread_mutex_t___pthread_mutex_s),
211 "::",
212 stringify!(__count)
213 )
214 );
215 assert_eq!(
216 unsafe {
217 &(*(::std::ptr::null::<pthread_mutex_t___pthread_mutex_s>())).__owner as *const _
218 as usize
219 },
220 8usize,
221 concat!(
222 "Offset of field: ",
223 stringify!(pthread_mutex_t___pthread_mutex_s),
224 "::",
225 stringify!(__owner)
226 )
227 );
228 assert_eq!(
229 unsafe {
230 &(*(::std::ptr::null::<pthread_mutex_t___pthread_mutex_s>())).__nusers as *const _
231 as usize
232 },
233 12usize,
234 concat!(
235 "Offset of field: ",
236 stringify!(pthread_mutex_t___pthread_mutex_s),
237 "::",
238 stringify!(__nusers)
239 )
240 );
241 assert_eq!(
242 unsafe {
243 &(*(::std::ptr::null::<pthread_mutex_t___pthread_mutex_s>())).__kind as *const _
244 as usize
245 },
246 16usize,
247 concat!(
248 "Offset of field: ",
249 stringify!(pthread_mutex_t___pthread_mutex_s),
250 "::",
251 stringify!(__kind)
252 )
253 );
254 assert_eq!(
255 unsafe {
256 &(*(::std::ptr::null::<pthread_mutex_t___pthread_mutex_s>())).__spins as *const _
257 as usize
258 },
259 20usize,
260 concat!(
261 "Offset of field: ",
262 stringify!(pthread_mutex_t___pthread_mutex_s),
263 "::",
264 stringify!(__spins)
265 )
266 );
267 assert_eq!(
268 unsafe {
269 &(*(::std::ptr::null::<pthread_mutex_t___pthread_mutex_s>())).__elision as *const _
270 as usize
271 },
272 22usize,
273 concat!(
274 "Offset of field: ",
275 stringify!(pthread_mutex_t___pthread_mutex_s),
276 "::",
277 stringify!(__elision)
278 )
279 );
280 assert_eq!(
281 unsafe {
282 &(*(::std::ptr::null::<pthread_mutex_t___pthread_mutex_s>())).__list as *const _
283 as usize
284 },
285 24usize,
286 concat!(
287 "Offset of field: ",
288 stringify!(pthread_mutex_t___pthread_mutex_s),
289 "::",
290 stringify!(__list)
291 )
292 );
293}
294#[test]
295fn bindgen_test_layout_pthread_mutex_t() {
296 assert_eq!(
297 ::std::mem::size_of::<pthread_mutex_t>(),
298 40usize,
299 concat!("Size of: ", stringify!(pthread_mutex_t))
300 );
301 assert_eq!(
302 ::std::mem::align_of::<pthread_mutex_t>(),
303 8usize,
304 concat!("Alignment of ", stringify!(pthread_mutex_t))
305 );
306 assert_eq!(
307 unsafe { &(*(::std::ptr::null::<pthread_mutex_t>())).__data as *const _ as usize },
308 0usize,
309 concat!(
310 "Offset of field: ",
311 stringify!(pthread_mutex_t),
312 "::",
313 stringify!(__data)
314 )
315 );
316 assert_eq!(
317 unsafe { &(*(::std::ptr::null::<pthread_mutex_t>())).__size as *const _ as usize },
318 0usize,
319 concat!(
320 "Offset of field: ",
321 stringify!(pthread_mutex_t),
322 "::",
323 stringify!(__size)
324 )
325 );
326 assert_eq!(
327 unsafe { &(*(::std::ptr::null::<pthread_mutex_t>())).__align as *const _ as usize },
328 0usize,
329 concat!(
330 "Offset of field: ",
331 stringify!(pthread_mutex_t),
332 "::",
333 stringify!(__align)
334 )
335 );
336}
337impl ::std::fmt::Debug for pthread_mutex_t {
338 fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
339 write!(f, "pthread_mutex_t {{ union }}")
340 }
341}
342#[repr(C)]
343#[derive(Copy, Clone)]
344pub union pthread_cond_t {
345 pub __data: pthread_cond_t__bindgen_ty_1,
346 pub __size: [::std::os::raw::c_char; 48usize],
347 pub __align: ::std::os::raw::c_longlong,
348 _bindgen_union_align: [u64; 6usize],
349}
350#[repr(C)]
351#[derive(Debug, Copy, Clone)]
352pub struct pthread_cond_t__bindgen_ty_1 {
353 pub __lock: ::std::os::raw::c_int,
354 pub __futex: ::std::os::raw::c_uint,
355 pub __total_seq: ::std::os::raw::c_ulonglong,
356 pub __wakeup_seq: ::std::os::raw::c_ulonglong,
357 pub __woken_seq: ::std::os::raw::c_ulonglong,
358 pub __mutex: *mut ::std::os::raw::c_void,
359 pub __nwaiters: ::std::os::raw::c_uint,
360 pub __broadcast_seq: ::std::os::raw::c_uint,
361}
362#[test]
363fn bindgen_test_layout_pthread_cond_t__bindgen_ty_1() {
364 assert_eq!(
365 ::std::mem::size_of::<pthread_cond_t__bindgen_ty_1>(),
366 48usize,
367 concat!("Size of: ", stringify!(pthread_cond_t__bindgen_ty_1))
368 );
369 assert_eq!(
370 ::std::mem::align_of::<pthread_cond_t__bindgen_ty_1>(),
371 8usize,
372 concat!("Alignment of ", stringify!(pthread_cond_t__bindgen_ty_1))
373 );
374 assert_eq!(
375 unsafe {
376 &(*(::std::ptr::null::<pthread_cond_t__bindgen_ty_1>())).__lock as *const _ as usize
377 },
378 0usize,
379 concat!(
380 "Offset of field: ",
381 stringify!(pthread_cond_t__bindgen_ty_1),
382 "::",
383 stringify!(__lock)
384 )
385 );
386 assert_eq!(
387 unsafe {
388 &(*(::std::ptr::null::<pthread_cond_t__bindgen_ty_1>())).__futex as *const _ as usize
389 },
390 4usize,
391 concat!(
392 "Offset of field: ",
393 stringify!(pthread_cond_t__bindgen_ty_1),
394 "::",
395 stringify!(__futex)
396 )
397 );
398 assert_eq!(
399 unsafe {
400 &(*(::std::ptr::null::<pthread_cond_t__bindgen_ty_1>())).__total_seq as *const _
401 as usize
402 },
403 8usize,
404 concat!(
405 "Offset of field: ",
406 stringify!(pthread_cond_t__bindgen_ty_1),
407 "::",
408 stringify!(__total_seq)
409 )
410 );
411 assert_eq!(
412 unsafe {
413 &(*(::std::ptr::null::<pthread_cond_t__bindgen_ty_1>())).__wakeup_seq as *const _
414 as usize
415 },
416 16usize,
417 concat!(
418 "Offset of field: ",
419 stringify!(pthread_cond_t__bindgen_ty_1),
420 "::",
421 stringify!(__wakeup_seq)
422 )
423 );
424 assert_eq!(
425 unsafe {
426 &(*(::std::ptr::null::<pthread_cond_t__bindgen_ty_1>())).__woken_seq as *const _
427 as usize
428 },
429 24usize,
430 concat!(
431 "Offset of field: ",
432 stringify!(pthread_cond_t__bindgen_ty_1),
433 "::",
434 stringify!(__woken_seq)
435 )
436 );
437 assert_eq!(
438 unsafe {
439 &(*(::std::ptr::null::<pthread_cond_t__bindgen_ty_1>())).__mutex as *const _ as usize
440 },
441 32usize,
442 concat!(
443 "Offset of field: ",
444 stringify!(pthread_cond_t__bindgen_ty_1),
445 "::",
446 stringify!(__mutex)
447 )
448 );
449 assert_eq!(
450 unsafe {
451 &(*(::std::ptr::null::<pthread_cond_t__bindgen_ty_1>())).__nwaiters as *const _ as usize
452 },
453 40usize,
454 concat!(
455 "Offset of field: ",
456 stringify!(pthread_cond_t__bindgen_ty_1),
457 "::",
458 stringify!(__nwaiters)
459 )
460 );
461 assert_eq!(
462 unsafe {
463 &(*(::std::ptr::null::<pthread_cond_t__bindgen_ty_1>())).__broadcast_seq as *const _
464 as usize
465 },
466 44usize,
467 concat!(
468 "Offset of field: ",
469 stringify!(pthread_cond_t__bindgen_ty_1),
470 "::",
471 stringify!(__broadcast_seq)
472 )
473 );
474}
475#[test]
476fn bindgen_test_layout_pthread_cond_t() {
477 assert_eq!(
478 ::std::mem::size_of::<pthread_cond_t>(),
479 48usize,
480 concat!("Size of: ", stringify!(pthread_cond_t))
481 );
482 assert_eq!(
483 ::std::mem::align_of::<pthread_cond_t>(),
484 8usize,
485 concat!("Alignment of ", stringify!(pthread_cond_t))
486 );
487 assert_eq!(
488 unsafe { &(*(::std::ptr::null::<pthread_cond_t>())).__data as *const _ as usize },
489 0usize,
490 concat!(
491 "Offset of field: ",
492 stringify!(pthread_cond_t),
493 "::",
494 stringify!(__data)
495 )
496 );
497 assert_eq!(
498 unsafe { &(*(::std::ptr::null::<pthread_cond_t>())).__size as *const _ as usize },
499 0usize,
500 concat!(
501 "Offset of field: ",
502 stringify!(pthread_cond_t),
503 "::",
504 stringify!(__size)
505 )
506 );
507 assert_eq!(
508 unsafe { &(*(::std::ptr::null::<pthread_cond_t>())).__align as *const _ as usize },
509 0usize,
510 concat!(
511 "Offset of field: ",
512 stringify!(pthread_cond_t),
513 "::",
514 stringify!(__align)
515 )
516 );
517}
518impl ::std::fmt::Debug for pthread_cond_t {
519 fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
520 write!(f, "pthread_cond_t {{ union }}")
521 }
522}
523pub type VALUE = usize;
524pub type ID = usize;
525#[repr(C)]
526#[derive(Debug, Copy, Clone)]
527pub struct RBasic {
528 pub flags: VALUE,
529 pub klass: VALUE,
530}
531#[test]
532fn bindgen_test_layout_RBasic() {
533 assert_eq!(
534 ::std::mem::size_of::<RBasic>(),
535 16usize,
536 concat!("Size of: ", stringify!(RBasic))
537 );
538 assert_eq!(
539 ::std::mem::align_of::<RBasic>(),
540 8usize,
541 concat!("Alignment of ", stringify!(RBasic))
542 );
543 assert_eq!(
544 unsafe { &(*(::std::ptr::null::<RBasic>())).flags as *const _ as usize },
545 0usize,
546 concat!(
547 "Offset of field: ",
548 stringify!(RBasic),
549 "::",
550 stringify!(flags)
551 )
552 );
553 assert_eq!(
554 unsafe { &(*(::std::ptr::null::<RBasic>())).klass as *const _ as usize },
555 8usize,
556 concat!(
557 "Offset of field: ",
558 stringify!(RBasic),
559 "::",
560 stringify!(klass)
561 )
562 );
563}
564#[repr(C)]
565#[derive(Copy, Clone)]
566pub struct RString {
567 pub basic: RBasic,
568 pub as_: RString__bindgen_ty_1,
569}
570#[repr(C)]
571#[derive(Copy, Clone)]
572pub union RString__bindgen_ty_1 {
573 pub heap: RString__bindgen_ty_1__bindgen_ty_1,
574 pub ary: [::std::os::raw::c_char; 24usize],
575 _bindgen_union_align: [u64; 3usize],
576}
577#[repr(C)]
578#[derive(Copy, Clone)]
579pub struct RString__bindgen_ty_1__bindgen_ty_1 {
580 pub len: ::std::os::raw::c_long,
581 pub ptr: *mut ::std::os::raw::c_char,
582 pub aux: RString__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1,
583}
584#[repr(C)]
585#[derive(Copy, Clone)]
586pub union RString__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1 {
587 pub capa: ::std::os::raw::c_long,
588 pub shared: VALUE,
589 _bindgen_union_align: u64,
590}
591#[test]
592fn bindgen_test_layout_RString__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1() {
593 assert_eq!(
594 ::std::mem::size_of::<RString__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1>(),
595 8usize,
596 concat!(
597 "Size of: ",
598 stringify!(RString__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1)
599 )
600 );
601 assert_eq!(
602 ::std::mem::align_of::<RString__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1>(),
603 8usize,
604 concat!(
605 "Alignment of ",
606 stringify!(RString__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1)
607 )
608 );
609 assert_eq!(
610 unsafe {
611 &(*(::std::ptr::null::<RString__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1>())).capa
612 as *const _ as usize
613 },
614 0usize,
615 concat!(
616 "Offset of field: ",
617 stringify!(RString__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
618 "::",
619 stringify!(capa)
620 )
621 );
622 assert_eq!(
623 unsafe {
624 &(*(::std::ptr::null::<RString__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1>())).shared
625 as *const _ as usize
626 },
627 0usize,
628 concat!(
629 "Offset of field: ",
630 stringify!(RString__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
631 "::",
632 stringify!(shared)
633 )
634 );
635}
636impl ::std::fmt::Debug for RString__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1 {
637 fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
638 write!(
639 f,
640 "RString__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1 {{ union }}"
641 )
642 }
643}
644#[test]
645fn bindgen_test_layout_RString__bindgen_ty_1__bindgen_ty_1() {
646 assert_eq!(
647 ::std::mem::size_of::<RString__bindgen_ty_1__bindgen_ty_1>(),
648 24usize,
649 concat!("Size of: ", stringify!(RString__bindgen_ty_1__bindgen_ty_1))
650 );
651 assert_eq!(
652 ::std::mem::align_of::<RString__bindgen_ty_1__bindgen_ty_1>(),
653 8usize,
654 concat!(
655 "Alignment of ",
656 stringify!(RString__bindgen_ty_1__bindgen_ty_1)
657 )
658 );
659 assert_eq!(
660 unsafe {
661 &(*(::std::ptr::null::<RString__bindgen_ty_1__bindgen_ty_1>())).len as *const _ as usize
662 },
663 0usize,
664 concat!(
665 "Offset of field: ",
666 stringify!(RString__bindgen_ty_1__bindgen_ty_1),
667 "::",
668 stringify!(len)
669 )
670 );
671 assert_eq!(
672 unsafe {
673 &(*(::std::ptr::null::<RString__bindgen_ty_1__bindgen_ty_1>())).ptr as *const _ as usize
674 },
675 8usize,
676 concat!(
677 "Offset of field: ",
678 stringify!(RString__bindgen_ty_1__bindgen_ty_1),
679 "::",
680 stringify!(ptr)
681 )
682 );
683 assert_eq!(
684 unsafe {
685 &(*(::std::ptr::null::<RString__bindgen_ty_1__bindgen_ty_1>())).aux as *const _ as usize
686 },
687 16usize,
688 concat!(
689 "Offset of field: ",
690 stringify!(RString__bindgen_ty_1__bindgen_ty_1),
691 "::",
692 stringify!(aux)
693 )
694 );
695}
696impl ::std::fmt::Debug for RString__bindgen_ty_1__bindgen_ty_1 {
697 fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
698 write!(
699 f,
700 "RString__bindgen_ty_1__bindgen_ty_1 {{ len: {:?}, ptr: {:?}, aux: {:?} }}",
701 self.len, self.ptr, self.aux
702 )
703 }
704}
705#[test]
706fn bindgen_test_layout_RString__bindgen_ty_1() {
707 assert_eq!(
708 ::std::mem::size_of::<RString__bindgen_ty_1>(),
709 24usize,
710 concat!("Size of: ", stringify!(RString__bindgen_ty_1))
711 );
712 assert_eq!(
713 ::std::mem::align_of::<RString__bindgen_ty_1>(),
714 8usize,
715 concat!("Alignment of ", stringify!(RString__bindgen_ty_1))
716 );
717 assert_eq!(
718 unsafe { &(*(::std::ptr::null::<RString__bindgen_ty_1>())).heap as *const _ as usize },
719 0usize,
720 concat!(
721 "Offset of field: ",
722 stringify!(RString__bindgen_ty_1),
723 "::",
724 stringify!(heap)
725 )
726 );
727 assert_eq!(
728 unsafe { &(*(::std::ptr::null::<RString__bindgen_ty_1>())).ary as *const _ as usize },
729 0usize,
730 concat!(
731 "Offset of field: ",
732 stringify!(RString__bindgen_ty_1),
733 "::",
734 stringify!(ary)
735 )
736 );
737}
738impl ::std::fmt::Debug for RString__bindgen_ty_1 {
739 fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
740 write!(f, "RString__bindgen_ty_1 {{ union }}")
741 }
742}
743#[test]
744fn bindgen_test_layout_RString() {
745 assert_eq!(
746 ::std::mem::size_of::<RString>(),
747 40usize,
748 concat!("Size of: ", stringify!(RString))
749 );
750 assert_eq!(
751 ::std::mem::align_of::<RString>(),
752 8usize,
753 concat!("Alignment of ", stringify!(RString))
754 );
755 assert_eq!(
756 unsafe { &(*(::std::ptr::null::<RString>())).basic as *const _ as usize },
757 0usize,
758 concat!(
759 "Offset of field: ",
760 stringify!(RString),
761 "::",
762 stringify!(basic)
763 )
764 );
765 assert_eq!(
766 unsafe { &(*(::std::ptr::null::<RString>())).as_ as *const _ as usize },
767 16usize,
768 concat!(
769 "Offset of field: ",
770 stringify!(RString),
771 "::",
772 stringify!(as_)
773 )
774 );
775}
776impl ::std::fmt::Debug for RString {
777 fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
778 write!(
779 f,
780 "RString {{ basic: {:?}, as: {:?} }}",
781 self.basic, self.as_
782 )
783 }
784}
785#[repr(C)]
786#[derive(Copy, Clone)]
787pub struct RArray {
788 pub basic: RBasic,
789 pub as_: RArray__bindgen_ty_1,
790}
791#[repr(C)]
792#[derive(Copy, Clone)]
793pub union RArray__bindgen_ty_1 {
794 pub heap: RArray__bindgen_ty_1__bindgen_ty_1,
795 pub ary: [VALUE; 3usize],
796 _bindgen_union_align: [u64; 3usize],
797}
798#[repr(C)]
799#[derive(Copy, Clone)]
800pub struct RArray__bindgen_ty_1__bindgen_ty_1 {
801 pub len: ::std::os::raw::c_long,
802 pub aux: RArray__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1,
803 pub ptr: *mut VALUE,
804}
805#[repr(C)]
806#[derive(Copy, Clone)]
807pub union RArray__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1 {
808 pub capa: ::std::os::raw::c_long,
809 pub shared: VALUE,
810 _bindgen_union_align: u64,
811}
812#[test]
813fn bindgen_test_layout_RArray__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1() {
814 assert_eq!(
815 ::std::mem::size_of::<RArray__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1>(),
816 8usize,
817 concat!(
818 "Size of: ",
819 stringify!(RArray__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1)
820 )
821 );
822 assert_eq!(
823 ::std::mem::align_of::<RArray__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1>(),
824 8usize,
825 concat!(
826 "Alignment of ",
827 stringify!(RArray__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1)
828 )
829 );
830 assert_eq!(
831 unsafe {
832 &(*(::std::ptr::null::<RArray__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1>())).capa
833 as *const _ as usize
834 },
835 0usize,
836 concat!(
837 "Offset of field: ",
838 stringify!(RArray__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
839 "::",
840 stringify!(capa)
841 )
842 );
843 assert_eq!(
844 unsafe {
845 &(*(::std::ptr::null::<RArray__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1>())).shared
846 as *const _ as usize
847 },
848 0usize,
849 concat!(
850 "Offset of field: ",
851 stringify!(RArray__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
852 "::",
853 stringify!(shared)
854 )
855 );
856}
857impl ::std::fmt::Debug for RArray__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1 {
858 fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
859 write!(
860 f,
861 "RArray__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1 {{ union }}"
862 )
863 }
864}
865#[test]
866fn bindgen_test_layout_RArray__bindgen_ty_1__bindgen_ty_1() {
867 assert_eq!(
868 ::std::mem::size_of::<RArray__bindgen_ty_1__bindgen_ty_1>(),
869 24usize,
870 concat!("Size of: ", stringify!(RArray__bindgen_ty_1__bindgen_ty_1))
871 );
872 assert_eq!(
873 ::std::mem::align_of::<RArray__bindgen_ty_1__bindgen_ty_1>(),
874 8usize,
875 concat!(
876 "Alignment of ",
877 stringify!(RArray__bindgen_ty_1__bindgen_ty_1)
878 )
879 );
880 assert_eq!(
881 unsafe {
882 &(*(::std::ptr::null::<RArray__bindgen_ty_1__bindgen_ty_1>())).len as *const _ as usize
883 },
884 0usize,
885 concat!(
886 "Offset of field: ",
887 stringify!(RArray__bindgen_ty_1__bindgen_ty_1),
888 "::",
889 stringify!(len)
890 )
891 );
892 assert_eq!(
893 unsafe {
894 &(*(::std::ptr::null::<RArray__bindgen_ty_1__bindgen_ty_1>())).aux as *const _ as usize
895 },
896 8usize,
897 concat!(
898 "Offset of field: ",
899 stringify!(RArray__bindgen_ty_1__bindgen_ty_1),
900 "::",
901 stringify!(aux)
902 )
903 );
904 assert_eq!(
905 unsafe {
906 &(*(::std::ptr::null::<RArray__bindgen_ty_1__bindgen_ty_1>())).ptr as *const _ as usize
907 },
908 16usize,
909 concat!(
910 "Offset of field: ",
911 stringify!(RArray__bindgen_ty_1__bindgen_ty_1),
912 "::",
913 stringify!(ptr)
914 )
915 );
916}
917impl ::std::fmt::Debug for RArray__bindgen_ty_1__bindgen_ty_1 {
918 fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
919 write!(
920 f,
921 "RArray__bindgen_ty_1__bindgen_ty_1 {{ len: {:?}, aux: {:?}, ptr: {:?} }}",
922 self.len, self.aux, self.ptr
923 )
924 }
925}
926#[test]
927fn bindgen_test_layout_RArray__bindgen_ty_1() {
928 assert_eq!(
929 ::std::mem::size_of::<RArray__bindgen_ty_1>(),
930 24usize,
931 concat!("Size of: ", stringify!(RArray__bindgen_ty_1))
932 );
933 assert_eq!(
934 ::std::mem::align_of::<RArray__bindgen_ty_1>(),
935 8usize,
936 concat!("Alignment of ", stringify!(RArray__bindgen_ty_1))
937 );
938 assert_eq!(
939 unsafe { &(*(::std::ptr::null::<RArray__bindgen_ty_1>())).heap as *const _ as usize },
940 0usize,
941 concat!(
942 "Offset of field: ",
943 stringify!(RArray__bindgen_ty_1),
944 "::",
945 stringify!(heap)
946 )
947 );
948 assert_eq!(
949 unsafe { &(*(::std::ptr::null::<RArray__bindgen_ty_1>())).ary as *const _ as usize },
950 0usize,
951 concat!(
952 "Offset of field: ",
953 stringify!(RArray__bindgen_ty_1),
954 "::",
955 stringify!(ary)
956 )
957 );
958}
959impl ::std::fmt::Debug for RArray__bindgen_ty_1 {
960 fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
961 write!(f, "RArray__bindgen_ty_1 {{ union }}")
962 }
963}
964#[test]
965fn bindgen_test_layout_RArray() {
966 assert_eq!(
967 ::std::mem::size_of::<RArray>(),
968 40usize,
969 concat!("Size of: ", stringify!(RArray))
970 );
971 assert_eq!(
972 ::std::mem::align_of::<RArray>(),
973 8usize,
974 concat!("Alignment of ", stringify!(RArray))
975 );
976 assert_eq!(
977 unsafe { &(*(::std::ptr::null::<RArray>())).basic as *const _ as usize },
978 0usize,
979 concat!(
980 "Offset of field: ",
981 stringify!(RArray),
982 "::",
983 stringify!(basic)
984 )
985 );
986 assert_eq!(
987 unsafe { &(*(::std::ptr::null::<RArray>())).as_ as *const _ as usize },
988 16usize,
989 concat!(
990 "Offset of field: ",
991 stringify!(RArray),
992 "::",
993 stringify!(as_)
994 )
995 );
996}
997impl ::std::fmt::Debug for RArray {
998 fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
999 write!(
1000 f,
1001 "RArray {{ basic: {:?}, as: {:?} }}",
1002 self.basic, self.as_
1003 )
1004 }
1005}
1006pub type st_data_t = usize;
1007#[repr(C)]
1008#[derive(Debug, Copy, Clone)]
1009pub struct st_hash_type {
1010 pub compare: ::std::option::Option<unsafe extern "C" fn() -> ::std::os::raw::c_int>,
1011 pub hash: ::std::option::Option<unsafe extern "C" fn() -> ::std::os::raw::c_int>,
1012}
1013#[test]
1014fn bindgen_test_layout_st_hash_type() {
1015 assert_eq!(
1016 ::std::mem::size_of::<st_hash_type>(),
1017 16usize,
1018 concat!("Size of: ", stringify!(st_hash_type))
1019 );
1020 assert_eq!(
1021 ::std::mem::align_of::<st_hash_type>(),
1022 8usize,
1023 concat!("Alignment of ", stringify!(st_hash_type))
1024 );
1025 assert_eq!(
1026 unsafe { &(*(::std::ptr::null::<st_hash_type>())).compare as *const _ as usize },
1027 0usize,
1028 concat!(
1029 "Offset of field: ",
1030 stringify!(st_hash_type),
1031 "::",
1032 stringify!(compare)
1033 )
1034 );
1035 assert_eq!(
1036 unsafe { &(*(::std::ptr::null::<st_hash_type>())).hash as *const _ as usize },
1037 8usize,
1038 concat!(
1039 "Offset of field: ",
1040 stringify!(st_hash_type),
1041 "::",
1042 stringify!(hash)
1043 )
1044 );
1045}
1046pub type st_index_t = st_data_t;
1047#[repr(C)]
1048#[derive(Debug, Copy, Clone)]
1049pub struct st_table {
1050 pub type_: *const st_hash_type,
1051 pub num_bins: st_index_t,
1052 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize], u64>,
1053 pub bins: *mut *mut st_table_entry,
1054 pub head: *mut st_table_entry,
1055}
1056#[test]
1057fn bindgen_test_layout_st_table() {
1058 assert_eq!(
1059 ::std::mem::size_of::<st_table>(),
1060 40usize,
1061 concat!("Size of: ", stringify!(st_table))
1062 );
1063 assert_eq!(
1064 ::std::mem::align_of::<st_table>(),
1065 8usize,
1066 concat!("Alignment of ", stringify!(st_table))
1067 );
1068 assert_eq!(
1069 unsafe { &(*(::std::ptr::null::<st_table>())).type_ as *const _ as usize },
1070 0usize,
1071 concat!(
1072 "Offset of field: ",
1073 stringify!(st_table),
1074 "::",
1075 stringify!(type_)
1076 )
1077 );
1078 assert_eq!(
1079 unsafe { &(*(::std::ptr::null::<st_table>())).num_bins as *const _ as usize },
1080 8usize,
1081 concat!(
1082 "Offset of field: ",
1083 stringify!(st_table),
1084 "::",
1085 stringify!(num_bins)
1086 )
1087 );
1088 assert_eq!(
1089 unsafe { &(*(::std::ptr::null::<st_table>())).bins as *const _ as usize },
1090 24usize,
1091 concat!(
1092 "Offset of field: ",
1093 stringify!(st_table),
1094 "::",
1095 stringify!(bins)
1096 )
1097 );
1098 assert_eq!(
1099 unsafe { &(*(::std::ptr::null::<st_table>())).head as *const _ as usize },
1100 32usize,
1101 concat!(
1102 "Offset of field: ",
1103 stringify!(st_table),
1104 "::",
1105 stringify!(head)
1106 )
1107 );
1108}
1109impl st_table {
1110 #[inline]
1111 pub fn entries_packed(&self) -> ::std::os::raw::c_uint {
1112 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u32) }
1113 }
1114 #[inline]
1115 pub fn set_entries_packed(&mut self, val: ::std::os::raw::c_uint) {
1116 unsafe {
1117 let val: u32 = ::std::mem::transmute(val);
1118 self._bitfield_1.set(0usize, 1u8, val as u64)
1119 }
1120 }
1121 #[inline]
1122 pub fn num_entries(&self) -> st_index_t {
1123 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 63u8) as usize) }
1124 }
1125 #[inline]
1126 pub fn set_num_entries(&mut self, val: st_index_t) {
1127 unsafe {
1128 let val: usize = ::std::mem::transmute(val);
1129 self._bitfield_1.set(1usize, 63u8, val as u64)
1130 }
1131 }
1132 #[inline]
1133 pub fn new_bitfield_1(
1134 entries_packed: ::std::os::raw::c_uint,
1135 num_entries: st_index_t,
1136 ) -> __BindgenBitfieldUnit<[u8; 8usize], u64> {
1137 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize], u64> =
1138 Default::default();
1139 __bindgen_bitfield_unit.set(0usize, 1u8, {
1140 let entries_packed: u32 = unsafe { ::std::mem::transmute(entries_packed) };
1141 entries_packed as u64
1142 });
1143 __bindgen_bitfield_unit.set(1usize, 63u8, {
1144 let num_entries: usize = unsafe { ::std::mem::transmute(num_entries) };
1145 num_entries as u64
1146 });
1147 __bindgen_bitfield_unit
1148 }
1149}
1150pub type rb_unblock_function_t =
1151 ::std::option::Option<unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void)>;
1152pub type rb_event_flag_t = ::std::os::raw::c_uint;
1153pub type rb_event_hook_func_t = ::std::option::Option<
1154 unsafe extern "C" fn(arg1: rb_event_flag_t, data: VALUE, arg2: VALUE, arg3: ID, klass: VALUE),
1155>;
1156#[repr(C)]
1157#[derive(Debug, Copy, Clone)]
1158pub struct rb_event_hook_struct {
1159 pub flag: rb_event_flag_t,
1160 pub func: rb_event_hook_func_t,
1161 pub data: VALUE,
1162 pub next: *mut rb_event_hook_struct,
1163}
1164#[test]
1165fn bindgen_test_layout_rb_event_hook_struct() {
1166 assert_eq!(
1167 ::std::mem::size_of::<rb_event_hook_struct>(),
1168 32usize,
1169 concat!("Size of: ", stringify!(rb_event_hook_struct))
1170 );
1171 assert_eq!(
1172 ::std::mem::align_of::<rb_event_hook_struct>(),
1173 8usize,
1174 concat!("Alignment of ", stringify!(rb_event_hook_struct))
1175 );
1176 assert_eq!(
1177 unsafe { &(*(::std::ptr::null::<rb_event_hook_struct>())).flag as *const _ as usize },
1178 0usize,
1179 concat!(
1180 "Offset of field: ",
1181 stringify!(rb_event_hook_struct),
1182 "::",
1183 stringify!(flag)
1184 )
1185 );
1186 assert_eq!(
1187 unsafe { &(*(::std::ptr::null::<rb_event_hook_struct>())).func as *const _ as usize },
1188 8usize,
1189 concat!(
1190 "Offset of field: ",
1191 stringify!(rb_event_hook_struct),
1192 "::",
1193 stringify!(func)
1194 )
1195 );
1196 assert_eq!(
1197 unsafe { &(*(::std::ptr::null::<rb_event_hook_struct>())).data as *const _ as usize },
1198 16usize,
1199 concat!(
1200 "Offset of field: ",
1201 stringify!(rb_event_hook_struct),
1202 "::",
1203 stringify!(data)
1204 )
1205 );
1206 assert_eq!(
1207 unsafe { &(*(::std::ptr::null::<rb_event_hook_struct>())).next as *const _ as usize },
1208 24usize,
1209 concat!(
1210 "Offset of field: ",
1211 stringify!(rb_event_hook_struct),
1212 "::",
1213 stringify!(next)
1214 )
1215 );
1216}
1217pub type rb_event_hook_t = rb_event_hook_struct;
1218#[repr(C)]
1219#[derive(Copy, Clone)]
1220pub struct RNode {
1221 pub flags: ::std::os::raw::c_ulong,
1222 pub nd_file: *mut ::std::os::raw::c_char,
1223 pub u1: RNode__bindgen_ty_1,
1224 pub u2: RNode__bindgen_ty_2,
1225 pub u3: RNode__bindgen_ty_3,
1226}
1227#[repr(C)]
1228#[derive(Copy, Clone)]
1229pub union RNode__bindgen_ty_1 {
1230 pub node: *mut RNode,
1231 pub id: ID,
1232 pub value: VALUE,
1233 pub cfunc: ::std::option::Option<unsafe extern "C" fn() -> VALUE>,
1234 pub tbl: *mut ID,
1235 _bindgen_union_align: u64,
1236}
1237#[test]
1238fn bindgen_test_layout_RNode__bindgen_ty_1() {
1239 assert_eq!(
1240 ::std::mem::size_of::<RNode__bindgen_ty_1>(),
1241 8usize,
1242 concat!("Size of: ", stringify!(RNode__bindgen_ty_1))
1243 );
1244 assert_eq!(
1245 ::std::mem::align_of::<RNode__bindgen_ty_1>(),
1246 8usize,
1247 concat!("Alignment of ", stringify!(RNode__bindgen_ty_1))
1248 );
1249 assert_eq!(
1250 unsafe { &(*(::std::ptr::null::<RNode__bindgen_ty_1>())).node as *const _ as usize },
1251 0usize,
1252 concat!(
1253 "Offset of field: ",
1254 stringify!(RNode__bindgen_ty_1),
1255 "::",
1256 stringify!(node)
1257 )
1258 );
1259 assert_eq!(
1260 unsafe { &(*(::std::ptr::null::<RNode__bindgen_ty_1>())).id as *const _ as usize },
1261 0usize,
1262 concat!(
1263 "Offset of field: ",
1264 stringify!(RNode__bindgen_ty_1),
1265 "::",
1266 stringify!(id)
1267 )
1268 );
1269 assert_eq!(
1270 unsafe { &(*(::std::ptr::null::<RNode__bindgen_ty_1>())).value as *const _ as usize },
1271 0usize,
1272 concat!(
1273 "Offset of field: ",
1274 stringify!(RNode__bindgen_ty_1),
1275 "::",
1276 stringify!(value)
1277 )
1278 );
1279 assert_eq!(
1280 unsafe { &(*(::std::ptr::null::<RNode__bindgen_ty_1>())).cfunc as *const _ as usize },
1281 0usize,
1282 concat!(
1283 "Offset of field: ",
1284 stringify!(RNode__bindgen_ty_1),
1285 "::",
1286 stringify!(cfunc)
1287 )
1288 );
1289 assert_eq!(
1290 unsafe { &(*(::std::ptr::null::<RNode__bindgen_ty_1>())).tbl as *const _ as usize },
1291 0usize,
1292 concat!(
1293 "Offset of field: ",
1294 stringify!(RNode__bindgen_ty_1),
1295 "::",
1296 stringify!(tbl)
1297 )
1298 );
1299}
1300impl ::std::fmt::Debug for RNode__bindgen_ty_1 {
1301 fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
1302 write!(f, "RNode__bindgen_ty_1 {{ union }}")
1303 }
1304}
1305#[repr(C)]
1306#[derive(Copy, Clone)]
1307pub union RNode__bindgen_ty_2 {
1308 pub node: *mut RNode,
1309 pub id: ID,
1310 pub argc: ::std::os::raw::c_long,
1311 pub value: VALUE,
1312 _bindgen_union_align: u64,
1313}
1314#[test]
1315fn bindgen_test_layout_RNode__bindgen_ty_2() {
1316 assert_eq!(
1317 ::std::mem::size_of::<RNode__bindgen_ty_2>(),
1318 8usize,
1319 concat!("Size of: ", stringify!(RNode__bindgen_ty_2))
1320 );
1321 assert_eq!(
1322 ::std::mem::align_of::<RNode__bindgen_ty_2>(),
1323 8usize,
1324 concat!("Alignment of ", stringify!(RNode__bindgen_ty_2))
1325 );
1326 assert_eq!(
1327 unsafe { &(*(::std::ptr::null::<RNode__bindgen_ty_2>())).node as *const _ as usize },
1328 0usize,
1329 concat!(
1330 "Offset of field: ",
1331 stringify!(RNode__bindgen_ty_2),
1332 "::",
1333 stringify!(node)
1334 )
1335 );
1336 assert_eq!(
1337 unsafe { &(*(::std::ptr::null::<RNode__bindgen_ty_2>())).id as *const _ as usize },
1338 0usize,
1339 concat!(
1340 "Offset of field: ",
1341 stringify!(RNode__bindgen_ty_2),
1342 "::",
1343 stringify!(id)
1344 )
1345 );
1346 assert_eq!(
1347 unsafe { &(*(::std::ptr::null::<RNode__bindgen_ty_2>())).argc as *const _ as usize },
1348 0usize,
1349 concat!(
1350 "Offset of field: ",
1351 stringify!(RNode__bindgen_ty_2),
1352 "::",
1353 stringify!(argc)
1354 )
1355 );
1356 assert_eq!(
1357 unsafe { &(*(::std::ptr::null::<RNode__bindgen_ty_2>())).value as *const _ as usize },
1358 0usize,
1359 concat!(
1360 "Offset of field: ",
1361 stringify!(RNode__bindgen_ty_2),
1362 "::",
1363 stringify!(value)
1364 )
1365 );
1366}
1367impl ::std::fmt::Debug for RNode__bindgen_ty_2 {
1368 fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
1369 write!(f, "RNode__bindgen_ty_2 {{ union }}")
1370 }
1371}
1372#[repr(C)]
1373#[derive(Copy, Clone)]
1374pub union RNode__bindgen_ty_3 {
1375 pub node: *mut RNode,
1376 pub id: ID,
1377 pub state: ::std::os::raw::c_long,
1378 pub entry: *mut global_entry,
1379 pub cnt: ::std::os::raw::c_long,
1380 pub value: VALUE,
1381 _bindgen_union_align: u64,
1382}
1383#[test]
1384fn bindgen_test_layout_RNode__bindgen_ty_3() {
1385 assert_eq!(
1386 ::std::mem::size_of::<RNode__bindgen_ty_3>(),
1387 8usize,
1388 concat!("Size of: ", stringify!(RNode__bindgen_ty_3))
1389 );
1390 assert_eq!(
1391 ::std::mem::align_of::<RNode__bindgen_ty_3>(),
1392 8usize,
1393 concat!("Alignment of ", stringify!(RNode__bindgen_ty_3))
1394 );
1395 assert_eq!(
1396 unsafe { &(*(::std::ptr::null::<RNode__bindgen_ty_3>())).node as *const _ as usize },
1397 0usize,
1398 concat!(
1399 "Offset of field: ",
1400 stringify!(RNode__bindgen_ty_3),
1401 "::",
1402 stringify!(node)
1403 )
1404 );
1405 assert_eq!(
1406 unsafe { &(*(::std::ptr::null::<RNode__bindgen_ty_3>())).id as *const _ as usize },
1407 0usize,
1408 concat!(
1409 "Offset of field: ",
1410 stringify!(RNode__bindgen_ty_3),
1411 "::",
1412 stringify!(id)
1413 )
1414 );
1415 assert_eq!(
1416 unsafe { &(*(::std::ptr::null::<RNode__bindgen_ty_3>())).state as *const _ as usize },
1417 0usize,
1418 concat!(
1419 "Offset of field: ",
1420 stringify!(RNode__bindgen_ty_3),
1421 "::",
1422 stringify!(state)
1423 )
1424 );
1425 assert_eq!(
1426 unsafe { &(*(::std::ptr::null::<RNode__bindgen_ty_3>())).entry as *const _ as usize },
1427 0usize,
1428 concat!(
1429 "Offset of field: ",
1430 stringify!(RNode__bindgen_ty_3),
1431 "::",
1432 stringify!(entry)
1433 )
1434 );
1435 assert_eq!(
1436 unsafe { &(*(::std::ptr::null::<RNode__bindgen_ty_3>())).cnt as *const _ as usize },
1437 0usize,
1438 concat!(
1439 "Offset of field: ",
1440 stringify!(RNode__bindgen_ty_3),
1441 "::",
1442 stringify!(cnt)
1443 )
1444 );
1445 assert_eq!(
1446 unsafe { &(*(::std::ptr::null::<RNode__bindgen_ty_3>())).value as *const _ as usize },
1447 0usize,
1448 concat!(
1449 "Offset of field: ",
1450 stringify!(RNode__bindgen_ty_3),
1451 "::",
1452 stringify!(value)
1453 )
1454 );
1455}
1456impl ::std::fmt::Debug for RNode__bindgen_ty_3 {
1457 fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
1458 write!(f, "RNode__bindgen_ty_3 {{ union }}")
1459 }
1460}
1461#[test]
1462fn bindgen_test_layout_RNode() {
1463 assert_eq!(
1464 ::std::mem::size_of::<RNode>(),
1465 40usize,
1466 concat!("Size of: ", stringify!(RNode))
1467 );
1468 assert_eq!(
1469 ::std::mem::align_of::<RNode>(),
1470 8usize,
1471 concat!("Alignment of ", stringify!(RNode))
1472 );
1473 assert_eq!(
1474 unsafe { &(*(::std::ptr::null::<RNode>())).flags as *const _ as usize },
1475 0usize,
1476 concat!(
1477 "Offset of field: ",
1478 stringify!(RNode),
1479 "::",
1480 stringify!(flags)
1481 )
1482 );
1483 assert_eq!(
1484 unsafe { &(*(::std::ptr::null::<RNode>())).nd_file as *const _ as usize },
1485 8usize,
1486 concat!(
1487 "Offset of field: ",
1488 stringify!(RNode),
1489 "::",
1490 stringify!(nd_file)
1491 )
1492 );
1493 assert_eq!(
1494 unsafe { &(*(::std::ptr::null::<RNode>())).u1 as *const _ as usize },
1495 16usize,
1496 concat!("Offset of field: ", stringify!(RNode), "::", stringify!(u1))
1497 );
1498 assert_eq!(
1499 unsafe { &(*(::std::ptr::null::<RNode>())).u2 as *const _ as usize },
1500 24usize,
1501 concat!("Offset of field: ", stringify!(RNode), "::", stringify!(u2))
1502 );
1503 assert_eq!(
1504 unsafe { &(*(::std::ptr::null::<RNode>())).u3 as *const _ as usize },
1505 32usize,
1506 concat!("Offset of field: ", stringify!(RNode), "::", stringify!(u3))
1507 );
1508}
1509impl ::std::fmt::Debug for RNode {
1510 fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
1511 write!(
1512 f,
1513 "RNode {{ flags: {:?}, nd_file: {:?}, u1: {:?}, u2: {:?}, u3: {:?} }}",
1514 self.flags, self.nd_file, self.u1, self.u2, self.u3
1515 )
1516 }
1517}
1518pub type NODE = RNode;
1519pub type __jmp_buf = [::std::os::raw::c_long; 8usize];
1520pub type rb_thread_id_t = pthread_t;
1521pub type rb_thread_lock_t = pthread_mutex_t;
1522#[repr(C)]
1523#[derive(Copy, Clone)]
1524pub struct native_thread_data_struct {
1525 pub signal_thread_list: *mut ::std::os::raw::c_void,
1526 pub sleep_cond: pthread_cond_t,
1527}
1528#[test]
1529fn bindgen_test_layout_native_thread_data_struct() {
1530 assert_eq!(
1531 ::std::mem::size_of::<native_thread_data_struct>(),
1532 56usize,
1533 concat!("Size of: ", stringify!(native_thread_data_struct))
1534 );
1535 assert_eq!(
1536 ::std::mem::align_of::<native_thread_data_struct>(),
1537 8usize,
1538 concat!("Alignment of ", stringify!(native_thread_data_struct))
1539 );
1540 assert_eq!(
1541 unsafe {
1542 &(*(::std::ptr::null::<native_thread_data_struct>())).signal_thread_list as *const _
1543 as usize
1544 },
1545 0usize,
1546 concat!(
1547 "Offset of field: ",
1548 stringify!(native_thread_data_struct),
1549 "::",
1550 stringify!(signal_thread_list)
1551 )
1552 );
1553 assert_eq!(
1554 unsafe {
1555 &(*(::std::ptr::null::<native_thread_data_struct>())).sleep_cond as *const _ as usize
1556 },
1557 8usize,
1558 concat!(
1559 "Offset of field: ",
1560 stringify!(native_thread_data_struct),
1561 "::",
1562 stringify!(sleep_cond)
1563 )
1564 );
1565}
1566impl ::std::fmt::Debug for native_thread_data_struct {
1567 fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
1568 write!(
1569 f,
1570 "native_thread_data_struct {{ signal_thread_list: {:?}, sleep_cond: {:?} }}",
1571 self.signal_thread_list, self.sleep_cond
1572 )
1573 }
1574}
1575pub type native_thread_data_t = native_thread_data_struct;
1576#[repr(C)]
1577#[derive(Debug, Copy, Clone)]
1578pub struct __jmp_buf_tag {
1579 pub __jmpbuf: __jmp_buf,
1580 pub __mask_was_saved: ::std::os::raw::c_int,
1581 pub __saved_mask: __sigset_t,
1582}
1583#[test]
1584fn bindgen_test_layout___jmp_buf_tag() {
1585 assert_eq!(
1586 ::std::mem::size_of::<__jmp_buf_tag>(),
1587 200usize,
1588 concat!("Size of: ", stringify!(__jmp_buf_tag))
1589 );
1590 assert_eq!(
1591 ::std::mem::align_of::<__jmp_buf_tag>(),
1592 8usize,
1593 concat!("Alignment of ", stringify!(__jmp_buf_tag))
1594 );
1595 assert_eq!(
1596 unsafe { &(*(::std::ptr::null::<__jmp_buf_tag>())).__jmpbuf as *const _ as usize },
1597 0usize,
1598 concat!(
1599 "Offset of field: ",
1600 stringify!(__jmp_buf_tag),
1601 "::",
1602 stringify!(__jmpbuf)
1603 )
1604 );
1605 assert_eq!(
1606 unsafe { &(*(::std::ptr::null::<__jmp_buf_tag>())).__mask_was_saved as *const _ as usize },
1607 64usize,
1608 concat!(
1609 "Offset of field: ",
1610 stringify!(__jmp_buf_tag),
1611 "::",
1612 stringify!(__mask_was_saved)
1613 )
1614 );
1615 assert_eq!(
1616 unsafe { &(*(::std::ptr::null::<__jmp_buf_tag>())).__saved_mask as *const _ as usize },
1617 72usize,
1618 concat!(
1619 "Offset of field: ",
1620 stringify!(__jmp_buf_tag),
1621 "::",
1622 stringify!(__saved_mask)
1623 )
1624 );
1625}
1626pub type jmp_buf = [__jmp_buf_tag; 1usize];
1627#[repr(C)]
1628#[derive(Debug, Copy, Clone)]
1629pub struct iseq_compile_data_ensure_node_stack {
1630 _unused: [u8; 0],
1631}
1632#[repr(C)]
1633#[derive(Debug, Copy, Clone)]
1634pub struct rb_compile_option_struct {
1635 pub inline_const_cache: ::std::os::raw::c_int,
1636 pub peephole_optimization: ::std::os::raw::c_int,
1637 pub tailcall_optimization: ::std::os::raw::c_int,
1638 pub specialized_instruction: ::std::os::raw::c_int,
1639 pub operands_unification: ::std::os::raw::c_int,
1640 pub instructions_unification: ::std::os::raw::c_int,
1641 pub stack_caching: ::std::os::raw::c_int,
1642 pub trace_instruction: ::std::os::raw::c_int,
1643 pub debug_level: ::std::os::raw::c_int,
1644}
1645#[test]
1646fn bindgen_test_layout_rb_compile_option_struct() {
1647 assert_eq!(
1648 ::std::mem::size_of::<rb_compile_option_struct>(),
1649 36usize,
1650 concat!("Size of: ", stringify!(rb_compile_option_struct))
1651 );
1652 assert_eq!(
1653 ::std::mem::align_of::<rb_compile_option_struct>(),
1654 4usize,
1655 concat!("Alignment of ", stringify!(rb_compile_option_struct))
1656 );
1657 assert_eq!(
1658 unsafe {
1659 &(*(::std::ptr::null::<rb_compile_option_struct>())).inline_const_cache as *const _
1660 as usize
1661 },
1662 0usize,
1663 concat!(
1664 "Offset of field: ",
1665 stringify!(rb_compile_option_struct),
1666 "::",
1667 stringify!(inline_const_cache)
1668 )
1669 );
1670 assert_eq!(
1671 unsafe {
1672 &(*(::std::ptr::null::<rb_compile_option_struct>())).peephole_optimization as *const _
1673 as usize
1674 },
1675 4usize,
1676 concat!(
1677 "Offset of field: ",
1678 stringify!(rb_compile_option_struct),
1679 "::",
1680 stringify!(peephole_optimization)
1681 )
1682 );
1683 assert_eq!(
1684 unsafe {
1685 &(*(::std::ptr::null::<rb_compile_option_struct>())).tailcall_optimization as *const _
1686 as usize
1687 },
1688 8usize,
1689 concat!(
1690 "Offset of field: ",
1691 stringify!(rb_compile_option_struct),
1692 "::",
1693 stringify!(tailcall_optimization)
1694 )
1695 );
1696 assert_eq!(
1697 unsafe {
1698 &(*(::std::ptr::null::<rb_compile_option_struct>())).specialized_instruction as *const _
1699 as usize
1700 },
1701 12usize,
1702 concat!(
1703 "Offset of field: ",
1704 stringify!(rb_compile_option_struct),
1705 "::",
1706 stringify!(specialized_instruction)
1707 )
1708 );
1709 assert_eq!(
1710 unsafe {
1711 &(*(::std::ptr::null::<rb_compile_option_struct>())).operands_unification as *const _
1712 as usize
1713 },
1714 16usize,
1715 concat!(
1716 "Offset of field: ",
1717 stringify!(rb_compile_option_struct),
1718 "::",
1719 stringify!(operands_unification)
1720 )
1721 );
1722 assert_eq!(
1723 unsafe {
1724 &(*(::std::ptr::null::<rb_compile_option_struct>())).instructions_unification
1725 as *const _ as usize
1726 },
1727 20usize,
1728 concat!(
1729 "Offset of field: ",
1730 stringify!(rb_compile_option_struct),
1731 "::",
1732 stringify!(instructions_unification)
1733 )
1734 );
1735 assert_eq!(
1736 unsafe {
1737 &(*(::std::ptr::null::<rb_compile_option_struct>())).stack_caching as *const _ as usize
1738 },
1739 24usize,
1740 concat!(
1741 "Offset of field: ",
1742 stringify!(rb_compile_option_struct),
1743 "::",
1744 stringify!(stack_caching)
1745 )
1746 );
1747 assert_eq!(
1748 unsafe {
1749 &(*(::std::ptr::null::<rb_compile_option_struct>())).trace_instruction as *const _
1750 as usize
1751 },
1752 28usize,
1753 concat!(
1754 "Offset of field: ",
1755 stringify!(rb_compile_option_struct),
1756 "::",
1757 stringify!(trace_instruction)
1758 )
1759 );
1760 assert_eq!(
1761 unsafe {
1762 &(*(::std::ptr::null::<rb_compile_option_struct>())).debug_level as *const _ as usize
1763 },
1764 32usize,
1765 concat!(
1766 "Offset of field: ",
1767 stringify!(rb_compile_option_struct),
1768 "::",
1769 stringify!(debug_level)
1770 )
1771 );
1772}
1773pub type rb_compile_option_t = rb_compile_option_struct;
1774#[repr(C)]
1775#[derive(Debug, Copy, Clone)]
1776pub struct rb_iseq_struct {
1777 pub type_: VALUE,
1778 pub name: VALUE,
1779 pub filename: VALUE,
1780 pub iseq: *mut VALUE,
1781 pub iseq_encoded: *mut VALUE,
1782 pub iseq_size: ::std::os::raw::c_ulong,
1783 pub mark_ary: VALUE,
1784 pub coverage: VALUE,
1785 pub insn_info_table: *mut iseq_insn_info_entry,
1786 pub insn_info_size: ::std::os::raw::c_ulong,
1787 pub local_table: *mut ID,
1788 pub local_table_size: ::std::os::raw::c_int,
1789 pub local_size: ::std::os::raw::c_int,
1790 pub argc: ::std::os::raw::c_int,
1791 pub arg_simple: ::std::os::raw::c_int,
1792 pub arg_rest: ::std::os::raw::c_int,
1793 pub arg_block: ::std::os::raw::c_int,
1794 pub arg_opts: ::std::os::raw::c_int,
1795 pub arg_post_len: ::std::os::raw::c_int,
1796 pub arg_post_start: ::std::os::raw::c_int,
1797 pub arg_size: ::std::os::raw::c_int,
1798 pub arg_opt_table: *mut VALUE,
1799 pub stack_max: ::std::os::raw::c_int,
1800 pub catch_table: *mut iseq_catch_table_entry,
1801 pub catch_table_size: ::std::os::raw::c_int,
1802 pub parent_iseq: *mut rb_iseq_struct,
1803 pub local_iseq: *mut rb_iseq_struct,
1804 pub self_: VALUE,
1805 pub orig: VALUE,
1806 pub cref_stack: *mut NODE,
1807 pub klass: VALUE,
1808 pub defined_method_id: ID,
1809 pub compile_data: *mut iseq_compile_data,
1810}
1811#[test]
1812fn bindgen_test_layout_rb_iseq_struct() {
1813 assert_eq!(
1814 ::std::mem::size_of::<rb_iseq_struct>(),
1815 224usize,
1816 concat!("Size of: ", stringify!(rb_iseq_struct))
1817 );
1818 assert_eq!(
1819 ::std::mem::align_of::<rb_iseq_struct>(),
1820 8usize,
1821 concat!("Alignment of ", stringify!(rb_iseq_struct))
1822 );
1823 assert_eq!(
1824 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).type_ as *const _ as usize },
1825 0usize,
1826 concat!(
1827 "Offset of field: ",
1828 stringify!(rb_iseq_struct),
1829 "::",
1830 stringify!(type_)
1831 )
1832 );
1833 assert_eq!(
1834 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).name as *const _ as usize },
1835 8usize,
1836 concat!(
1837 "Offset of field: ",
1838 stringify!(rb_iseq_struct),
1839 "::",
1840 stringify!(name)
1841 )
1842 );
1843 assert_eq!(
1844 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).filename as *const _ as usize },
1845 16usize,
1846 concat!(
1847 "Offset of field: ",
1848 stringify!(rb_iseq_struct),
1849 "::",
1850 stringify!(filename)
1851 )
1852 );
1853 assert_eq!(
1854 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).iseq as *const _ as usize },
1855 24usize,
1856 concat!(
1857 "Offset of field: ",
1858 stringify!(rb_iseq_struct),
1859 "::",
1860 stringify!(iseq)
1861 )
1862 );
1863 assert_eq!(
1864 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).iseq_encoded as *const _ as usize },
1865 32usize,
1866 concat!(
1867 "Offset of field: ",
1868 stringify!(rb_iseq_struct),
1869 "::",
1870 stringify!(iseq_encoded)
1871 )
1872 );
1873 assert_eq!(
1874 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).iseq_size as *const _ as usize },
1875 40usize,
1876 concat!(
1877 "Offset of field: ",
1878 stringify!(rb_iseq_struct),
1879 "::",
1880 stringify!(iseq_size)
1881 )
1882 );
1883 assert_eq!(
1884 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).mark_ary as *const _ as usize },
1885 48usize,
1886 concat!(
1887 "Offset of field: ",
1888 stringify!(rb_iseq_struct),
1889 "::",
1890 stringify!(mark_ary)
1891 )
1892 );
1893 assert_eq!(
1894 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).coverage as *const _ as usize },
1895 56usize,
1896 concat!(
1897 "Offset of field: ",
1898 stringify!(rb_iseq_struct),
1899 "::",
1900 stringify!(coverage)
1901 )
1902 );
1903 assert_eq!(
1904 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).insn_info_table as *const _ as usize },
1905 64usize,
1906 concat!(
1907 "Offset of field: ",
1908 stringify!(rb_iseq_struct),
1909 "::",
1910 stringify!(insn_info_table)
1911 )
1912 );
1913 assert_eq!(
1914 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).insn_info_size as *const _ as usize },
1915 72usize,
1916 concat!(
1917 "Offset of field: ",
1918 stringify!(rb_iseq_struct),
1919 "::",
1920 stringify!(insn_info_size)
1921 )
1922 );
1923 assert_eq!(
1924 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).local_table as *const _ as usize },
1925 80usize,
1926 concat!(
1927 "Offset of field: ",
1928 stringify!(rb_iseq_struct),
1929 "::",
1930 stringify!(local_table)
1931 )
1932 );
1933 assert_eq!(
1934 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).local_table_size as *const _ as usize },
1935 88usize,
1936 concat!(
1937 "Offset of field: ",
1938 stringify!(rb_iseq_struct),
1939 "::",
1940 stringify!(local_table_size)
1941 )
1942 );
1943 assert_eq!(
1944 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).local_size as *const _ as usize },
1945 92usize,
1946 concat!(
1947 "Offset of field: ",
1948 stringify!(rb_iseq_struct),
1949 "::",
1950 stringify!(local_size)
1951 )
1952 );
1953 assert_eq!(
1954 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).argc as *const _ as usize },
1955 96usize,
1956 concat!(
1957 "Offset of field: ",
1958 stringify!(rb_iseq_struct),
1959 "::",
1960 stringify!(argc)
1961 )
1962 );
1963 assert_eq!(
1964 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).arg_simple as *const _ as usize },
1965 100usize,
1966 concat!(
1967 "Offset of field: ",
1968 stringify!(rb_iseq_struct),
1969 "::",
1970 stringify!(arg_simple)
1971 )
1972 );
1973 assert_eq!(
1974 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).arg_rest as *const _ as usize },
1975 104usize,
1976 concat!(
1977 "Offset of field: ",
1978 stringify!(rb_iseq_struct),
1979 "::",
1980 stringify!(arg_rest)
1981 )
1982 );
1983 assert_eq!(
1984 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).arg_block as *const _ as usize },
1985 108usize,
1986 concat!(
1987 "Offset of field: ",
1988 stringify!(rb_iseq_struct),
1989 "::",
1990 stringify!(arg_block)
1991 )
1992 );
1993 assert_eq!(
1994 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).arg_opts as *const _ as usize },
1995 112usize,
1996 concat!(
1997 "Offset of field: ",
1998 stringify!(rb_iseq_struct),
1999 "::",
2000 stringify!(arg_opts)
2001 )
2002 );
2003 assert_eq!(
2004 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).arg_post_len as *const _ as usize },
2005 116usize,
2006 concat!(
2007 "Offset of field: ",
2008 stringify!(rb_iseq_struct),
2009 "::",
2010 stringify!(arg_post_len)
2011 )
2012 );
2013 assert_eq!(
2014 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).arg_post_start as *const _ as usize },
2015 120usize,
2016 concat!(
2017 "Offset of field: ",
2018 stringify!(rb_iseq_struct),
2019 "::",
2020 stringify!(arg_post_start)
2021 )
2022 );
2023 assert_eq!(
2024 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).arg_size as *const _ as usize },
2025 124usize,
2026 concat!(
2027 "Offset of field: ",
2028 stringify!(rb_iseq_struct),
2029 "::",
2030 stringify!(arg_size)
2031 )
2032 );
2033 assert_eq!(
2034 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).arg_opt_table as *const _ as usize },
2035 128usize,
2036 concat!(
2037 "Offset of field: ",
2038 stringify!(rb_iseq_struct),
2039 "::",
2040 stringify!(arg_opt_table)
2041 )
2042 );
2043 assert_eq!(
2044 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).stack_max as *const _ as usize },
2045 136usize,
2046 concat!(
2047 "Offset of field: ",
2048 stringify!(rb_iseq_struct),
2049 "::",
2050 stringify!(stack_max)
2051 )
2052 );
2053 assert_eq!(
2054 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).catch_table as *const _ as usize },
2055 144usize,
2056 concat!(
2057 "Offset of field: ",
2058 stringify!(rb_iseq_struct),
2059 "::",
2060 stringify!(catch_table)
2061 )
2062 );
2063 assert_eq!(
2064 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).catch_table_size as *const _ as usize },
2065 152usize,
2066 concat!(
2067 "Offset of field: ",
2068 stringify!(rb_iseq_struct),
2069 "::",
2070 stringify!(catch_table_size)
2071 )
2072 );
2073 assert_eq!(
2074 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).parent_iseq as *const _ as usize },
2075 160usize,
2076 concat!(
2077 "Offset of field: ",
2078 stringify!(rb_iseq_struct),
2079 "::",
2080 stringify!(parent_iseq)
2081 )
2082 );
2083 assert_eq!(
2084 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).local_iseq as *const _ as usize },
2085 168usize,
2086 concat!(
2087 "Offset of field: ",
2088 stringify!(rb_iseq_struct),
2089 "::",
2090 stringify!(local_iseq)
2091 )
2092 );
2093 assert_eq!(
2094 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).self_ as *const _ as usize },
2095 176usize,
2096 concat!(
2097 "Offset of field: ",
2098 stringify!(rb_iseq_struct),
2099 "::",
2100 stringify!(self_)
2101 )
2102 );
2103 assert_eq!(
2104 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).orig as *const _ as usize },
2105 184usize,
2106 concat!(
2107 "Offset of field: ",
2108 stringify!(rb_iseq_struct),
2109 "::",
2110 stringify!(orig)
2111 )
2112 );
2113 assert_eq!(
2114 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).cref_stack as *const _ as usize },
2115 192usize,
2116 concat!(
2117 "Offset of field: ",
2118 stringify!(rb_iseq_struct),
2119 "::",
2120 stringify!(cref_stack)
2121 )
2122 );
2123 assert_eq!(
2124 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).klass as *const _ as usize },
2125 200usize,
2126 concat!(
2127 "Offset of field: ",
2128 stringify!(rb_iseq_struct),
2129 "::",
2130 stringify!(klass)
2131 )
2132 );
2133 assert_eq!(
2134 unsafe {
2135 &(*(::std::ptr::null::<rb_iseq_struct>())).defined_method_id as *const _ as usize
2136 },
2137 208usize,
2138 concat!(
2139 "Offset of field: ",
2140 stringify!(rb_iseq_struct),
2141 "::",
2142 stringify!(defined_method_id)
2143 )
2144 );
2145 assert_eq!(
2146 unsafe { &(*(::std::ptr::null::<rb_iseq_struct>())).compile_data as *const _ as usize },
2147 216usize,
2148 concat!(
2149 "Offset of field: ",
2150 stringify!(rb_iseq_struct),
2151 "::",
2152 stringify!(compile_data)
2153 )
2154 );
2155}
2156pub type rb_iseq_t = rb_iseq_struct;
2157#[repr(C)]
2158#[derive(Copy, Clone)]
2159pub struct rb_vm_struct {
2160 pub self_: VALUE,
2161 pub global_vm_lock: rb_thread_lock_t,
2162 pub main_thread: *mut rb_thread_struct,
2163 pub running_thread: *mut rb_thread_struct,
2164 pub living_threads: *mut st_table,
2165 pub thgroup_default: VALUE,
2166 pub running: ::std::os::raw::c_int,
2167 pub thread_abort_on_exception: ::std::os::raw::c_int,
2168 pub trace_flag: ::std::os::raw::c_ulong,
2169 pub sleeper: ::std::os::raw::c_int,
2170 pub mark_object_ary: VALUE,
2171 pub special_exceptions: [VALUE; 3usize],
2172 pub top_self: VALUE,
2173 pub load_path: VALUE,
2174 pub loaded_features: VALUE,
2175 pub loading_table: *mut st_table,
2176 pub trap_list: [rb_vm_struct__bindgen_ty_1; 65usize],
2177 pub event_hooks: *mut rb_event_hook_t,
2178 pub src_encoding_index: ::std::os::raw::c_int,
2179 pub verbose: VALUE,
2180 pub debug: VALUE,
2181 pub progname: VALUE,
2182 pub coverages: VALUE,
2183}
2184#[repr(C)]
2185#[derive(Debug, Copy, Clone)]
2186pub struct rb_vm_struct__bindgen_ty_1 {
2187 pub cmd: VALUE,
2188 pub safe: ::std::os::raw::c_int,
2189}
2190#[test]
2191fn bindgen_test_layout_rb_vm_struct__bindgen_ty_1() {
2192 assert_eq!(
2193 ::std::mem::size_of::<rb_vm_struct__bindgen_ty_1>(),
2194 16usize,
2195 concat!("Size of: ", stringify!(rb_vm_struct__bindgen_ty_1))
2196 );
2197 assert_eq!(
2198 ::std::mem::align_of::<rb_vm_struct__bindgen_ty_1>(),
2199 8usize,
2200 concat!("Alignment of ", stringify!(rb_vm_struct__bindgen_ty_1))
2201 );
2202 assert_eq!(
2203 unsafe { &(*(::std::ptr::null::<rb_vm_struct__bindgen_ty_1>())).cmd as *const _ as usize },
2204 0usize,
2205 concat!(
2206 "Offset of field: ",
2207 stringify!(rb_vm_struct__bindgen_ty_1),
2208 "::",
2209 stringify!(cmd)
2210 )
2211 );
2212 assert_eq!(
2213 unsafe { &(*(::std::ptr::null::<rb_vm_struct__bindgen_ty_1>())).safe as *const _ as usize },
2214 8usize,
2215 concat!(
2216 "Offset of field: ",
2217 stringify!(rb_vm_struct__bindgen_ty_1),
2218 "::",
2219 stringify!(safe)
2220 )
2221 );
2222}
2223#[test]
2224fn bindgen_test_layout_rb_vm_struct() {
2225 assert_eq!(
2226 ::std::mem::size_of::<rb_vm_struct>(),
2227 1256usize,
2228 concat!("Size of: ", stringify!(rb_vm_struct))
2229 );
2230 assert_eq!(
2231 ::std::mem::align_of::<rb_vm_struct>(),
2232 8usize,
2233 concat!("Alignment of ", stringify!(rb_vm_struct))
2234 );
2235 assert_eq!(
2236 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).self_ as *const _ as usize },
2237 0usize,
2238 concat!(
2239 "Offset of field: ",
2240 stringify!(rb_vm_struct),
2241 "::",
2242 stringify!(self_)
2243 )
2244 );
2245 assert_eq!(
2246 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).global_vm_lock as *const _ as usize },
2247 8usize,
2248 concat!(
2249 "Offset of field: ",
2250 stringify!(rb_vm_struct),
2251 "::",
2252 stringify!(global_vm_lock)
2253 )
2254 );
2255 assert_eq!(
2256 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).main_thread as *const _ as usize },
2257 48usize,
2258 concat!(
2259 "Offset of field: ",
2260 stringify!(rb_vm_struct),
2261 "::",
2262 stringify!(main_thread)
2263 )
2264 );
2265 assert_eq!(
2266 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).running_thread as *const _ as usize },
2267 56usize,
2268 concat!(
2269 "Offset of field: ",
2270 stringify!(rb_vm_struct),
2271 "::",
2272 stringify!(running_thread)
2273 )
2274 );
2275 assert_eq!(
2276 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).living_threads as *const _ as usize },
2277 64usize,
2278 concat!(
2279 "Offset of field: ",
2280 stringify!(rb_vm_struct),
2281 "::",
2282 stringify!(living_threads)
2283 )
2284 );
2285 assert_eq!(
2286 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).thgroup_default as *const _ as usize },
2287 72usize,
2288 concat!(
2289 "Offset of field: ",
2290 stringify!(rb_vm_struct),
2291 "::",
2292 stringify!(thgroup_default)
2293 )
2294 );
2295 assert_eq!(
2296 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).running as *const _ as usize },
2297 80usize,
2298 concat!(
2299 "Offset of field: ",
2300 stringify!(rb_vm_struct),
2301 "::",
2302 stringify!(running)
2303 )
2304 );
2305 assert_eq!(
2306 unsafe {
2307 &(*(::std::ptr::null::<rb_vm_struct>())).thread_abort_on_exception as *const _ as usize
2308 },
2309 84usize,
2310 concat!(
2311 "Offset of field: ",
2312 stringify!(rb_vm_struct),
2313 "::",
2314 stringify!(thread_abort_on_exception)
2315 )
2316 );
2317 assert_eq!(
2318 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).trace_flag as *const _ as usize },
2319 88usize,
2320 concat!(
2321 "Offset of field: ",
2322 stringify!(rb_vm_struct),
2323 "::",
2324 stringify!(trace_flag)
2325 )
2326 );
2327 assert_eq!(
2328 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).sleeper as *const _ as usize },
2329 96usize,
2330 concat!(
2331 "Offset of field: ",
2332 stringify!(rb_vm_struct),
2333 "::",
2334 stringify!(sleeper)
2335 )
2336 );
2337 assert_eq!(
2338 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).mark_object_ary as *const _ as usize },
2339 104usize,
2340 concat!(
2341 "Offset of field: ",
2342 stringify!(rb_vm_struct),
2343 "::",
2344 stringify!(mark_object_ary)
2345 )
2346 );
2347 assert_eq!(
2348 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).special_exceptions as *const _ as usize },
2349 112usize,
2350 concat!(
2351 "Offset of field: ",
2352 stringify!(rb_vm_struct),
2353 "::",
2354 stringify!(special_exceptions)
2355 )
2356 );
2357 assert_eq!(
2358 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).top_self as *const _ as usize },
2359 136usize,
2360 concat!(
2361 "Offset of field: ",
2362 stringify!(rb_vm_struct),
2363 "::",
2364 stringify!(top_self)
2365 )
2366 );
2367 assert_eq!(
2368 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).load_path as *const _ as usize },
2369 144usize,
2370 concat!(
2371 "Offset of field: ",
2372 stringify!(rb_vm_struct),
2373 "::",
2374 stringify!(load_path)
2375 )
2376 );
2377 assert_eq!(
2378 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).loaded_features as *const _ as usize },
2379 152usize,
2380 concat!(
2381 "Offset of field: ",
2382 stringify!(rb_vm_struct),
2383 "::",
2384 stringify!(loaded_features)
2385 )
2386 );
2387 assert_eq!(
2388 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).loading_table as *const _ as usize },
2389 160usize,
2390 concat!(
2391 "Offset of field: ",
2392 stringify!(rb_vm_struct),
2393 "::",
2394 stringify!(loading_table)
2395 )
2396 );
2397 assert_eq!(
2398 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).trap_list as *const _ as usize },
2399 168usize,
2400 concat!(
2401 "Offset of field: ",
2402 stringify!(rb_vm_struct),
2403 "::",
2404 stringify!(trap_list)
2405 )
2406 );
2407 assert_eq!(
2408 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).event_hooks as *const _ as usize },
2409 1208usize,
2410 concat!(
2411 "Offset of field: ",
2412 stringify!(rb_vm_struct),
2413 "::",
2414 stringify!(event_hooks)
2415 )
2416 );
2417 assert_eq!(
2418 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).src_encoding_index as *const _ as usize },
2419 1216usize,
2420 concat!(
2421 "Offset of field: ",
2422 stringify!(rb_vm_struct),
2423 "::",
2424 stringify!(src_encoding_index)
2425 )
2426 );
2427 assert_eq!(
2428 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).verbose as *const _ as usize },
2429 1224usize,
2430 concat!(
2431 "Offset of field: ",
2432 stringify!(rb_vm_struct),
2433 "::",
2434 stringify!(verbose)
2435 )
2436 );
2437 assert_eq!(
2438 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).debug as *const _ as usize },
2439 1232usize,
2440 concat!(
2441 "Offset of field: ",
2442 stringify!(rb_vm_struct),
2443 "::",
2444 stringify!(debug)
2445 )
2446 );
2447 assert_eq!(
2448 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).progname as *const _ as usize },
2449 1240usize,
2450 concat!(
2451 "Offset of field: ",
2452 stringify!(rb_vm_struct),
2453 "::",
2454 stringify!(progname)
2455 )
2456 );
2457 assert_eq!(
2458 unsafe { &(*(::std::ptr::null::<rb_vm_struct>())).coverages as *const _ as usize },
2459 1248usize,
2460 concat!(
2461 "Offset of field: ",
2462 stringify!(rb_vm_struct),
2463 "::",
2464 stringify!(coverages)
2465 )
2466 );
2467}
2468impl ::std::fmt::Debug for rb_vm_struct {
2469 fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
2470 write ! ( f , "rb_vm_struct {{ self: {:?}, global_vm_lock: {:?}, main_thread: {:?}, running_thread: {:?}, living_threads: {:?}, thgroup_default: {:?}, running: {:?}, thread_abort_on_exception: {:?}, trace_flag: {:?}, sleeper: {:?}, mark_object_ary: {:?}, special_exceptions: {:?}, top_self: {:?}, load_path: {:?}, loaded_features: {:?}, loading_table: {:?}, trap_list: [{}], event_hooks: {:?}, src_encoding_index: {:?}, verbose: {:?}, debug: {:?}, progname: {:?}, coverages: {:?} }}" , self . self_ , self . global_vm_lock , self . main_thread , self . running_thread , self . living_threads , self . thgroup_default , self . running , self . thread_abort_on_exception , self . trace_flag , self . sleeper , self . mark_object_ary , self . special_exceptions , self . top_self , self . load_path , self . loaded_features , self . loading_table , self . trap_list . iter ( ) . enumerate ( ) . map ( | ( i , v ) | format ! ( "{}{:?}" , if i > 0 { ", " } else { "" } , v ) ) . collect :: < String > ( ) , self . event_hooks , self . src_encoding_index , self . verbose , self . debug , self . progname , self . coverages )
2471 }
2472}
2473pub type rb_vm_t = rb_vm_struct;
2474#[repr(C)]
2475#[derive(Debug, Copy, Clone)]
2476pub struct rb_control_frame_t {
2477 pub pc: *mut VALUE,
2478 pub sp: *mut VALUE,
2479 pub bp: *mut VALUE,
2480 pub iseq: *mut rb_iseq_t,
2481 pub flag: VALUE,
2482 pub self_: VALUE,
2483 pub lfp: *mut VALUE,
2484 pub dfp: *mut VALUE,
2485 pub block_iseq: *mut rb_iseq_t,
2486 pub proc_: VALUE,
2487 pub method_id: ID,
2488 pub method_class: VALUE,
2489}
2490#[test]
2491fn bindgen_test_layout_rb_control_frame_t() {
2492 assert_eq!(
2493 ::std::mem::size_of::<rb_control_frame_t>(),
2494 96usize,
2495 concat!("Size of: ", stringify!(rb_control_frame_t))
2496 );
2497 assert_eq!(
2498 ::std::mem::align_of::<rb_control_frame_t>(),
2499 8usize,
2500 concat!("Alignment of ", stringify!(rb_control_frame_t))
2501 );
2502 assert_eq!(
2503 unsafe { &(*(::std::ptr::null::<rb_control_frame_t>())).pc as *const _ as usize },
2504 0usize,
2505 concat!(
2506 "Offset of field: ",
2507 stringify!(rb_control_frame_t),
2508 "::",
2509 stringify!(pc)
2510 )
2511 );
2512 assert_eq!(
2513 unsafe { &(*(::std::ptr::null::<rb_control_frame_t>())).sp as *const _ as usize },
2514 8usize,
2515 concat!(
2516 "Offset of field: ",
2517 stringify!(rb_control_frame_t),
2518 "::",
2519 stringify!(sp)
2520 )
2521 );
2522 assert_eq!(
2523 unsafe { &(*(::std::ptr::null::<rb_control_frame_t>())).bp as *const _ as usize },
2524 16usize,
2525 concat!(
2526 "Offset of field: ",
2527 stringify!(rb_control_frame_t),
2528 "::",
2529 stringify!(bp)
2530 )
2531 );
2532 assert_eq!(
2533 unsafe { &(*(::std::ptr::null::<rb_control_frame_t>())).iseq as *const _ as usize },
2534 24usize,
2535 concat!(
2536 "Offset of field: ",
2537 stringify!(rb_control_frame_t),
2538 "::",
2539 stringify!(iseq)
2540 )
2541 );
2542 assert_eq!(
2543 unsafe { &(*(::std::ptr::null::<rb_control_frame_t>())).flag as *const _ as usize },
2544 32usize,
2545 concat!(
2546 "Offset of field: ",
2547 stringify!(rb_control_frame_t),
2548 "::",
2549 stringify!(flag)
2550 )
2551 );
2552 assert_eq!(
2553 unsafe { &(*(::std::ptr::null::<rb_control_frame_t>())).self_ as *const _ as usize },
2554 40usize,
2555 concat!(
2556 "Offset of field: ",
2557 stringify!(rb_control_frame_t),
2558 "::",
2559 stringify!(self_)
2560 )
2561 );
2562 assert_eq!(
2563 unsafe { &(*(::std::ptr::null::<rb_control_frame_t>())).lfp as *const _ as usize },
2564 48usize,
2565 concat!(
2566 "Offset of field: ",
2567 stringify!(rb_control_frame_t),
2568 "::",
2569 stringify!(lfp)
2570 )
2571 );
2572 assert_eq!(
2573 unsafe { &(*(::std::ptr::null::<rb_control_frame_t>())).dfp as *const _ as usize },
2574 56usize,
2575 concat!(
2576 "Offset of field: ",
2577 stringify!(rb_control_frame_t),
2578 "::",
2579 stringify!(dfp)
2580 )
2581 );
2582 assert_eq!(
2583 unsafe { &(*(::std::ptr::null::<rb_control_frame_t>())).block_iseq as *const _ as usize },
2584 64usize,
2585 concat!(
2586 "Offset of field: ",
2587 stringify!(rb_control_frame_t),
2588 "::",
2589 stringify!(block_iseq)
2590 )
2591 );
2592 assert_eq!(
2593 unsafe { &(*(::std::ptr::null::<rb_control_frame_t>())).proc_ as *const _ as usize },
2594 72usize,
2595 concat!(
2596 "Offset of field: ",
2597 stringify!(rb_control_frame_t),
2598 "::",
2599 stringify!(proc_)
2600 )
2601 );
2602 assert_eq!(
2603 unsafe { &(*(::std::ptr::null::<rb_control_frame_t>())).method_id as *const _ as usize },
2604 80usize,
2605 concat!(
2606 "Offset of field: ",
2607 stringify!(rb_control_frame_t),
2608 "::",
2609 stringify!(method_id)
2610 )
2611 );
2612 assert_eq!(
2613 unsafe { &(*(::std::ptr::null::<rb_control_frame_t>())).method_class as *const _ as usize },
2614 88usize,
2615 concat!(
2616 "Offset of field: ",
2617 stringify!(rb_control_frame_t),
2618 "::",
2619 stringify!(method_class)
2620 )
2621 );
2622}
2623#[repr(C)]
2624#[derive(Debug, Copy, Clone)]
2625pub struct rb_block_struct {
2626 pub self_: VALUE,
2627 pub lfp: *mut VALUE,
2628 pub dfp: *mut VALUE,
2629 pub iseq: *mut rb_iseq_t,
2630 pub proc_: VALUE,
2631}
2632#[test]
2633fn bindgen_test_layout_rb_block_struct() {
2634 assert_eq!(
2635 ::std::mem::size_of::<rb_block_struct>(),
2636 40usize,
2637 concat!("Size of: ", stringify!(rb_block_struct))
2638 );
2639 assert_eq!(
2640 ::std::mem::align_of::<rb_block_struct>(),
2641 8usize,
2642 concat!("Alignment of ", stringify!(rb_block_struct))
2643 );
2644 assert_eq!(
2645 unsafe { &(*(::std::ptr::null::<rb_block_struct>())).self_ as *const _ as usize },
2646 0usize,
2647 concat!(
2648 "Offset of field: ",
2649 stringify!(rb_block_struct),
2650 "::",
2651 stringify!(self_)
2652 )
2653 );
2654 assert_eq!(
2655 unsafe { &(*(::std::ptr::null::<rb_block_struct>())).lfp as *const _ as usize },
2656 8usize,
2657 concat!(
2658 "Offset of field: ",
2659 stringify!(rb_block_struct),
2660 "::",
2661 stringify!(lfp)
2662 )
2663 );
2664 assert_eq!(
2665 unsafe { &(*(::std::ptr::null::<rb_block_struct>())).dfp as *const _ as usize },
2666 16usize,
2667 concat!(
2668 "Offset of field: ",
2669 stringify!(rb_block_struct),
2670 "::",
2671 stringify!(dfp)
2672 )
2673 );
2674 assert_eq!(
2675 unsafe { &(*(::std::ptr::null::<rb_block_struct>())).iseq as *const _ as usize },
2676 24usize,
2677 concat!(
2678 "Offset of field: ",
2679 stringify!(rb_block_struct),
2680 "::",
2681 stringify!(iseq)
2682 )
2683 );
2684 assert_eq!(
2685 unsafe { &(*(::std::ptr::null::<rb_block_struct>())).proc_ as *const _ as usize },
2686 32usize,
2687 concat!(
2688 "Offset of field: ",
2689 stringify!(rb_block_struct),
2690 "::",
2691 stringify!(proc_)
2692 )
2693 );
2694}
2695pub type rb_block_t = rb_block_struct;
2696pub const rb_thread_status_THREAD_TO_KILL: rb_thread_status = 0;
2697pub const rb_thread_status_THREAD_RUNNABLE: rb_thread_status = 1;
2698pub const rb_thread_status_THREAD_STOPPED: rb_thread_status = 2;
2699pub const rb_thread_status_THREAD_STOPPED_FOREVER: rb_thread_status = 3;
2700pub const rb_thread_status_THREAD_KILLED: rb_thread_status = 4;
2701pub type rb_thread_status = ::std::os::raw::c_uint;
2702pub type rb_jmpbuf_t = jmp_buf;
2703#[repr(C)]
2704#[derive(Debug, Copy, Clone)]
2705pub struct rb_vm_tag {
2706 pub buf: rb_jmpbuf_t,
2707 pub tag: VALUE,
2708 pub retval: VALUE,
2709 pub prev: *mut rb_vm_tag,
2710}
2711#[test]
2712fn bindgen_test_layout_rb_vm_tag() {
2713 assert_eq!(
2714 ::std::mem::size_of::<rb_vm_tag>(),
2715 224usize,
2716 concat!("Size of: ", stringify!(rb_vm_tag))
2717 );
2718 assert_eq!(
2719 ::std::mem::align_of::<rb_vm_tag>(),
2720 8usize,
2721 concat!("Alignment of ", stringify!(rb_vm_tag))
2722 );
2723 assert_eq!(
2724 unsafe { &(*(::std::ptr::null::<rb_vm_tag>())).buf as *const _ as usize },
2725 0usize,
2726 concat!(
2727 "Offset of field: ",
2728 stringify!(rb_vm_tag),
2729 "::",
2730 stringify!(buf)
2731 )
2732 );
2733 assert_eq!(
2734 unsafe { &(*(::std::ptr::null::<rb_vm_tag>())).tag as *const _ as usize },
2735 200usize,
2736 concat!(
2737 "Offset of field: ",
2738 stringify!(rb_vm_tag),
2739 "::",
2740 stringify!(tag)
2741 )
2742 );
2743 assert_eq!(
2744 unsafe { &(*(::std::ptr::null::<rb_vm_tag>())).retval as *const _ as usize },
2745 208usize,
2746 concat!(
2747 "Offset of field: ",
2748 stringify!(rb_vm_tag),
2749 "::",
2750 stringify!(retval)
2751 )
2752 );
2753 assert_eq!(
2754 unsafe { &(*(::std::ptr::null::<rb_vm_tag>())).prev as *const _ as usize },
2755 216usize,
2756 concat!(
2757 "Offset of field: ",
2758 stringify!(rb_vm_tag),
2759 "::",
2760 stringify!(prev)
2761 )
2762 );
2763}
2764#[repr(C)]
2765#[derive(Debug, Copy, Clone)]
2766pub struct rb_vm_trap_tag {
2767 pub prev: *mut rb_vm_trap_tag,
2768}
2769#[test]
2770fn bindgen_test_layout_rb_vm_trap_tag() {
2771 assert_eq!(
2772 ::std::mem::size_of::<rb_vm_trap_tag>(),
2773 8usize,
2774 concat!("Size of: ", stringify!(rb_vm_trap_tag))
2775 );
2776 assert_eq!(
2777 ::std::mem::align_of::<rb_vm_trap_tag>(),
2778 8usize,
2779 concat!("Alignment of ", stringify!(rb_vm_trap_tag))
2780 );
2781 assert_eq!(
2782 unsafe { &(*(::std::ptr::null::<rb_vm_trap_tag>())).prev as *const _ as usize },
2783 0usize,
2784 concat!(
2785 "Offset of field: ",
2786 stringify!(rb_vm_trap_tag),
2787 "::",
2788 stringify!(prev)
2789 )
2790 );
2791}
2792#[repr(C)]
2793#[derive(Debug, Copy, Clone)]
2794pub struct rb_unblock_callback {
2795 pub func: rb_unblock_function_t,
2796 pub arg: *mut ::std::os::raw::c_void,
2797}
2798#[test]
2799fn bindgen_test_layout_rb_unblock_callback() {
2800 assert_eq!(
2801 ::std::mem::size_of::<rb_unblock_callback>(),
2802 16usize,
2803 concat!("Size of: ", stringify!(rb_unblock_callback))
2804 );
2805 assert_eq!(
2806 ::std::mem::align_of::<rb_unblock_callback>(),
2807 8usize,
2808 concat!("Alignment of ", stringify!(rb_unblock_callback))
2809 );
2810 assert_eq!(
2811 unsafe { &(*(::std::ptr::null::<rb_unblock_callback>())).func as *const _ as usize },
2812 0usize,
2813 concat!(
2814 "Offset of field: ",
2815 stringify!(rb_unblock_callback),
2816 "::",
2817 stringify!(func)
2818 )
2819 );
2820 assert_eq!(
2821 unsafe { &(*(::std::ptr::null::<rb_unblock_callback>())).arg as *const _ as usize },
2822 8usize,
2823 concat!(
2824 "Offset of field: ",
2825 stringify!(rb_unblock_callback),
2826 "::",
2827 stringify!(arg)
2828 )
2829 );
2830}
2831#[repr(C)]
2832#[derive(Debug, Copy, Clone)]
2833pub struct rb_mutex_struct {
2834 _unused: [u8; 0],
2835}
2836#[repr(C)]
2837#[derive(Copy, Clone)]
2838pub struct rb_thread_struct {
2839 pub self_: VALUE,
2840 pub vm: *mut rb_vm_t,
2841 pub stack: *mut VALUE,
2842 pub stack_size: ::std::os::raw::c_ulong,
2843 pub cfp: *mut rb_control_frame_t,
2844 pub safe_level: ::std::os::raw::c_int,
2845 pub raised_flag: ::std::os::raw::c_int,
2846 pub last_status: VALUE,
2847 pub state: ::std::os::raw::c_int,
2848 pub passed_block: *mut rb_block_t,
2849 pub top_self: VALUE,
2850 pub top_wrapper: VALUE,
2851 pub base_block: *mut rb_block_t,
2852 pub local_lfp: *mut VALUE,
2853 pub local_svar: VALUE,
2854 pub thread_id: rb_thread_id_t,
2855 pub status: rb_thread_status,
2856 pub priority: ::std::os::raw::c_int,
2857 pub slice: ::std::os::raw::c_int,
2858 pub native_thread_data: native_thread_data_t,
2859 pub blocking_region_buffer: *mut ::std::os::raw::c_void,
2860 pub thgroup: VALUE,
2861 pub value: VALUE,
2862 pub errinfo: VALUE,
2863 pub thrown_errinfo: VALUE,
2864 pub exec_signal: ::std::os::raw::c_int,
2865 pub interrupt_flag: ::std::os::raw::c_int,
2866 pub interrupt_lock: rb_thread_lock_t,
2867 pub unblock: rb_unblock_callback,
2868 pub locking_mutex: VALUE,
2869 pub keeping_mutexes: *mut rb_mutex_struct,
2870 pub transition_for_lock: ::std::os::raw::c_int,
2871 pub tag: *mut rb_vm_tag,
2872 pub trap_tag: *mut rb_vm_trap_tag,
2873 pub parse_in_eval: ::std::os::raw::c_int,
2874 pub mild_compile_error: ::std::os::raw::c_int,
2875 pub local_storage: *mut st_table,
2876 pub join_list_next: *mut rb_thread_struct,
2877 pub join_list_head: *mut rb_thread_struct,
2878 pub first_proc: VALUE,
2879 pub first_args: VALUE,
2880 pub first_func: ::std::option::Option<unsafe extern "C" fn() -> VALUE>,
2881 pub machine_stack_start: *mut VALUE,
2882 pub machine_stack_end: *mut VALUE,
2883 pub machine_stack_maxsize: usize,
2884 pub machine_regs: jmp_buf,
2885 pub mark_stack_len: ::std::os::raw::c_int,
2886 pub stat_insn_usage: VALUE,
2887 pub event_hooks: *mut rb_event_hook_t,
2888 pub event_flags: rb_event_flag_t,
2889 pub tracing: ::std::os::raw::c_int,
2890 pub fiber: VALUE,
2891 pub root_fiber: VALUE,
2892 pub root_jmpbuf: rb_jmpbuf_t,
2893 pub method_missing_reason: ::std::os::raw::c_int,
2894 pub abort_on_exception: ::std::os::raw::c_int,
2895}
2896#[test]
2897fn bindgen_test_layout_rb_thread_struct() {
2898 assert_eq!(
2899 ::std::mem::size_of::<rb_thread_struct>(),
2900 872usize,
2901 concat!("Size of: ", stringify!(rb_thread_struct))
2902 );
2903 assert_eq!(
2904 ::std::mem::align_of::<rb_thread_struct>(),
2905 8usize,
2906 concat!("Alignment of ", stringify!(rb_thread_struct))
2907 );
2908 assert_eq!(
2909 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).self_ as *const _ as usize },
2910 0usize,
2911 concat!(
2912 "Offset of field: ",
2913 stringify!(rb_thread_struct),
2914 "::",
2915 stringify!(self_)
2916 )
2917 );
2918 assert_eq!(
2919 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).vm as *const _ as usize },
2920 8usize,
2921 concat!(
2922 "Offset of field: ",
2923 stringify!(rb_thread_struct),
2924 "::",
2925 stringify!(vm)
2926 )
2927 );
2928 assert_eq!(
2929 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).stack as *const _ as usize },
2930 16usize,
2931 concat!(
2932 "Offset of field: ",
2933 stringify!(rb_thread_struct),
2934 "::",
2935 stringify!(stack)
2936 )
2937 );
2938 assert_eq!(
2939 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).stack_size as *const _ as usize },
2940 24usize,
2941 concat!(
2942 "Offset of field: ",
2943 stringify!(rb_thread_struct),
2944 "::",
2945 stringify!(stack_size)
2946 )
2947 );
2948 assert_eq!(
2949 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).cfp as *const _ as usize },
2950 32usize,
2951 concat!(
2952 "Offset of field: ",
2953 stringify!(rb_thread_struct),
2954 "::",
2955 stringify!(cfp)
2956 )
2957 );
2958 assert_eq!(
2959 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).safe_level as *const _ as usize },
2960 40usize,
2961 concat!(
2962 "Offset of field: ",
2963 stringify!(rb_thread_struct),
2964 "::",
2965 stringify!(safe_level)
2966 )
2967 );
2968 assert_eq!(
2969 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).raised_flag as *const _ as usize },
2970 44usize,
2971 concat!(
2972 "Offset of field: ",
2973 stringify!(rb_thread_struct),
2974 "::",
2975 stringify!(raised_flag)
2976 )
2977 );
2978 assert_eq!(
2979 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).last_status as *const _ as usize },
2980 48usize,
2981 concat!(
2982 "Offset of field: ",
2983 stringify!(rb_thread_struct),
2984 "::",
2985 stringify!(last_status)
2986 )
2987 );
2988 assert_eq!(
2989 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).state as *const _ as usize },
2990 56usize,
2991 concat!(
2992 "Offset of field: ",
2993 stringify!(rb_thread_struct),
2994 "::",
2995 stringify!(state)
2996 )
2997 );
2998 assert_eq!(
2999 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).passed_block as *const _ as usize },
3000 64usize,
3001 concat!(
3002 "Offset of field: ",
3003 stringify!(rb_thread_struct),
3004 "::",
3005 stringify!(passed_block)
3006 )
3007 );
3008 assert_eq!(
3009 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).top_self as *const _ as usize },
3010 72usize,
3011 concat!(
3012 "Offset of field: ",
3013 stringify!(rb_thread_struct),
3014 "::",
3015 stringify!(top_self)
3016 )
3017 );
3018 assert_eq!(
3019 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).top_wrapper as *const _ as usize },
3020 80usize,
3021 concat!(
3022 "Offset of field: ",
3023 stringify!(rb_thread_struct),
3024 "::",
3025 stringify!(top_wrapper)
3026 )
3027 );
3028 assert_eq!(
3029 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).base_block as *const _ as usize },
3030 88usize,
3031 concat!(
3032 "Offset of field: ",
3033 stringify!(rb_thread_struct),
3034 "::",
3035 stringify!(base_block)
3036 )
3037 );
3038 assert_eq!(
3039 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).local_lfp as *const _ as usize },
3040 96usize,
3041 concat!(
3042 "Offset of field: ",
3043 stringify!(rb_thread_struct),
3044 "::",
3045 stringify!(local_lfp)
3046 )
3047 );
3048 assert_eq!(
3049 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).local_svar as *const _ as usize },
3050 104usize,
3051 concat!(
3052 "Offset of field: ",
3053 stringify!(rb_thread_struct),
3054 "::",
3055 stringify!(local_svar)
3056 )
3057 );
3058 assert_eq!(
3059 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).thread_id as *const _ as usize },
3060 112usize,
3061 concat!(
3062 "Offset of field: ",
3063 stringify!(rb_thread_struct),
3064 "::",
3065 stringify!(thread_id)
3066 )
3067 );
3068 assert_eq!(
3069 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).status as *const _ as usize },
3070 120usize,
3071 concat!(
3072 "Offset of field: ",
3073 stringify!(rb_thread_struct),
3074 "::",
3075 stringify!(status)
3076 )
3077 );
3078 assert_eq!(
3079 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).priority as *const _ as usize },
3080 124usize,
3081 concat!(
3082 "Offset of field: ",
3083 stringify!(rb_thread_struct),
3084 "::",
3085 stringify!(priority)
3086 )
3087 );
3088 assert_eq!(
3089 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).slice as *const _ as usize },
3090 128usize,
3091 concat!(
3092 "Offset of field: ",
3093 stringify!(rb_thread_struct),
3094 "::",
3095 stringify!(slice)
3096 )
3097 );
3098 assert_eq!(
3099 unsafe {
3100 &(*(::std::ptr::null::<rb_thread_struct>())).native_thread_data as *const _ as usize
3101 },
3102 136usize,
3103 concat!(
3104 "Offset of field: ",
3105 stringify!(rb_thread_struct),
3106 "::",
3107 stringify!(native_thread_data)
3108 )
3109 );
3110 assert_eq!(
3111 unsafe {
3112 &(*(::std::ptr::null::<rb_thread_struct>())).blocking_region_buffer as *const _ as usize
3113 },
3114 192usize,
3115 concat!(
3116 "Offset of field: ",
3117 stringify!(rb_thread_struct),
3118 "::",
3119 stringify!(blocking_region_buffer)
3120 )
3121 );
3122 assert_eq!(
3123 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).thgroup as *const _ as usize },
3124 200usize,
3125 concat!(
3126 "Offset of field: ",
3127 stringify!(rb_thread_struct),
3128 "::",
3129 stringify!(thgroup)
3130 )
3131 );
3132 assert_eq!(
3133 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).value as *const _ as usize },
3134 208usize,
3135 concat!(
3136 "Offset of field: ",
3137 stringify!(rb_thread_struct),
3138 "::",
3139 stringify!(value)
3140 )
3141 );
3142 assert_eq!(
3143 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).errinfo as *const _ as usize },
3144 216usize,
3145 concat!(
3146 "Offset of field: ",
3147 stringify!(rb_thread_struct),
3148 "::",
3149 stringify!(errinfo)
3150 )
3151 );
3152 assert_eq!(
3153 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).thrown_errinfo as *const _ as usize },
3154 224usize,
3155 concat!(
3156 "Offset of field: ",
3157 stringify!(rb_thread_struct),
3158 "::",
3159 stringify!(thrown_errinfo)
3160 )
3161 );
3162 assert_eq!(
3163 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).exec_signal as *const _ as usize },
3164 232usize,
3165 concat!(
3166 "Offset of field: ",
3167 stringify!(rb_thread_struct),
3168 "::",
3169 stringify!(exec_signal)
3170 )
3171 );
3172 assert_eq!(
3173 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).interrupt_flag as *const _ as usize },
3174 236usize,
3175 concat!(
3176 "Offset of field: ",
3177 stringify!(rb_thread_struct),
3178 "::",
3179 stringify!(interrupt_flag)
3180 )
3181 );
3182 assert_eq!(
3183 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).interrupt_lock as *const _ as usize },
3184 240usize,
3185 concat!(
3186 "Offset of field: ",
3187 stringify!(rb_thread_struct),
3188 "::",
3189 stringify!(interrupt_lock)
3190 )
3191 );
3192 assert_eq!(
3193 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).unblock as *const _ as usize },
3194 280usize,
3195 concat!(
3196 "Offset of field: ",
3197 stringify!(rb_thread_struct),
3198 "::",
3199 stringify!(unblock)
3200 )
3201 );
3202 assert_eq!(
3203 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).locking_mutex as *const _ as usize },
3204 296usize,
3205 concat!(
3206 "Offset of field: ",
3207 stringify!(rb_thread_struct),
3208 "::",
3209 stringify!(locking_mutex)
3210 )
3211 );
3212 assert_eq!(
3213 unsafe {
3214 &(*(::std::ptr::null::<rb_thread_struct>())).keeping_mutexes as *const _ as usize
3215 },
3216 304usize,
3217 concat!(
3218 "Offset of field: ",
3219 stringify!(rb_thread_struct),
3220 "::",
3221 stringify!(keeping_mutexes)
3222 )
3223 );
3224 assert_eq!(
3225 unsafe {
3226 &(*(::std::ptr::null::<rb_thread_struct>())).transition_for_lock as *const _ as usize
3227 },
3228 312usize,
3229 concat!(
3230 "Offset of field: ",
3231 stringify!(rb_thread_struct),
3232 "::",
3233 stringify!(transition_for_lock)
3234 )
3235 );
3236 assert_eq!(
3237 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).tag as *const _ as usize },
3238 320usize,
3239 concat!(
3240 "Offset of field: ",
3241 stringify!(rb_thread_struct),
3242 "::",
3243 stringify!(tag)
3244 )
3245 );
3246 assert_eq!(
3247 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).trap_tag as *const _ as usize },
3248 328usize,
3249 concat!(
3250 "Offset of field: ",
3251 stringify!(rb_thread_struct),
3252 "::",
3253 stringify!(trap_tag)
3254 )
3255 );
3256 assert_eq!(
3257 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).parse_in_eval as *const _ as usize },
3258 336usize,
3259 concat!(
3260 "Offset of field: ",
3261 stringify!(rb_thread_struct),
3262 "::",
3263 stringify!(parse_in_eval)
3264 )
3265 );
3266 assert_eq!(
3267 unsafe {
3268 &(*(::std::ptr::null::<rb_thread_struct>())).mild_compile_error as *const _ as usize
3269 },
3270 340usize,
3271 concat!(
3272 "Offset of field: ",
3273 stringify!(rb_thread_struct),
3274 "::",
3275 stringify!(mild_compile_error)
3276 )
3277 );
3278 assert_eq!(
3279 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).local_storage as *const _ as usize },
3280 344usize,
3281 concat!(
3282 "Offset of field: ",
3283 stringify!(rb_thread_struct),
3284 "::",
3285 stringify!(local_storage)
3286 )
3287 );
3288 assert_eq!(
3289 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).join_list_next as *const _ as usize },
3290 352usize,
3291 concat!(
3292 "Offset of field: ",
3293 stringify!(rb_thread_struct),
3294 "::",
3295 stringify!(join_list_next)
3296 )
3297 );
3298 assert_eq!(
3299 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).join_list_head as *const _ as usize },
3300 360usize,
3301 concat!(
3302 "Offset of field: ",
3303 stringify!(rb_thread_struct),
3304 "::",
3305 stringify!(join_list_head)
3306 )
3307 );
3308 assert_eq!(
3309 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).first_proc as *const _ as usize },
3310 368usize,
3311 concat!(
3312 "Offset of field: ",
3313 stringify!(rb_thread_struct),
3314 "::",
3315 stringify!(first_proc)
3316 )
3317 );
3318 assert_eq!(
3319 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).first_args as *const _ as usize },
3320 376usize,
3321 concat!(
3322 "Offset of field: ",
3323 stringify!(rb_thread_struct),
3324 "::",
3325 stringify!(first_args)
3326 )
3327 );
3328 assert_eq!(
3329 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).first_func as *const _ as usize },
3330 384usize,
3331 concat!(
3332 "Offset of field: ",
3333 stringify!(rb_thread_struct),
3334 "::",
3335 stringify!(first_func)
3336 )
3337 );
3338 assert_eq!(
3339 unsafe {
3340 &(*(::std::ptr::null::<rb_thread_struct>())).machine_stack_start as *const _ as usize
3341 },
3342 392usize,
3343 concat!(
3344 "Offset of field: ",
3345 stringify!(rb_thread_struct),
3346 "::",
3347 stringify!(machine_stack_start)
3348 )
3349 );
3350 assert_eq!(
3351 unsafe {
3352 &(*(::std::ptr::null::<rb_thread_struct>())).machine_stack_end as *const _ as usize
3353 },
3354 400usize,
3355 concat!(
3356 "Offset of field: ",
3357 stringify!(rb_thread_struct),
3358 "::",
3359 stringify!(machine_stack_end)
3360 )
3361 );
3362 assert_eq!(
3363 unsafe {
3364 &(*(::std::ptr::null::<rb_thread_struct>())).machine_stack_maxsize as *const _ as usize
3365 },
3366 408usize,
3367 concat!(
3368 "Offset of field: ",
3369 stringify!(rb_thread_struct),
3370 "::",
3371 stringify!(machine_stack_maxsize)
3372 )
3373 );
3374 assert_eq!(
3375 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).machine_regs as *const _ as usize },
3376 416usize,
3377 concat!(
3378 "Offset of field: ",
3379 stringify!(rb_thread_struct),
3380 "::",
3381 stringify!(machine_regs)
3382 )
3383 );
3384 assert_eq!(
3385 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).mark_stack_len as *const _ as usize },
3386 616usize,
3387 concat!(
3388 "Offset of field: ",
3389 stringify!(rb_thread_struct),
3390 "::",
3391 stringify!(mark_stack_len)
3392 )
3393 );
3394 assert_eq!(
3395 unsafe {
3396 &(*(::std::ptr::null::<rb_thread_struct>())).stat_insn_usage as *const _ as usize
3397 },
3398 624usize,
3399 concat!(
3400 "Offset of field: ",
3401 stringify!(rb_thread_struct),
3402 "::",
3403 stringify!(stat_insn_usage)
3404 )
3405 );
3406 assert_eq!(
3407 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).event_hooks as *const _ as usize },
3408 632usize,
3409 concat!(
3410 "Offset of field: ",
3411 stringify!(rb_thread_struct),
3412 "::",
3413 stringify!(event_hooks)
3414 )
3415 );
3416 assert_eq!(
3417 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).event_flags as *const _ as usize },
3418 640usize,
3419 concat!(
3420 "Offset of field: ",
3421 stringify!(rb_thread_struct),
3422 "::",
3423 stringify!(event_flags)
3424 )
3425 );
3426 assert_eq!(
3427 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).tracing as *const _ as usize },
3428 644usize,
3429 concat!(
3430 "Offset of field: ",
3431 stringify!(rb_thread_struct),
3432 "::",
3433 stringify!(tracing)
3434 )
3435 );
3436 assert_eq!(
3437 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).fiber as *const _ as usize },
3438 648usize,
3439 concat!(
3440 "Offset of field: ",
3441 stringify!(rb_thread_struct),
3442 "::",
3443 stringify!(fiber)
3444 )
3445 );
3446 assert_eq!(
3447 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).root_fiber as *const _ as usize },
3448 656usize,
3449 concat!(
3450 "Offset of field: ",
3451 stringify!(rb_thread_struct),
3452 "::",
3453 stringify!(root_fiber)
3454 )
3455 );
3456 assert_eq!(
3457 unsafe { &(*(::std::ptr::null::<rb_thread_struct>())).root_jmpbuf as *const _ as usize },
3458 664usize,
3459 concat!(
3460 "Offset of field: ",
3461 stringify!(rb_thread_struct),
3462 "::",
3463 stringify!(root_jmpbuf)
3464 )
3465 );
3466 assert_eq!(
3467 unsafe {
3468 &(*(::std::ptr::null::<rb_thread_struct>())).method_missing_reason as *const _ as usize
3469 },
3470 864usize,
3471 concat!(
3472 "Offset of field: ",
3473 stringify!(rb_thread_struct),
3474 "::",
3475 stringify!(method_missing_reason)
3476 )
3477 );
3478 assert_eq!(
3479 unsafe {
3480 &(*(::std::ptr::null::<rb_thread_struct>())).abort_on_exception as *const _ as usize
3481 },
3482 868usize,
3483 concat!(
3484 "Offset of field: ",
3485 stringify!(rb_thread_struct),
3486 "::",
3487 stringify!(abort_on_exception)
3488 )
3489 );
3490}
3491impl ::std::fmt::Debug for rb_thread_struct {
3492 fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
3493 write ! ( f , "rb_thread_struct {{ self: {:?}, vm: {:?}, stack: {:?}, stack_size: {:?}, cfp: {:?}, safe_level: {:?}, raised_flag: {:?}, last_status: {:?}, state: {:?}, passed_block: {:?}, top_self: {:?}, top_wrapper: {:?}, base_block: {:?}, local_lfp: {:?}, local_svar: {:?}, thread_id: {:?}, status: {:?}, priority: {:?}, slice: {:?}, native_thread_data: {:?}, blocking_region_buffer: {:?}, thgroup: {:?}, value: {:?}, errinfo: {:?}, thrown_errinfo: {:?}, exec_signal: {:?}, interrupt_flag: {:?}, interrupt_lock: {:?}, unblock: {:?}, locking_mutex: {:?}, keeping_mutexes: {:?}, transition_for_lock: {:?}, tag: {:?}, trap_tag: {:?}, parse_in_eval: {:?}, mild_compile_error: {:?}, local_storage: {:?}, join_list_next: {:?}, join_list_head: {:?}, first_proc: {:?}, first_args: {:?}, first_func: {:?}, machine_stack_start: {:?}, machine_stack_end: {:?}, machine_stack_maxsize: {:?}, machine_regs: {:?}, mark_stack_len: {:?}, stat_insn_usage: {:?}, event_hooks: {:?}, event_flags: {:?}, tracing: {:?}, fiber: {:?}, root_fiber: {:?}, root_jmpbuf: {:?}, method_missing_reason: {:?}, abort_on_exception: {:?} }}" , self . self_ , self . vm , self . stack , self . stack_size , self . cfp , self . safe_level , self . raised_flag , self . last_status , self . state , self . passed_block , self . top_self , self . top_wrapper , self . base_block , self . local_lfp , self . local_svar , self . thread_id , self . status , self . priority , self . slice , self . native_thread_data , self . blocking_region_buffer , self . thgroup , self . value , self . errinfo , self . thrown_errinfo , self . exec_signal , self . interrupt_flag , self . interrupt_lock , self . unblock , self . locking_mutex , self . keeping_mutexes , self . transition_for_lock , self . tag , self . trap_tag , self . parse_in_eval , self . mild_compile_error , self . local_storage , self . join_list_next , self . join_list_head , self . first_proc , self . first_args , self . first_func , self . machine_stack_start , self . machine_stack_end , self . machine_stack_maxsize , self . machine_regs , self . mark_stack_len , self . stat_insn_usage , self . event_hooks , self . event_flags , self . tracing , self . fiber , self . root_fiber , self . root_jmpbuf , self . method_missing_reason , self . abort_on_exception )
3494 }
3495}
3496pub type rb_thread_t = rb_thread_struct;
3497#[repr(C)]
3498#[derive(Debug, Copy, Clone)]
3499pub struct global_entry {
3500 pub var: *mut global_variable,
3501 pub id: ID,
3502}
3503#[test]
3504fn bindgen_test_layout_global_entry() {
3505 assert_eq!(
3506 ::std::mem::size_of::<global_entry>(),
3507 16usize,
3508 concat!("Size of: ", stringify!(global_entry))
3509 );
3510 assert_eq!(
3511 ::std::mem::align_of::<global_entry>(),
3512 8usize,
3513 concat!("Alignment of ", stringify!(global_entry))
3514 );
3515 assert_eq!(
3516 unsafe { &(*(::std::ptr::null::<global_entry>())).var as *const _ as usize },
3517 0usize,
3518 concat!(
3519 "Offset of field: ",
3520 stringify!(global_entry),
3521 "::",
3522 stringify!(var)
3523 )
3524 );
3525 assert_eq!(
3526 unsafe { &(*(::std::ptr::null::<global_entry>())).id as *const _ as usize },
3527 8usize,
3528 concat!(
3529 "Offset of field: ",
3530 stringify!(global_entry),
3531 "::",
3532 stringify!(id)
3533 )
3534 );
3535}
3536#[repr(C)]
3537#[derive(Debug, Copy, Clone)]
3538pub struct iseq_insn_info_entry {
3539 pub position: ::std::os::raw::c_ushort,
3540 pub line_no: ::std::os::raw::c_ushort,
3541 pub sp: ::std::os::raw::c_ushort,
3542}
3543#[test]
3544fn bindgen_test_layout_iseq_insn_info_entry() {
3545 assert_eq!(
3546 ::std::mem::size_of::<iseq_insn_info_entry>(),
3547 6usize,
3548 concat!("Size of: ", stringify!(iseq_insn_info_entry))
3549 );
3550 assert_eq!(
3551 ::std::mem::align_of::<iseq_insn_info_entry>(),
3552 2usize,
3553 concat!("Alignment of ", stringify!(iseq_insn_info_entry))
3554 );
3555 assert_eq!(
3556 unsafe { &(*(::std::ptr::null::<iseq_insn_info_entry>())).position as *const _ as usize },
3557 0usize,
3558 concat!(
3559 "Offset of field: ",
3560 stringify!(iseq_insn_info_entry),
3561 "::",
3562 stringify!(position)
3563 )
3564 );
3565 assert_eq!(
3566 unsafe { &(*(::std::ptr::null::<iseq_insn_info_entry>())).line_no as *const _ as usize },
3567 2usize,
3568 concat!(
3569 "Offset of field: ",
3570 stringify!(iseq_insn_info_entry),
3571 "::",
3572 stringify!(line_no)
3573 )
3574 );
3575 assert_eq!(
3576 unsafe { &(*(::std::ptr::null::<iseq_insn_info_entry>())).sp as *const _ as usize },
3577 4usize,
3578 concat!(
3579 "Offset of field: ",
3580 stringify!(iseq_insn_info_entry),
3581 "::",
3582 stringify!(sp)
3583 )
3584 );
3585}
3586#[repr(C)]
3587#[derive(Debug, Copy, Clone)]
3588pub struct iseq_catch_table_entry {
3589 pub type_: VALUE,
3590 pub iseq: VALUE,
3591 pub start: ::std::os::raw::c_ulong,
3592 pub end: ::std::os::raw::c_ulong,
3593 pub cont: ::std::os::raw::c_ulong,
3594 pub sp: ::std::os::raw::c_ulong,
3595}
3596#[test]
3597fn bindgen_test_layout_iseq_catch_table_entry() {
3598 assert_eq!(
3599 ::std::mem::size_of::<iseq_catch_table_entry>(),
3600 48usize,
3601 concat!("Size of: ", stringify!(iseq_catch_table_entry))
3602 );
3603 assert_eq!(
3604 ::std::mem::align_of::<iseq_catch_table_entry>(),
3605 8usize,
3606 concat!("Alignment of ", stringify!(iseq_catch_table_entry))
3607 );
3608 assert_eq!(
3609 unsafe { &(*(::std::ptr::null::<iseq_catch_table_entry>())).type_ as *const _ as usize },
3610 0usize,
3611 concat!(
3612 "Offset of field: ",
3613 stringify!(iseq_catch_table_entry),
3614 "::",
3615 stringify!(type_)
3616 )
3617 );
3618 assert_eq!(
3619 unsafe { &(*(::std::ptr::null::<iseq_catch_table_entry>())).iseq as *const _ as usize },
3620 8usize,
3621 concat!(
3622 "Offset of field: ",
3623 stringify!(iseq_catch_table_entry),
3624 "::",
3625 stringify!(iseq)
3626 )
3627 );
3628 assert_eq!(
3629 unsafe { &(*(::std::ptr::null::<iseq_catch_table_entry>())).start as *const _ as usize },
3630 16usize,
3631 concat!(
3632 "Offset of field: ",
3633 stringify!(iseq_catch_table_entry),
3634 "::",
3635 stringify!(start)
3636 )
3637 );
3638 assert_eq!(
3639 unsafe { &(*(::std::ptr::null::<iseq_catch_table_entry>())).end as *const _ as usize },
3640 24usize,
3641 concat!(
3642 "Offset of field: ",
3643 stringify!(iseq_catch_table_entry),
3644 "::",
3645 stringify!(end)
3646 )
3647 );
3648 assert_eq!(
3649 unsafe { &(*(::std::ptr::null::<iseq_catch_table_entry>())).cont as *const _ as usize },
3650 32usize,
3651 concat!(
3652 "Offset of field: ",
3653 stringify!(iseq_catch_table_entry),
3654 "::",
3655 stringify!(cont)
3656 )
3657 );
3658 assert_eq!(
3659 unsafe { &(*(::std::ptr::null::<iseq_catch_table_entry>())).sp as *const _ as usize },
3660 40usize,
3661 concat!(
3662 "Offset of field: ",
3663 stringify!(iseq_catch_table_entry),
3664 "::",
3665 stringify!(sp)
3666 )
3667 );
3668}
3669#[repr(C)]
3670#[derive(Debug, Copy, Clone)]
3671pub struct iseq_compile_data_storage {
3672 pub next: *mut iseq_compile_data_storage,
3673 pub pos: ::std::os::raw::c_ulong,
3674 pub size: ::std::os::raw::c_ulong,
3675 pub buff: *mut ::std::os::raw::c_char,
3676}
3677#[test]
3678fn bindgen_test_layout_iseq_compile_data_storage() {
3679 assert_eq!(
3680 ::std::mem::size_of::<iseq_compile_data_storage>(),
3681 32usize,
3682 concat!("Size of: ", stringify!(iseq_compile_data_storage))
3683 );
3684 assert_eq!(
3685 ::std::mem::align_of::<iseq_compile_data_storage>(),
3686 8usize,
3687 concat!("Alignment of ", stringify!(iseq_compile_data_storage))
3688 );
3689 assert_eq!(
3690 unsafe { &(*(::std::ptr::null::<iseq_compile_data_storage>())).next as *const _ as usize },
3691 0usize,
3692 concat!(
3693 "Offset of field: ",
3694 stringify!(iseq_compile_data_storage),
3695 "::",
3696 stringify!(next)
3697 )
3698 );
3699 assert_eq!(
3700 unsafe { &(*(::std::ptr::null::<iseq_compile_data_storage>())).pos as *const _ as usize },
3701 8usize,
3702 concat!(
3703 "Offset of field: ",
3704 stringify!(iseq_compile_data_storage),
3705 "::",
3706 stringify!(pos)
3707 )
3708 );
3709 assert_eq!(
3710 unsafe { &(*(::std::ptr::null::<iseq_compile_data_storage>())).size as *const _ as usize },
3711 16usize,
3712 concat!(
3713 "Offset of field: ",
3714 stringify!(iseq_compile_data_storage),
3715 "::",
3716 stringify!(size)
3717 )
3718 );
3719 assert_eq!(
3720 unsafe { &(*(::std::ptr::null::<iseq_compile_data_storage>())).buff as *const _ as usize },
3721 24usize,
3722 concat!(
3723 "Offset of field: ",
3724 stringify!(iseq_compile_data_storage),
3725 "::",
3726 stringify!(buff)
3727 )
3728 );
3729}
3730#[repr(C)]
3731#[derive(Debug, Copy, Clone)]
3732pub struct iseq_compile_data {
3733 pub err_info: VALUE,
3734 pub mark_ary: VALUE,
3735 pub catch_table_ary: VALUE,
3736 pub start_label: *mut iseq_label_data,
3737 pub end_label: *mut iseq_label_data,
3738 pub redo_label: *mut iseq_label_data,
3739 pub current_block: VALUE,
3740 pub loopval_popped: VALUE,
3741 pub ensure_node: VALUE,
3742 pub for_iseq: VALUE,
3743 pub ensure_node_stack: *mut iseq_compile_data_ensure_node_stack,
3744 pub cached_const: ::std::os::raw::c_int,
3745 pub storage_head: *mut iseq_compile_data_storage,
3746 pub storage_current: *mut iseq_compile_data_storage,
3747 pub last_line: ::std::os::raw::c_int,
3748 pub flip_cnt: ::std::os::raw::c_int,
3749 pub label_no: ::std::os::raw::c_int,
3750 pub node_level: ::std::os::raw::c_int,
3751 pub option: *const rb_compile_option_t,
3752}
3753#[test]
3754fn bindgen_test_layout_iseq_compile_data() {
3755 assert_eq!(
3756 ::std::mem::size_of::<iseq_compile_data>(),
3757 136usize,
3758 concat!("Size of: ", stringify!(iseq_compile_data))
3759 );
3760 assert_eq!(
3761 ::std::mem::align_of::<iseq_compile_data>(),
3762 8usize,
3763 concat!("Alignment of ", stringify!(iseq_compile_data))
3764 );
3765 assert_eq!(
3766 unsafe { &(*(::std::ptr::null::<iseq_compile_data>())).err_info as *const _ as usize },
3767 0usize,
3768 concat!(
3769 "Offset of field: ",
3770 stringify!(iseq_compile_data),
3771 "::",
3772 stringify!(err_info)
3773 )
3774 );
3775 assert_eq!(
3776 unsafe { &(*(::std::ptr::null::<iseq_compile_data>())).mark_ary as *const _ as usize },
3777 8usize,
3778 concat!(
3779 "Offset of field: ",
3780 stringify!(iseq_compile_data),
3781 "::",
3782 stringify!(mark_ary)
3783 )
3784 );
3785 assert_eq!(
3786 unsafe {
3787 &(*(::std::ptr::null::<iseq_compile_data>())).catch_table_ary as *const _ as usize
3788 },
3789 16usize,
3790 concat!(
3791 "Offset of field: ",
3792 stringify!(iseq_compile_data),
3793 "::",
3794 stringify!(catch_table_ary)
3795 )
3796 );
3797 assert_eq!(
3798 unsafe { &(*(::std::ptr::null::<iseq_compile_data>())).start_label as *const _ as usize },
3799 24usize,
3800 concat!(
3801 "Offset of field: ",
3802 stringify!(iseq_compile_data),
3803 "::",
3804 stringify!(start_label)
3805 )
3806 );
3807 assert_eq!(
3808 unsafe { &(*(::std::ptr::null::<iseq_compile_data>())).end_label as *const _ as usize },
3809 32usize,
3810 concat!(
3811 "Offset of field: ",
3812 stringify!(iseq_compile_data),
3813 "::",
3814 stringify!(end_label)
3815 )
3816 );
3817 assert_eq!(
3818 unsafe { &(*(::std::ptr::null::<iseq_compile_data>())).redo_label as *const _ as usize },
3819 40usize,
3820 concat!(
3821 "Offset of field: ",
3822 stringify!(iseq_compile_data),
3823 "::",
3824 stringify!(redo_label)
3825 )
3826 );
3827 assert_eq!(
3828 unsafe { &(*(::std::ptr::null::<iseq_compile_data>())).current_block as *const _ as usize },
3829 48usize,
3830 concat!(
3831 "Offset of field: ",
3832 stringify!(iseq_compile_data),
3833 "::",
3834 stringify!(current_block)
3835 )
3836 );
3837 assert_eq!(
3838 unsafe {
3839 &(*(::std::ptr::null::<iseq_compile_data>())).loopval_popped as *const _ as usize
3840 },
3841 56usize,
3842 concat!(
3843 "Offset of field: ",
3844 stringify!(iseq_compile_data),
3845 "::",
3846 stringify!(loopval_popped)
3847 )
3848 );
3849 assert_eq!(
3850 unsafe { &(*(::std::ptr::null::<iseq_compile_data>())).ensure_node as *const _ as usize },
3851 64usize,
3852 concat!(
3853 "Offset of field: ",
3854 stringify!(iseq_compile_data),
3855 "::",
3856 stringify!(ensure_node)
3857 )
3858 );
3859 assert_eq!(
3860 unsafe { &(*(::std::ptr::null::<iseq_compile_data>())).for_iseq as *const _ as usize },
3861 72usize,
3862 concat!(
3863 "Offset of field: ",
3864 stringify!(iseq_compile_data),
3865 "::",
3866 stringify!(for_iseq)
3867 )
3868 );
3869 assert_eq!(
3870 unsafe {
3871 &(*(::std::ptr::null::<iseq_compile_data>())).ensure_node_stack as *const _ as usize
3872 },
3873 80usize,
3874 concat!(
3875 "Offset of field: ",
3876 stringify!(iseq_compile_data),
3877 "::",
3878 stringify!(ensure_node_stack)
3879 )
3880 );
3881 assert_eq!(
3882 unsafe { &(*(::std::ptr::null::<iseq_compile_data>())).cached_const as *const _ as usize },
3883 88usize,
3884 concat!(
3885 "Offset of field: ",
3886 stringify!(iseq_compile_data),
3887 "::",
3888 stringify!(cached_const)
3889 )
3890 );
3891 assert_eq!(
3892 unsafe { &(*(::std::ptr::null::<iseq_compile_data>())).storage_head as *const _ as usize },
3893 96usize,
3894 concat!(
3895 "Offset of field: ",
3896 stringify!(iseq_compile_data),
3897 "::",
3898 stringify!(storage_head)
3899 )
3900 );
3901 assert_eq!(
3902 unsafe {
3903 &(*(::std::ptr::null::<iseq_compile_data>())).storage_current as *const _ as usize
3904 },
3905 104usize,
3906 concat!(
3907 "Offset of field: ",
3908 stringify!(iseq_compile_data),
3909 "::",
3910 stringify!(storage_current)
3911 )
3912 );
3913 assert_eq!(
3914 unsafe { &(*(::std::ptr::null::<iseq_compile_data>())).last_line as *const _ as usize },
3915 112usize,
3916 concat!(
3917 "Offset of field: ",
3918 stringify!(iseq_compile_data),
3919 "::",
3920 stringify!(last_line)
3921 )
3922 );
3923 assert_eq!(
3924 unsafe { &(*(::std::ptr::null::<iseq_compile_data>())).flip_cnt as *const _ as usize },
3925 116usize,
3926 concat!(
3927 "Offset of field: ",
3928 stringify!(iseq_compile_data),
3929 "::",
3930 stringify!(flip_cnt)
3931 )
3932 );
3933 assert_eq!(
3934 unsafe { &(*(::std::ptr::null::<iseq_compile_data>())).label_no as *const _ as usize },
3935 120usize,
3936 concat!(
3937 "Offset of field: ",
3938 stringify!(iseq_compile_data),
3939 "::",
3940 stringify!(label_no)
3941 )
3942 );
3943 assert_eq!(
3944 unsafe { &(*(::std::ptr::null::<iseq_compile_data>())).node_level as *const _ as usize },
3945 124usize,
3946 concat!(
3947 "Offset of field: ",
3948 stringify!(iseq_compile_data),
3949 "::",
3950 stringify!(node_level)
3951 )
3952 );
3953 assert_eq!(
3954 unsafe { &(*(::std::ptr::null::<iseq_compile_data>())).option as *const _ as usize },
3955 128usize,
3956 concat!(
3957 "Offset of field: ",
3958 stringify!(iseq_compile_data),
3959 "::",
3960 stringify!(option)
3961 )
3962 );
3963}
3964#[repr(C)]
3965#[derive(Debug, Copy, Clone)]
3966pub struct st_table_entry {
3967 pub _address: u8,
3968}
3969#[repr(C)]
3970#[derive(Debug, Copy, Clone)]
3971pub struct global_variable {
3972 pub _address: u8,
3973}
3974#[repr(C)]
3975#[derive(Debug, Copy, Clone)]
3976pub struct iseq_label_data {
3977 pub _address: u8,
3978}