2
2
3
3
pub const ZEND_DEBUG : u32 = 1 ;
4
4
pub const ZEND_MM_ALIGNMENT : u32 = 8 ;
5
- pub const _ZEND_TYPE_NAME_BIT: u32 = 8388608 ;
5
+ pub const _ZEND_TYPE_NAME_BIT: u32 = 16777216 ;
6
6
pub const _ZEND_TYPE_NULLABLE_BIT: u32 = 2 ;
7
7
pub const HT_MIN_SIZE : u32 = 8 ;
8
8
pub const IS_UNDEF : u32 = 0 ;
@@ -21,7 +21,7 @@ pub const IS_CALLABLE: u32 = 12;
21
21
pub const IS_VOID : u32 = 14 ;
22
22
pub const IS_MIXED : u32 = 16 ;
23
23
pub const IS_PTR : u32 = 13 ;
24
- pub const _IS_BOOL: u32 = 17 ;
24
+ pub const _IS_BOOL: u32 = 18 ;
25
25
pub const Z_TYPE_FLAGS_SHIFT : u32 = 8 ;
26
26
pub const IS_TYPE_REFCOUNTED : u32 = 1 ;
27
27
pub const IS_TYPE_COLLECTABLE : u32 = 2 ;
@@ -56,13 +56,12 @@ pub const ZEND_ACC_USE_GUARDS: u32 = 2048;
56
56
pub const ZEND_ACC_CONSTANTS_UPDATED : u32 = 4096 ;
57
57
pub const ZEND_ACC_NO_DYNAMIC_PROPERTIES : u32 = 8192 ;
58
58
pub const ZEND_HAS_STATIC_IN_METHODS : u32 = 16384 ;
59
- pub const ZEND_ACC_PROPERTY_TYPES_RESOLVED : u32 = 32768 ;
60
59
pub const ZEND_ACC_REUSE_GET_ITERATOR : u32 = 65536 ;
61
60
pub const ZEND_ACC_RESOLVED_PARENT : u32 = 131072 ;
62
61
pub const ZEND_ACC_RESOLVED_INTERFACES : u32 = 262144 ;
63
62
pub const ZEND_ACC_UNRESOLVED_VARIANCE : u32 = 524288 ;
64
63
pub const ZEND_ACC_NEARLY_LINKED : u32 = 1048576 ;
65
- pub const ZEND_ACC_HAS_UNLINKED_USES : u32 = 2097152 ;
64
+ pub const ZEND_ACC_NOT_SERIALIZABLE : u32 = 536870912 ;
66
65
pub const ZEND_ACC_DEPRECATED : u32 = 2048 ;
67
66
pub const ZEND_ACC_RETURN_REFERENCE : u32 = 4096 ;
68
67
pub const ZEND_ACC_HAS_RETURN_TYPE : u32 = 8192 ;
@@ -81,30 +80,20 @@ pub const ZEND_ACC_DONE_PASS_TWO: u32 = 33554432;
81
80
pub const ZEND_ACC_HEAP_RT_CACHE : u32 = 67108864 ;
82
81
pub const ZEND_ACC_STRICT_TYPES : u32 = 2147483648 ;
83
82
pub const ZEND_ISEMPTY : u32 = 1 ;
84
- pub const _ZEND_SEND_MODE_SHIFT: u32 = 24 ;
85
- pub const _ZEND_IS_VARIADIC_BIT: u32 = 67108864 ;
86
- pub const ZEND_MODULE_API_NO : u32 = 20200930 ;
83
+ pub const _ZEND_SEND_MODE_SHIFT: u32 = 25 ;
84
+ pub const _ZEND_IS_VARIADIC_BIT: u32 = 134217728 ;
85
+ pub const ZEND_MODULE_API_NO : u32 = 20210902 ;
87
86
pub const USING_ZTS : u32 = 0 ;
88
87
pub const MAY_BE_BOOL : u32 = 12 ;
89
88
pub const MAY_BE_ANY : u32 = 1022 ;
90
89
pub const CONST_CS : u32 = 0 ;
91
90
pub const CONST_PERSISTENT : u32 = 1 ;
92
91
pub const CONST_NO_FILE_CACHE : u32 = 2 ;
93
92
pub const CONST_DEPRECATED : u32 = 4 ;
94
- pub type size_t = :: std:: os:: raw:: c_ulong ;
95
- pub type __uint8_t = :: std:: os:: raw:: c_uchar ;
96
- pub type __uint16_t = :: std:: os:: raw:: c_ushort ;
97
- pub type __uint32_t = :: std:: os:: raw:: c_uint ;
98
- pub type __int64_t = :: std:: os:: raw:: c_long ;
99
- pub type __uint64_t = :: std:: os:: raw:: c_ulong ;
100
- #[ repr( C ) ]
101
- #[ derive( Debug , Copy , Clone ) ]
102
- pub struct __sigset_t {
103
- pub __val : [ :: std:: os:: raw:: c_ulong ; 16usize ] ,
104
- }
93
+ pub type __darwin_size_t = :: std:: os:: raw:: c_ulong ;
94
+ pub type size_t = __darwin_size_t ;
105
95
pub type zend_long = i64 ;
106
96
pub type zend_ulong = u64 ;
107
- pub type zend_bool = bool ;
108
97
pub type zend_uchar = :: std:: os:: raw:: c_uchar ;
109
98
pub const ZEND_RESULT_CODE_SUCCESS : ZEND_RESULT_CODE = 0 ;
110
99
pub const ZEND_RESULT_CODE_FAILURE : ZEND_RESULT_CODE = -1 ;
@@ -130,6 +119,7 @@ pub struct zend_type {
130
119
pub type_mask : u32 ,
131
120
}
132
121
#[ repr( C ) ]
122
+ #[ derive( Copy , Clone ) ]
133
123
pub union _zend_value {
134
124
pub lval : zend_long ,
135
125
pub dval : f64 ,
@@ -187,7 +177,6 @@ pub union _zval_struct__bindgen_ty_2 {
187
177
pub num_args : u32 ,
188
178
pub fe_pos : u32 ,
189
179
pub fe_iter_idx : u32 ,
190
- pub access_flags : u32 ,
191
180
pub property_guard : u32 ,
192
181
pub constant_flags : u32 ,
193
182
pub extra : u32 ,
@@ -272,7 +261,7 @@ pub struct _zend_object {
272
261
#[ derive( Copy , Clone ) ]
273
262
pub struct _zend_resource {
274
263
pub gc : zend_refcounted_h ,
275
- pub handle : :: std :: os :: raw :: c_int ,
264
+ pub handle : zend_long ,
276
265
pub type_ : :: std:: os:: raw:: c_int ,
277
266
pub ptr : * mut :: std:: os:: raw:: c_void ,
278
267
}
@@ -368,6 +357,9 @@ extern "C" {
368
357
extern "C" {
369
358
pub fn zend_array_destroy ( ht : * mut HashTable ) ;
370
359
}
360
+ extern "C" {
361
+ pub fn gc_possible_root ( ref_ : * mut zend_refcounted ) ;
362
+ }
371
363
#[ repr( C ) ]
372
364
#[ derive( Debug , Copy , Clone ) ]
373
365
pub struct zend_get_gc_buffer {
@@ -467,6 +459,43 @@ pub struct _zend_trait_alias {
467
459
}
468
460
pub type zend_trait_alias = _zend_trait_alias ;
469
461
#[ repr( C ) ]
462
+ #[ derive( Debug , Copy , Clone ) ]
463
+ pub struct _zend_class_mutable_data {
464
+ pub default_properties_table : * mut zval ,
465
+ pub constants_table : * mut HashTable ,
466
+ pub ce_flags : u32 ,
467
+ }
468
+ pub type zend_class_mutable_data = _zend_class_mutable_data ;
469
+ #[ repr( C ) ]
470
+ #[ derive( Debug , Copy , Clone ) ]
471
+ pub struct _zend_class_dependency {
472
+ pub name : * mut zend_string ,
473
+ pub ce : * mut zend_class_entry ,
474
+ }
475
+ pub type zend_class_dependency = _zend_class_dependency ;
476
+ pub type zend_inheritance_cache_entry = _zend_inheritance_cache_entry ;
477
+ #[ repr( C ) ]
478
+ #[ derive( Debug , Copy , Clone ) ]
479
+ pub struct _zend_error_info {
480
+ pub type_ : :: std:: os:: raw:: c_int ,
481
+ pub lineno : u32 ,
482
+ pub filename : * mut zend_string ,
483
+ pub message : * mut zend_string ,
484
+ }
485
+ pub type zend_error_info = _zend_error_info ;
486
+ #[ repr( C ) ]
487
+ #[ derive( Debug , Copy , Clone ) ]
488
+ pub struct _zend_inheritance_cache_entry {
489
+ pub next : * mut zend_inheritance_cache_entry ,
490
+ pub ce : * mut zend_class_entry ,
491
+ pub parent : * mut zend_class_entry ,
492
+ pub dependencies : * mut zend_class_dependency ,
493
+ pub dependencies_count : u32 ,
494
+ pub num_warnings : u32 ,
495
+ pub warnings : * mut * mut zend_error_info ,
496
+ pub traits_and_interfaces : [ * mut zend_class_entry ; 1usize ] ,
497
+ }
498
+ #[ repr( C ) ]
470
499
pub struct _zend_class_entry {
471
500
pub type_ : :: std:: os:: raw:: c_char ,
472
501
pub name : * mut zend_string ,
@@ -481,6 +510,8 @@ pub struct _zend_class_entry {
481
510
pub function_table : HashTable ,
482
511
pub properties_info : HashTable ,
483
512
pub constants_table : HashTable ,
513
+ pub mutable_data__ptr : * mut * mut zend_class_mutable_data ,
514
+ pub inheritance_cache : * mut zend_inheritance_cache_entry ,
484
515
pub properties_info_table : * mut * mut _zend_property_info ,
485
516
pub constructor : * mut zend_function ,
486
517
pub destructor : * mut zend_function ,
@@ -534,6 +565,8 @@ pub struct _zend_class_entry {
534
565
pub trait_aliases : * mut * mut zend_trait_alias ,
535
566
pub trait_precedences : * mut * mut zend_trait_precedence ,
536
567
pub attributes : * mut HashTable ,
568
+ pub enum_backing_type : u32 ,
569
+ pub backed_enum_table : * mut HashTable ,
537
570
pub info : _zend_class_entry__bindgen_ty_4 ,
538
571
}
539
572
#[ repr( C ) ]
@@ -675,10 +708,10 @@ pub type zend_object_get_method_t = ::std::option::Option<
675
708
> ;
676
709
pub type zend_object_get_constructor_t =
677
710
:: std:: option:: Option < unsafe extern "C" fn ( object : * mut zend_object ) -> * mut zend_function > ;
678
- pub type zend_object_dtor_obj_t =
679
- :: std:: option:: Option < unsafe extern "C" fn ( object : * mut zend_object ) > ;
680
711
pub type zend_object_free_obj_t =
681
712
:: std:: option:: Option < unsafe extern "C" fn ( object : * mut zend_object ) > ;
713
+ pub type zend_object_dtor_obj_t =
714
+ :: std:: option:: Option < unsafe extern "C" fn ( object : * mut zend_object ) > ;
682
715
pub type zend_object_clone_obj_t =
683
716
:: std:: option:: Option < unsafe extern "C" fn ( object : * mut zend_object ) -> * mut zend_object > ;
684
717
pub type zend_object_get_class_name_t =
@@ -702,7 +735,7 @@ pub type zend_object_get_closure_t = ::std::option::Option<
702
735
ce_ptr : * mut * mut zend_class_entry ,
703
736
fptr_ptr : * mut * mut zend_function ,
704
737
obj_ptr : * mut * mut zend_object ,
705
- check_only : zend_bool ,
738
+ check_only : bool ,
706
739
) -> :: std:: os:: raw:: c_int ,
707
740
> ;
708
741
pub type zend_object_get_gc_t = :: std:: option:: Option <
@@ -885,7 +918,9 @@ pub struct _zend_op_array {
885
918
pub line_end : u32 ,
886
919
pub doc_comment : * mut zend_string ,
887
920
pub last_literal : :: std:: os:: raw:: c_int ,
921
+ pub num_dynamic_func_defs : u32 ,
888
922
pub literals : * mut zval ,
923
+ pub dynamic_func_defs : * mut * mut zend_op_array ,
889
924
pub reserved : [ * mut :: std:: os:: raw:: c_void ; 6usize ] ,
890
925
}
891
926
pub type zif_handler = :: std:: option:: Option <
@@ -944,16 +979,11 @@ pub struct _zend_execute_data {
944
979
pub run_time_cache : * mut * mut :: std:: os:: raw:: c_void ,
945
980
pub extra_named_params : * mut zend_array ,
946
981
}
947
- pub type __jmp_buf = [ :: std:: os:: raw:: c_long ; 8usize ] ;
948
- #[ repr( C ) ]
949
- #[ derive( Debug , Copy , Clone ) ]
950
- pub struct __jmp_buf_tag {
951
- pub __jmpbuf : __jmp_buf ,
952
- pub __mask_was_saved : :: std:: os:: raw:: c_int ,
953
- pub __saved_mask : __sigset_t ,
954
- }
955
- pub type jmp_buf = [ __jmp_buf_tag ; 1usize ] ;
982
+ pub type sigjmp_buf = [ :: std:: os:: raw:: c_int ; 49usize ] ;
956
983
pub type zend_executor_globals = _zend_executor_globals ;
984
+ extern "C" {
985
+ pub static mut executor_globals: zend_executor_globals ;
986
+ }
957
987
#[ repr( C ) ]
958
988
#[ derive( Debug , Copy , Clone ) ]
959
989
pub struct _zend_stack {
@@ -984,9 +1014,24 @@ pub struct _zend_objects_store {
984
1014
pub free_list_head : :: std:: os:: raw:: c_int ,
985
1015
}
986
1016
pub type zend_objects_store = _zend_objects_store ;
1017
+ extern "C" {
1018
+ pub fn zend_objects_store_del ( object : * mut zend_object ) ;
1019
+ }
987
1020
pub type zend_vm_stack = * mut _zend_vm_stack ;
988
1021
pub type zend_ini_entry = _zend_ini_entry ;
989
1022
#[ repr( C ) ]
1023
+ #[ derive( Debug , Copy , Clone ) ]
1024
+ pub struct _zend_fiber_context {
1025
+ _unused : [ u8 ; 0 ] ,
1026
+ }
1027
+ pub type zend_fiber_context = _zend_fiber_context ;
1028
+ #[ repr( C ) ]
1029
+ #[ derive( Debug , Copy , Clone ) ]
1030
+ pub struct _zend_fiber {
1031
+ _unused : [ u8 ; 0 ] ,
1032
+ }
1033
+ pub type zend_fiber = _zend_fiber ;
1034
+ #[ repr( C ) ]
990
1035
pub struct _zend_executor_globals {
991
1036
pub uninitialized_zval : zval ,
992
1037
pub error_zval : zval ,
@@ -995,7 +1040,7 @@ pub struct _zend_executor_globals {
995
1040
pub symtable_cache_ptr : * mut * mut zend_array ,
996
1041
pub symbol_table : zend_array ,
997
1042
pub included_files : HashTable ,
998
- pub bailout : * mut jmp_buf ,
1043
+ pub bailout : * mut sigjmp_buf ,
999
1044
pub error_reporting : :: std:: os:: raw:: c_int ,
1000
1045
pub exit_status : :: std:: os:: raw:: c_int ,
1001
1046
pub function_table : * mut HashTable ,
@@ -1014,10 +1059,10 @@ pub struct _zend_executor_globals {
1014
1059
pub persistent_functions_count : u32 ,
1015
1060
pub persistent_classes_count : u32 ,
1016
1061
pub in_autoload : * mut HashTable ,
1017
- pub full_tables_cleanup : zend_bool ,
1018
- pub no_extensions : zend_bool ,
1019
- pub vm_interrupt : zend_bool ,
1020
- pub timed_out : zend_bool ,
1062
+ pub full_tables_cleanup : bool ,
1063
+ pub no_extensions : bool ,
1064
+ pub vm_interrupt : bool ,
1065
+ pub timed_out : bool ,
1021
1066
pub hard_timeout : zend_long ,
1022
1067
pub regular_list : HashTable ,
1023
1068
pub persistent_list : HashTable ,
@@ -1030,7 +1075,7 @@ pub struct _zend_executor_globals {
1030
1075
pub error_handling : zend_error_handling_t ,
1031
1076
pub exception_class : * mut zend_class_entry ,
1032
1077
pub timeout_seconds : zend_long ,
1033
- pub lambda_count : :: std:: os:: raw:: c_int ,
1078
+ pub capture_warnings_during_sccp : :: std:: os:: raw:: c_int ,
1034
1079
pub ini_directives : * mut HashTable ,
1035
1080
pub modified_ini_directives : * mut HashTable ,
1036
1081
pub error_reporting_ini_entry : * mut zend_ini_entry ,
@@ -1040,7 +1085,7 @@ pub struct _zend_executor_globals {
1040
1085
pub opline_before_exception : * const zend_op ,
1041
1086
pub exception_op : [ zend_op ; 3usize ] ,
1042
1087
pub current_module : * mut _zend_module_entry ,
1043
- pub active : zend_bool ,
1088
+ pub active : bool ,
1044
1089
pub flags : zend_uchar ,
1045
1090
pub assertions : zend_long ,
1046
1091
pub ht_iterators_count : u32 ,
@@ -1051,9 +1096,16 @@ pub struct _zend_executor_globals {
1051
1096
pub trampoline : zend_function ,
1052
1097
pub call_trampoline_op : zend_op ,
1053
1098
pub weakrefs : HashTable ,
1054
- pub exception_ignore_args : zend_bool ,
1099
+ pub exception_ignore_args : bool ,
1055
1100
pub exception_string_param_max_len : zend_long ,
1056
1101
pub get_gc_buffer : zend_get_gc_buffer ,
1102
+ pub main_fiber_context : * mut zend_fiber_context ,
1103
+ pub current_fiber_context : * mut zend_fiber_context ,
1104
+ pub active_fiber : * mut zend_fiber ,
1105
+ pub fiber_stack_size : zend_long ,
1106
+ pub record_errors : bool ,
1107
+ pub num_errors : u32 ,
1108
+ pub errors : * mut * mut zend_error_info ,
1057
1109
pub reserved : [ * mut :: std:: os:: raw:: c_void ; 6usize ] ,
1058
1110
}
1059
1111
pub type zend_module_entry = _zend_module_entry ;
@@ -1150,7 +1202,7 @@ extern "C" {
1150
1202
callable : * mut zval ,
1151
1203
check_flags : u32 ,
1152
1204
callable_name : * mut * mut zend_string ,
1153
- ) -> zend_bool ;
1205
+ ) -> bool ;
1154
1206
}
1155
1207
extern "C" {
1156
1208
pub fn zend_declare_property (
@@ -1261,7 +1313,7 @@ extern "C" {
1261
1313
pub fn zend_register_bool_constant (
1262
1314
name : * const :: std:: os:: raw:: c_char ,
1263
1315
name_len : size_t ,
1264
- bval : zend_bool ,
1316
+ bval : bool ,
1265
1317
flags : :: std:: os:: raw:: c_int ,
1266
1318
module_number : :: std:: os:: raw:: c_int ,
1267
1319
) ;
@@ -1349,23 +1401,6 @@ extern "C" {
1349
1401
extern "C" {
1350
1402
pub fn zend_do_implement_interface ( ce : * mut zend_class_entry , iface : * mut zend_class_entry ) ;
1351
1403
}
1352
- extern "C" {
1353
- pub fn zend_class_serialize_deny (
1354
- object : * mut zval ,
1355
- buffer : * mut * mut :: std:: os:: raw:: c_uchar ,
1356
- buf_len : * mut size_t ,
1357
- data : * mut zend_serialize_data ,
1358
- ) -> :: std:: os:: raw:: c_int ;
1359
- }
1360
- extern "C" {
1361
- pub fn zend_class_unserialize_deny (
1362
- object : * mut zval ,
1363
- ce : * mut zend_class_entry ,
1364
- buf : * const :: std:: os:: raw:: c_uchar ,
1365
- buf_len : size_t ,
1366
- data : * mut zend_unserialize_data ,
1367
- ) -> :: std:: os:: raw:: c_int ;
1368
- }
1369
1404
extern "C" {
1370
1405
pub fn ext_php_rs_zend_string_init (
1371
1406
str_ : * const :: std:: os:: raw:: c_char ,
0 commit comments