forked from davidcole1340/ext-php-rs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docsrs_bindings.rs
2636 lines (2635 loc) · 88.5 KB
/
docsrs_bindings.rs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
/* automatically generated by rust-bindgen 0.68.1 */
#[repr(C)]
#[derive(Copy, Clone, Debug, Default, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct __BindgenBitfieldUnit<Storage> {
storage: Storage,
}
impl<Storage> __BindgenBitfieldUnit<Storage> {
#[inline]
pub const fn new(storage: Storage) -> Self {
Self { storage }
}
}
impl<Storage> __BindgenBitfieldUnit<Storage>
where
Storage: AsRef<[u8]> + AsMut<[u8]>,
{
#[inline]
pub fn get_bit(&self, index: usize) -> bool {
debug_assert!(index / 8 < self.storage.as_ref().len());
let byte_index = index / 8;
let byte = self.storage.as_ref()[byte_index];
let bit_index = if cfg!(target_endian = "big") {
7 - (index % 8)
} else {
index % 8
};
let mask = 1 << bit_index;
byte & mask == mask
}
#[inline]
pub fn set_bit(&mut self, index: usize, val: bool) {
debug_assert!(index / 8 < self.storage.as_ref().len());
let byte_index = index / 8;
let byte = &mut self.storage.as_mut()[byte_index];
let bit_index = if cfg!(target_endian = "big") {
7 - (index % 8)
} else {
index % 8
};
let mask = 1 << bit_index;
if val {
*byte |= mask;
} else {
*byte &= !mask;
}
}
#[inline]
pub fn get(&self, bit_offset: usize, bit_width: u8) -> u64 {
debug_assert!(bit_width <= 64);
debug_assert!(bit_offset / 8 < self.storage.as_ref().len());
debug_assert!((bit_offset + (bit_width as usize)) / 8 <= self.storage.as_ref().len());
let mut val = 0;
for i in 0..(bit_width as usize) {
if self.get_bit(i + bit_offset) {
let index = if cfg!(target_endian = "big") {
bit_width as usize - 1 - i
} else {
i
};
val |= 1 << index;
}
}
val
}
#[inline]
pub fn set(&mut self, bit_offset: usize, bit_width: u8, val: u64) {
debug_assert!(bit_width <= 64);
debug_assert!(bit_offset / 8 < self.storage.as_ref().len());
debug_assert!((bit_offset + (bit_width as usize)) / 8 <= self.storage.as_ref().len());
for i in 0..(bit_width as usize) {
let mask = 1 << i;
let val_bit_is_set = val & mask == mask;
let index = if cfg!(target_endian = "big") {
bit_width as usize - 1 - i
} else {
i
};
self.set_bit(index + bit_offset, val_bit_is_set);
}
}
}
pub const ZEND_DEBUG: u32 = 1;
pub const _ZEND_TYPE_NAME_BIT: u32 = 16777216;
pub const _ZEND_TYPE_NULLABLE_BIT: u32 = 2;
pub const HT_MIN_SIZE: u32 = 8;
pub const IS_UNDEF: u32 = 0;
pub const IS_NULL: u32 = 1;
pub const IS_FALSE: u32 = 2;
pub const IS_TRUE: u32 = 3;
pub const IS_LONG: u32 = 4;
pub const IS_DOUBLE: u32 = 5;
pub const IS_STRING: u32 = 6;
pub const IS_ARRAY: u32 = 7;
pub const IS_OBJECT: u32 = 8;
pub const IS_RESOURCE: u32 = 9;
pub const IS_REFERENCE: u32 = 10;
pub const IS_CONSTANT_AST: u32 = 11;
pub const IS_CALLABLE: u32 = 12;
pub const IS_ITERABLE: u32 = 13;
pub const IS_VOID: u32 = 14;
pub const IS_MIXED: u32 = 16;
pub const IS_INDIRECT: u32 = 12;
pub const IS_PTR: u32 = 13;
pub const _IS_BOOL: u32 = 18;
pub const Z_TYPE_FLAGS_SHIFT: u32 = 8;
pub const IS_TYPE_REFCOUNTED: u32 = 1;
pub const IS_TYPE_COLLECTABLE: u32 = 2;
pub const IS_INTERNED_STRING_EX: u32 = 6;
pub const IS_STRING_EX: u32 = 262;
pub const IS_ARRAY_EX: u32 = 775;
pub const IS_OBJECT_EX: u32 = 776;
pub const IS_RESOURCE_EX: u32 = 265;
pub const IS_REFERENCE_EX: u32 = 266;
pub const IS_CONSTANT_AST_EX: u32 = 267;
pub const E_ERROR: u32 = 1;
pub const E_WARNING: u32 = 2;
pub const E_PARSE: u32 = 4;
pub const E_NOTICE: u32 = 8;
pub const E_CORE_ERROR: u32 = 16;
pub const E_CORE_WARNING: u32 = 32;
pub const E_COMPILE_ERROR: u32 = 64;
pub const E_COMPILE_WARNING: u32 = 128;
pub const E_USER_ERROR: u32 = 256;
pub const E_USER_WARNING: u32 = 512;
pub const E_USER_NOTICE: u32 = 1024;
pub const E_STRICT: u32 = 2048;
pub const E_RECOVERABLE_ERROR: u32 = 4096;
pub const E_DEPRECATED: u32 = 8192;
pub const E_USER_DEPRECATED: u32 = 16384;
pub const ZEND_PROPERTY_ISSET: u32 = 0;
pub const ZEND_PROPERTY_EXISTS: u32 = 2;
pub const ZEND_ACC_PUBLIC: u32 = 1;
pub const ZEND_ACC_PROTECTED: u32 = 2;
pub const ZEND_ACC_PRIVATE: u32 = 4;
pub const ZEND_ACC_CHANGED: u32 = 8;
pub const ZEND_ACC_STATIC: u32 = 16;
pub const ZEND_ACC_PROMOTED: u32 = 32;
pub const ZEND_ACC_FINAL: u32 = 32;
pub const ZEND_ACC_ABSTRACT: u32 = 64;
pub const ZEND_ACC_IMMUTABLE: u32 = 128;
pub const ZEND_ACC_HAS_TYPE_HINTS: u32 = 256;
pub const ZEND_ACC_TOP_LEVEL: u32 = 512;
pub const ZEND_ACC_PRELOADED: u32 = 1024;
pub const ZEND_ACC_INTERFACE: u32 = 1;
pub const ZEND_ACC_TRAIT: u32 = 2;
pub const ZEND_ACC_ANON_CLASS: u32 = 4;
pub const ZEND_ACC_LINKED: u32 = 8;
pub const ZEND_ACC_IMPLICIT_ABSTRACT_CLASS: u32 = 16;
pub const ZEND_ACC_USE_GUARDS: u32 = 2048;
pub const ZEND_ACC_CONSTANTS_UPDATED: u32 = 4096;
pub const ZEND_ACC_NO_DYNAMIC_PROPERTIES: u32 = 8192;
pub const ZEND_HAS_STATIC_IN_METHODS: u32 = 16384;
pub const ZEND_ACC_RESOLVED_PARENT: u32 = 131072;
pub const ZEND_ACC_RESOLVED_INTERFACES: u32 = 262144;
pub const ZEND_ACC_UNRESOLVED_VARIANCE: u32 = 524288;
pub const ZEND_ACC_NEARLY_LINKED: u32 = 1048576;
pub const ZEND_ACC_NOT_SERIALIZABLE: u32 = 536870912;
pub const ZEND_ACC_DEPRECATED: u32 = 2048;
pub const ZEND_ACC_RETURN_REFERENCE: u32 = 4096;
pub const ZEND_ACC_HAS_RETURN_TYPE: u32 = 8192;
pub const ZEND_ACC_VARIADIC: u32 = 16384;
pub const ZEND_ACC_HAS_FINALLY_BLOCK: u32 = 32768;
pub const ZEND_ACC_EARLY_BINDING: u32 = 65536;
pub const ZEND_ACC_USES_THIS: u32 = 131072;
pub const ZEND_ACC_CALL_VIA_TRAMPOLINE: u32 = 262144;
pub const ZEND_ACC_NEVER_CACHE: u32 = 524288;
pub const ZEND_ACC_TRAIT_CLONE: u32 = 1048576;
pub const ZEND_ACC_CTOR: u32 = 2097152;
pub const ZEND_ACC_CLOSURE: u32 = 4194304;
pub const ZEND_ACC_FAKE_CLOSURE: u32 = 8388608;
pub const ZEND_ACC_GENERATOR: u32 = 16777216;
pub const ZEND_ACC_DONE_PASS_TWO: u32 = 33554432;
pub const ZEND_ACC_HEAP_RT_CACHE: u32 = 67108864;
pub const ZEND_ACC_STRICT_TYPES: u32 = 2147483648;
pub const ZEND_INTERNAL_FUNCTION: u32 = 1;
pub const ZEND_USER_FUNCTION: u32 = 2;
pub const ZEND_EVAL_CODE: u32 = 4;
pub const ZEND_ISEMPTY: u32 = 1;
pub const _ZEND_SEND_MODE_SHIFT: u32 = 25;
pub const _ZEND_IS_VARIADIC_BIT: u32 = 134217728;
pub const ZEND_MODULE_API_NO: u32 = 20230831;
pub const USING_ZTS: u32 = 0;
pub const MAY_BE_BOOL: u32 = 12;
pub const MAY_BE_ANY: u32 = 1022;
pub const TRACK_VARS_POST: u32 = 0;
pub const TRACK_VARS_GET: u32 = 1;
pub const TRACK_VARS_COOKIE: u32 = 2;
pub const TRACK_VARS_SERVER: u32 = 3;
pub const TRACK_VARS_ENV: u32 = 4;
pub const TRACK_VARS_FILES: u32 = 5;
pub const TRACK_VARS_REQUEST: u32 = 6;
pub const PHP_INI_USER: u32 = 1;
pub const PHP_INI_PERDIR: u32 = 2;
pub const PHP_INI_SYSTEM: u32 = 4;
pub const PHP_INI_ALL: u32 = 7;
pub const CONST_CS: u32 = 0;
pub const CONST_PERSISTENT: u32 = 1;
pub const CONST_NO_FILE_CACHE: u32 = 2;
pub const CONST_DEPRECATED: u32 = 4;
pub type __dev_t = ::std::os::raw::c_ulong;
pub type __uid_t = ::std::os::raw::c_uint;
pub type __gid_t = ::std::os::raw::c_uint;
pub type __ino_t = ::std::os::raw::c_ulong;
pub type __mode_t = ::std::os::raw::c_uint;
pub type __nlink_t = ::std::os::raw::c_ulong;
pub type __off_t = ::std::os::raw::c_long;
pub type __off64_t = ::std::os::raw::c_long;
pub type __time_t = ::std::os::raw::c_long;
pub type __blksize_t = ::std::os::raw::c_long;
pub type __blkcnt_t = ::std::os::raw::c_long;
pub type __syscall_slong_t = ::std::os::raw::c_long;
pub type gid_t = __gid_t;
pub type uid_t = __uid_t;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct __sigset_t {
pub __val: [::std::os::raw::c_ulong; 16usize],
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct timespec {
pub tv_sec: __time_t,
pub tv_nsec: __syscall_slong_t,
}
pub type FILE = _IO_FILE;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _IO_marker {
_unused: [u8; 0],
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _IO_codecvt {
_unused: [u8; 0],
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _IO_wide_data {
_unused: [u8; 0],
}
pub type _IO_lock_t = ::std::os::raw::c_void;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _IO_FILE {
pub _flags: ::std::os::raw::c_int,
pub _IO_read_ptr: *mut ::std::os::raw::c_char,
pub _IO_read_end: *mut ::std::os::raw::c_char,
pub _IO_read_base: *mut ::std::os::raw::c_char,
pub _IO_write_base: *mut ::std::os::raw::c_char,
pub _IO_write_ptr: *mut ::std::os::raw::c_char,
pub _IO_write_end: *mut ::std::os::raw::c_char,
pub _IO_buf_base: *mut ::std::os::raw::c_char,
pub _IO_buf_end: *mut ::std::os::raw::c_char,
pub _IO_save_base: *mut ::std::os::raw::c_char,
pub _IO_backup_base: *mut ::std::os::raw::c_char,
pub _IO_save_end: *mut ::std::os::raw::c_char,
pub _markers: *mut _IO_marker,
pub _chain: *mut _IO_FILE,
pub _fileno: ::std::os::raw::c_int,
pub _flags2: ::std::os::raw::c_int,
pub _old_offset: __off_t,
pub _cur_column: ::std::os::raw::c_ushort,
pub _vtable_offset: ::std::os::raw::c_schar,
pub _shortbuf: [::std::os::raw::c_char; 1usize],
pub _lock: *mut _IO_lock_t,
pub _offset: __off64_t,
pub _codecvt: *mut _IO_codecvt,
pub _wide_data: *mut _IO_wide_data,
pub _freeres_list: *mut _IO_FILE,
pub _freeres_buf: *mut ::std::os::raw::c_void,
pub __pad5: usize,
pub _mode: ::std::os::raw::c_int,
pub _unused2: [::std::os::raw::c_char; 20usize],
}
pub type zend_long = i64;
pub type zend_ulong = u64;
pub type zend_off_t = i64;
pub const ZEND_RESULT_CODE_SUCCESS: ZEND_RESULT_CODE = 0;
pub const ZEND_RESULT_CODE_FAILURE: ZEND_RESULT_CODE = -1;
pub type ZEND_RESULT_CODE = ::std::os::raw::c_int;
pub use self::ZEND_RESULT_CODE as zend_result;
pub type zend_object_handlers = _zend_object_handlers;
pub type zend_class_entry = _zend_class_entry;
pub type zend_function = _zend_function;
pub type zend_execute_data = _zend_execute_data;
pub type zval = _zval_struct;
pub type zend_refcounted = _zend_refcounted;
pub type zend_string = _zend_string;
pub type zend_array = _zend_array;
pub type zend_object = _zend_object;
pub type zend_resource = _zend_resource;
pub type zend_reference = _zend_reference;
pub type zend_ast_ref = _zend_ast_ref;
pub type dtor_func_t = ::std::option::Option<unsafe extern "C" fn(pDest: *mut zval)>;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct zend_type {
pub ptr: *mut ::std::os::raw::c_void,
pub type_mask: u32,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union _zend_value {
pub lval: zend_long,
pub dval: f64,
pub counted: *mut zend_refcounted,
pub str_: *mut zend_string,
pub arr: *mut zend_array,
pub obj: *mut zend_object,
pub res: *mut zend_resource,
pub ref_: *mut zend_reference,
pub ast: *mut zend_ast_ref,
pub zv: *mut zval,
pub ptr: *mut ::std::os::raw::c_void,
pub ce: *mut zend_class_entry,
pub func: *mut zend_function,
pub ww: _zend_value__bindgen_ty_1,
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_value__bindgen_ty_1 {
pub w1: u32,
pub w2: u32,
}
pub type zend_value = _zend_value;
#[repr(C)]
pub struct _zval_struct {
pub value: zend_value,
pub u1: _zval_struct__bindgen_ty_1,
pub u2: _zval_struct__bindgen_ty_2,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union _zval_struct__bindgen_ty_1 {
pub type_info: u32,
pub v: _zval_struct__bindgen_ty_1__bindgen_ty_1,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub struct _zval_struct__bindgen_ty_1__bindgen_ty_1 {
pub type_: u8,
pub type_flags: u8,
pub u: _zval_struct__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union _zval_struct__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1 {
pub extra: u16,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union _zval_struct__bindgen_ty_2 {
pub next: u32,
pub cache_slot: u32,
pub opline_num: u32,
pub lineno: u32,
pub num_args: u32,
pub fe_pos: u32,
pub fe_iter_idx: u32,
pub guard: u32,
pub constant_flags: u32,
pub extra: u32,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub struct _zend_refcounted_h {
pub refcount: u32,
pub u: _zend_refcounted_h__bindgen_ty_1,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union _zend_refcounted_h__bindgen_ty_1 {
pub type_info: u32,
}
pub type zend_refcounted_h = _zend_refcounted_h;
#[repr(C)]
#[derive(Copy, Clone)]
pub struct _zend_refcounted {
pub gc: zend_refcounted_h,
}
#[repr(C)]
pub struct _zend_string {
pub gc: zend_refcounted_h,
pub h: zend_ulong,
pub len: usize,
pub val: [::std::os::raw::c_char; 1usize],
}
#[repr(C)]
pub struct _Bucket {
pub val: zval,
pub h: zend_ulong,
pub key: *mut zend_string,
}
pub type Bucket = _Bucket;
pub type HashTable = _zend_array;
#[repr(C)]
pub struct _zend_array {
pub gc: zend_refcounted_h,
pub u: _zend_array__bindgen_ty_1,
pub nTableMask: u32,
pub __bindgen_anon_1: _zend_array__bindgen_ty_2,
pub nNumUsed: u32,
pub nNumOfElements: u32,
pub nTableSize: u32,
pub nInternalPointer: u32,
pub nNextFreeElement: zend_long,
pub pDestructor: dtor_func_t,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union _zend_array__bindgen_ty_1 {
pub v: _zend_array__bindgen_ty_1__bindgen_ty_1,
pub flags: u32,
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_array__bindgen_ty_1__bindgen_ty_1 {
pub flags: u8,
pub _unused: u8,
pub nIteratorsCount: u8,
pub _unused2: u8,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union _zend_array__bindgen_ty_2 {
pub arHash: *mut u32,
pub arData: *mut Bucket,
pub arPacked: *mut zval,
}
pub type HashPosition = u32;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _HashTableIterator {
pub ht: *mut HashTable,
pub pos: HashPosition,
pub next_copy: u32,
}
pub type HashTableIterator = _HashTableIterator;
#[repr(C)]
pub struct _zend_object {
pub gc: zend_refcounted_h,
pub handle: u32,
pub ce: *mut zend_class_entry,
pub handlers: *const zend_object_handlers,
pub properties: *mut HashTable,
pub properties_table: [zval; 1usize],
}
#[repr(C)]
#[derive(Copy, Clone)]
pub struct _zend_resource {
pub gc: zend_refcounted_h,
pub handle: zend_long,
pub type_: ::std::os::raw::c_int,
pub ptr: *mut ::std::os::raw::c_void,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union zend_property_info_source_list {
pub ptr: *mut _zend_property_info,
pub list: usize,
}
#[repr(C)]
pub struct _zend_reference {
pub gc: zend_refcounted_h,
pub val: zval,
pub sources: zend_property_info_source_list,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub struct _zend_ast_ref {
pub gc: zend_refcounted_h,
}
extern "C" {
pub fn _emalloc(
size: usize,
__zend_filename: *const ::std::os::raw::c_char,
__zend_lineno: u32,
__zend_orig_filename: *const ::std::os::raw::c_char,
__zend_orig_lineno: u32,
) -> *mut ::std::os::raw::c_void;
}
extern "C" {
pub fn _efree(
ptr: *mut ::std::os::raw::c_void,
__zend_filename: *const ::std::os::raw::c_char,
__zend_lineno: u32,
__zend_orig_filename: *const ::std::os::raw::c_char,
__zend_orig_lineno: u32,
);
}
extern "C" {
pub fn __zend_malloc(len: usize) -> *mut ::std::os::raw::c_void;
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_llist_element {
pub next: *mut _zend_llist_element,
pub prev: *mut _zend_llist_element,
pub data: [::std::os::raw::c_char; 1usize],
}
pub type zend_llist_element = _zend_llist_element;
pub type llist_dtor_func_t =
::std::option::Option<unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void)>;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_llist {
pub head: *mut zend_llist_element,
pub tail: *mut zend_llist_element,
pub count: usize,
pub size: usize,
pub dtor: llist_dtor_func_t,
pub persistent: ::std::os::raw::c_uchar,
pub traverse_ptr: *mut zend_llist_element,
}
pub type zend_llist = _zend_llist;
pub type zend_llist_position = *mut zend_llist_element;
extern "C" {
pub fn zend_llist_get_next_ex(
l: *mut zend_llist,
pos: *mut zend_llist_position,
) -> *mut ::std::os::raw::c_void;
}
extern "C" {
pub fn zend_llist_get_prev_ex(
l: *mut zend_llist,
pos: *mut zend_llist_position,
) -> *mut ::std::os::raw::c_void;
}
pub type zend_string_init_interned_func_t = ::std::option::Option<
unsafe extern "C" fn(
str_: *const ::std::os::raw::c_char,
size: usize,
permanent: bool,
) -> *mut zend_string,
>;
extern "C" {
pub static mut zend_string_init_interned: zend_string_init_interned_func_t;
}
extern "C" {
pub fn zend_hash_clean(ht: *mut HashTable);
}
extern "C" {
pub fn zend_hash_str_update(
ht: *mut HashTable,
key: *const ::std::os::raw::c_char,
len: usize,
pData: *mut zval,
) -> *mut zval;
}
extern "C" {
pub fn zend_hash_index_update(ht: *mut HashTable, h: zend_ulong, pData: *mut zval)
-> *mut zval;
}
extern "C" {
pub fn zend_hash_next_index_insert(ht: *mut HashTable, pData: *mut zval) -> *mut zval;
}
extern "C" {
pub fn zend_hash_str_del(
ht: *mut HashTable,
key: *const ::std::os::raw::c_char,
len: usize,
) -> zend_result;
}
extern "C" {
pub fn zend_hash_index_del(ht: *mut HashTable, h: zend_ulong) -> zend_result;
}
extern "C" {
pub fn zend_hash_str_find(
ht: *const HashTable,
key: *const ::std::os::raw::c_char,
len: usize,
) -> *mut zval;
}
extern "C" {
pub fn zend_hash_index_find(ht: *const HashTable, h: zend_ulong) -> *mut zval;
}
extern "C" {
pub fn zend_hash_move_forward_ex(ht: *mut HashTable, pos: *mut HashPosition) -> zend_result;
}
extern "C" {
pub fn zend_hash_move_backwards_ex(ht: *mut HashTable, pos: *mut HashPosition) -> zend_result;
}
extern "C" {
pub fn zend_hash_get_current_key_zval_ex(
ht: *const HashTable,
key: *mut zval,
pos: *const HashPosition,
);
}
extern "C" {
pub fn zend_hash_get_current_key_type_ex(
ht: *mut HashTable,
pos: *mut HashPosition,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn zend_hash_get_current_data_ex(ht: *mut HashTable, pos: *mut HashPosition) -> *mut zval;
}
extern "C" {
pub fn _zend_new_array(size: u32) -> *mut HashTable;
}
extern "C" {
pub fn zend_array_count(ht: *mut HashTable) -> u32;
}
extern "C" {
pub fn zend_array_dup(source: *mut HashTable) -> *mut HashTable;
}
extern "C" {
pub fn zend_array_destroy(ht: *mut HashTable);
}
extern "C" {
pub fn zend_hash_str_find_ptr_lc(
ht: *const HashTable,
str_: *const ::std::os::raw::c_char,
len: usize,
) -> *mut ::std::os::raw::c_void;
}
extern "C" {
pub fn gc_possible_root(ref_: *mut zend_refcounted);
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct zend_get_gc_buffer {
pub cur: *mut zval,
pub end: *mut zval,
pub start: *mut zval,
}
extern "C" {
pub fn zval_ptr_dtor(zval_ptr: *mut zval);
}
pub type zend_object_iterator = _zend_object_iterator;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_object_iterator_funcs {
pub dtor: ::std::option::Option<unsafe extern "C" fn(iter: *mut zend_object_iterator)>,
pub valid: ::std::option::Option<
unsafe extern "C" fn(iter: *mut zend_object_iterator) -> ::std::os::raw::c_int,
>,
pub get_current_data:
::std::option::Option<unsafe extern "C" fn(iter: *mut zend_object_iterator) -> *mut zval>,
pub get_current_key: ::std::option::Option<
unsafe extern "C" fn(iter: *mut zend_object_iterator, key: *mut zval),
>,
pub move_forward: ::std::option::Option<unsafe extern "C" fn(iter: *mut zend_object_iterator)>,
pub rewind: ::std::option::Option<unsafe extern "C" fn(iter: *mut zend_object_iterator)>,
pub invalidate_current:
::std::option::Option<unsafe extern "C" fn(iter: *mut zend_object_iterator)>,
pub get_gc: ::std::option::Option<
unsafe extern "C" fn(
iter: *mut zend_object_iterator,
table: *mut *mut zval,
n: *mut ::std::os::raw::c_int,
) -> *mut HashTable,
>,
}
pub type zend_object_iterator_funcs = _zend_object_iterator_funcs;
#[repr(C)]
pub struct _zend_object_iterator {
pub std: zend_object,
pub data: zval,
pub funcs: *const zend_object_iterator_funcs,
pub index: zend_ulong,
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_class_iterator_funcs {
pub zf_new_iterator: *mut zend_function,
pub zf_valid: *mut zend_function,
pub zf_current: *mut zend_function,
pub zf_key: *mut zend_function,
pub zf_next: *mut zend_function,
pub zf_rewind: *mut zend_function,
}
pub type zend_class_iterator_funcs = _zend_class_iterator_funcs;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_class_arrayaccess_funcs {
pub zf_offsetget: *mut zend_function,
pub zf_offsetexists: *mut zend_function,
pub zf_offsetset: *mut zend_function,
pub zf_offsetunset: *mut zend_function,
}
pub type zend_class_arrayaccess_funcs = _zend_class_arrayaccess_funcs;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct stat {
pub st_dev: __dev_t,
pub st_ino: __ino_t,
pub st_nlink: __nlink_t,
pub st_mode: __mode_t,
pub st_uid: __uid_t,
pub st_gid: __gid_t,
pub __pad0: ::std::os::raw::c_int,
pub st_rdev: __dev_t,
pub st_size: __off_t,
pub st_blksize: __blksize_t,
pub st_blocks: __blkcnt_t,
pub st_atim: timespec,
pub st_mtim: timespec,
pub st_ctim: timespec,
pub __glibc_reserved: [__syscall_slong_t; 3usize],
}
pub type zend_stream_fsizer_t =
::std::option::Option<unsafe extern "C" fn(handle: *mut ::std::os::raw::c_void) -> usize>;
pub type zend_stream_reader_t = ::std::option::Option<
unsafe extern "C" fn(
handle: *mut ::std::os::raw::c_void,
buf: *mut ::std::os::raw::c_char,
len: usize,
) -> isize,
>;
pub type zend_stream_closer_t =
::std::option::Option<unsafe extern "C" fn(handle: *mut ::std::os::raw::c_void)>;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_stream {
pub handle: *mut ::std::os::raw::c_void,
pub isatty: ::std::os::raw::c_int,
pub reader: zend_stream_reader_t,
pub fsizer: zend_stream_fsizer_t,
pub closer: zend_stream_closer_t,
}
pub type zend_stream = _zend_stream;
#[repr(C)]
#[derive(Copy, Clone)]
pub struct _zend_file_handle {
pub handle: _zend_file_handle__bindgen_ty_1,
pub filename: *mut zend_string,
pub opened_path: *mut zend_string,
pub type_: u8,
pub primary_script: bool,
pub in_list: bool,
pub buf: *mut ::std::os::raw::c_char,
pub len: usize,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union _zend_file_handle__bindgen_ty_1 {
pub fp: *mut FILE,
pub stream: zend_stream,
}
pub type zend_file_handle = _zend_file_handle;
extern "C" {
pub fn zend_stream_init_filename(
handle: *mut zend_file_handle,
filename: *const ::std::os::raw::c_char,
);
}
extern "C" {
pub fn zend_destroy_file_handle(file_handle: *mut zend_file_handle);
}
pub type zend_stat_t = stat;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_serialize_data {
_unused: [u8; 0],
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_unserialize_data {
_unused: [u8; 0],
}
pub type zend_serialize_data = _zend_serialize_data;
pub type zend_unserialize_data = _zend_unserialize_data;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_class_name {
pub name: *mut zend_string,
pub lc_name: *mut zend_string,
}
pub type zend_class_name = _zend_class_name;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_trait_method_reference {
pub method_name: *mut zend_string,
pub class_name: *mut zend_string,
}
pub type zend_trait_method_reference = _zend_trait_method_reference;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_trait_precedence {
pub trait_method: zend_trait_method_reference,
pub num_excludes: u32,
pub exclude_class_names: [*mut zend_string; 1usize],
}
pub type zend_trait_precedence = _zend_trait_precedence;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_trait_alias {
pub trait_method: zend_trait_method_reference,
#[doc = " name for method to be added"]
pub alias: *mut zend_string,
#[doc = " modifiers to be set on trait method"]
pub modifiers: u32,
}
pub type zend_trait_alias = _zend_trait_alias;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_class_mutable_data {
pub default_properties_table: *mut zval,
pub constants_table: *mut HashTable,
pub ce_flags: u32,
pub backed_enum_table: *mut HashTable,
}
pub type zend_class_mutable_data = _zend_class_mutable_data;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_class_dependency {
pub name: *mut zend_string,
pub ce: *mut zend_class_entry,
}
pub type zend_class_dependency = _zend_class_dependency;
pub type zend_inheritance_cache_entry = _zend_inheritance_cache_entry;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_error_info {
pub type_: ::std::os::raw::c_int,
pub lineno: u32,
pub filename: *mut zend_string,
pub message: *mut zend_string,
}
pub type zend_error_info = _zend_error_info;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_inheritance_cache_entry {
pub next: *mut zend_inheritance_cache_entry,
pub ce: *mut zend_class_entry,
pub parent: *mut zend_class_entry,
pub dependencies: *mut zend_class_dependency,
pub dependencies_count: u32,
pub num_warnings: u32,
pub warnings: *mut *mut zend_error_info,
pub traits_and_interfaces: [*mut zend_class_entry; 1usize],
}
#[repr(C)]
pub struct _zend_class_entry {
pub type_: ::std::os::raw::c_char,
pub name: *mut zend_string,
pub __bindgen_anon_1: _zend_class_entry__bindgen_ty_1,
pub refcount: ::std::os::raw::c_int,
pub ce_flags: u32,
pub default_properties_count: ::std::os::raw::c_int,
pub default_static_members_count: ::std::os::raw::c_int,
pub default_properties_table: *mut zval,
pub default_static_members_table: *mut zval,
pub static_members_table__ptr: *mut zval,
pub function_table: HashTable,
pub properties_info: HashTable,
pub constants_table: HashTable,
pub mutable_data__ptr: *mut zend_class_mutable_data,
pub inheritance_cache: *mut zend_inheritance_cache_entry,
pub properties_info_table: *mut *mut _zend_property_info,
pub constructor: *mut zend_function,
pub destructor: *mut zend_function,
pub clone: *mut zend_function,
pub __get: *mut zend_function,
pub __set: *mut zend_function,
pub __unset: *mut zend_function,
pub __isset: *mut zend_function,
pub __call: *mut zend_function,
pub __callstatic: *mut zend_function,
pub __tostring: *mut zend_function,
pub __debugInfo: *mut zend_function,
pub __serialize: *mut zend_function,
pub __unserialize: *mut zend_function,
pub default_object_handlers: *const zend_object_handlers,
pub iterator_funcs_ptr: *mut zend_class_iterator_funcs,
pub arrayaccess_funcs_ptr: *mut zend_class_arrayaccess_funcs,
pub __bindgen_anon_2: _zend_class_entry__bindgen_ty_2,
pub get_iterator: ::std::option::Option<
unsafe extern "C" fn(
ce: *mut zend_class_entry,
object: *mut zval,
by_ref: ::std::os::raw::c_int,
) -> *mut zend_object_iterator,
>,
pub get_static_method: ::std::option::Option<
unsafe extern "C" fn(
ce: *mut zend_class_entry,
method: *mut zend_string,
) -> *mut zend_function,
>,
pub serialize: ::std::option::Option<
unsafe extern "C" fn(
object: *mut zval,
buffer: *mut *mut ::std::os::raw::c_uchar,
buf_len: *mut usize,
data: *mut zend_serialize_data,
) -> ::std::os::raw::c_int,
>,
pub unserialize: ::std::option::Option<
unsafe extern "C" fn(
object: *mut zval,
ce: *mut zend_class_entry,
buf: *const ::std::os::raw::c_uchar,
buf_len: usize,
data: *mut zend_unserialize_data,
) -> ::std::os::raw::c_int,
>,
pub num_interfaces: u32,
pub num_traits: u32,
pub __bindgen_anon_3: _zend_class_entry__bindgen_ty_3,
pub trait_names: *mut zend_class_name,
pub trait_aliases: *mut *mut zend_trait_alias,
pub trait_precedences: *mut *mut zend_trait_precedence,
pub attributes: *mut HashTable,
pub enum_backing_type: u32,
pub backed_enum_table: *mut HashTable,
pub info: _zend_class_entry__bindgen_ty_4,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union _zend_class_entry__bindgen_ty_1 {
pub parent: *mut zend_class_entry,
pub parent_name: *mut zend_string,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union _zend_class_entry__bindgen_ty_2 {
pub create_object: ::std::option::Option<
unsafe extern "C" fn(class_type: *mut zend_class_entry) -> *mut zend_object,
>,
pub interface_gets_implemented: ::std::option::Option<
unsafe extern "C" fn(
iface: *mut zend_class_entry,
class_type: *mut zend_class_entry,
) -> ::std::os::raw::c_int,
>,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union _zend_class_entry__bindgen_ty_3 {
pub interfaces: *mut *mut zend_class_entry,
pub interface_names: *mut zend_class_name,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union _zend_class_entry__bindgen_ty_4 {
pub user: _zend_class_entry__bindgen_ty_4__bindgen_ty_1,
pub internal: _zend_class_entry__bindgen_ty_4__bindgen_ty_2,
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_class_entry__bindgen_ty_4__bindgen_ty_1 {
pub filename: *mut zend_string,
pub line_start: u32,
pub line_end: u32,
pub doc_comment: *mut zend_string,
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _zend_class_entry__bindgen_ty_4__bindgen_ty_2 {
pub builtin_functions: *const _zend_function_entry,
pub module: *mut _zend_module_entry,
}
extern "C" {
pub fn _zend_bailout(filename: *const ::std::os::raw::c_char, lineno: u32) -> !;
}
extern "C" {
pub static mut zend_interrupt_function:
::std::option::Option<unsafe extern "C" fn(execute_data: *mut zend_execute_data)>;
}
extern "C" {
pub static mut zend_standard_class_def: *mut zend_class_entry;
}
pub const zend_error_handling_t_EH_NORMAL: zend_error_handling_t = 0;
pub const zend_error_handling_t_EH_THROW: zend_error_handling_t = 1;
pub type zend_error_handling_t = ::std::os::raw::c_uint;
pub type zend_object_read_property_t = ::std::option::Option<
unsafe extern "C" fn(
object: *mut zend_object,
member: *mut zend_string,
type_: ::std::os::raw::c_int,
cache_slot: *mut *mut ::std::os::raw::c_void,
rv: *mut zval,
) -> *mut zval,
>;
pub type zend_object_read_dimension_t = ::std::option::Option<
unsafe extern "C" fn(
object: *mut zend_object,
offset: *mut zval,
type_: ::std::os::raw::c_int,
rv: *mut zval,
) -> *mut zval,
>;
pub type zend_object_write_property_t = ::std::option::Option<
unsafe extern "C" fn(
object: *mut zend_object,
member: *mut zend_string,
value: *mut zval,
cache_slot: *mut *mut ::std::os::raw::c_void,
) -> *mut zval,
>;
pub type zend_object_write_dimension_t = ::std::option::Option<
unsafe extern "C" fn(object: *mut zend_object, offset: *mut zval, value: *mut zval),
>;
pub type zend_object_get_property_ptr_ptr_t = ::std::option::Option<
unsafe extern "C" fn(
object: *mut zend_object,