From 6a32aa9b00371aa2416a2951d1451866440ba12b Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Mon, 12 Jan 2026 16:22:13 +0100 Subject: [PATCH 01/23] Make ZEND_AST_CONST_ENUM_INIT a 4-children node --- Zend/zend_ast.c | 4 ++-- Zend/zend_ast.h | 6 +++--- Zend/zend_compile.c | 4 ++-- Zend/zend_enum.c | 29 ++++++++++++++++++----------- 4 files changed, 25 insertions(+), 18 deletions(-) diff --git a/Zend/zend_ast.c b/Zend/zend_ast.c index e0a68a73bdf27..0674683ac2f47 100644 --- a/Zend/zend_ast.c +++ b/Zend/zend_ast.c @@ -995,10 +995,10 @@ static zend_result ZEND_FASTCALL zend_ast_evaluate_inner( zend_ast *class_name_ast = ast->child[0]; zend_string *class_name = zend_ast_get_str(class_name_ast); - zend_ast *case_name_ast = ast->child[1]; + zend_ast *case_name_ast = ast->child[2]; zend_string *case_name = zend_ast_get_str(case_name_ast); - zend_ast *case_value_ast = ast->child[2]; + zend_ast *case_value_ast = ast->child[3]; zval case_value_zv; ZVAL_UNDEF(&case_value_zv); diff --git a/Zend/zend_ast.h b/Zend/zend_ast.h index c212cd8367a87..a88efefd85b20 100644 --- a/Zend/zend_ast.h +++ b/Zend/zend_ast.h @@ -168,15 +168,15 @@ enum _zend_ast_kind { ZEND_AST_CONST_ELEM, ZEND_AST_CLASS_CONST_GROUP, - // Pseudo node for initializing enums - ZEND_AST_CONST_ENUM_INIT, - /* 4 child nodes */ ZEND_AST_FOR = 4 << ZEND_AST_NUM_CHILDREN_SHIFT, ZEND_AST_FOREACH, ZEND_AST_ENUM_CASE, ZEND_AST_PROP_ELEM, + // Pseudo node for initializing enums + ZEND_AST_CONST_ENUM_INIT, + /* 5 child nodes */ /* 6 child nodes */ diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 203201bcc12b5..b927a57a90cde 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -9582,7 +9582,7 @@ static void zend_compile_enum_case(zend_ast *ast) ZSTR_VAL(enum_class_name)); } - zend_ast *const_enum_init_ast = zend_ast_create(ZEND_AST_CONST_ENUM_INIT, class_name_ast, case_name_ast, case_value_ast); + zend_ast *const_enum_init_ast = zend_ast_create(ZEND_AST_CONST_ENUM_INIT, class_name_ast, NULL, case_name_ast, case_value_ast); zval value_zv; zend_const_expr_to_zval(&value_zv, &const_enum_init_ast, /* allow_dynamic */ false); @@ -12448,7 +12448,7 @@ static void zend_eval_const_expr(zend_ast **ast_ptr) /* {{{ */ zend_eval_const_expr(&ast->child[1]); return; case ZEND_AST_CONST_ENUM_INIT: - zend_eval_const_expr(&ast->child[2]); + zend_eval_const_expr(&ast->child[3]); return; case ZEND_AST_PROP: case ZEND_AST_NULLSAFE_PROP: diff --git a/Zend/zend_enum.c b/Zend/zend_enum.c index 7c62c8a96d0e3..37ed4201833bc 100644 --- a/Zend/zend_enum.c +++ b/Zend/zend_enum.c @@ -541,14 +541,15 @@ ZEND_API zend_class_entry *zend_register_internal_enum( static zend_ast_ref *create_enum_case_ast( zend_string *class_name, zend_string *case_name, zval *value) { // TODO: Use custom node type for enum cases? - size_t size = sizeof(zend_ast_ref) + zend_ast_size(3) - + (value ? 3 : 2) * sizeof(zend_ast_zval); + const size_t num_children = ZEND_AST_CONST_ENUM_INIT >> ZEND_AST_NUM_CHILDREN_SHIFT; + size_t size = sizeof(zend_ast_ref) + zend_ast_size(num_children) + + (value ? num_children : num_children-1) * sizeof(zend_ast_zval); char *p = pemalloc(size, 1); zend_ast_ref *ref = (zend_ast_ref *) p; p += sizeof(zend_ast_ref); GC_SET_REFCOUNT(ref, 1); GC_TYPE_INFO(ref) = GC_CONSTANT_AST | GC_PERSISTENT | GC_IMMUTABLE; - zend_ast *ast = (zend_ast *) p; p += zend_ast_size(3); + zend_ast *ast = (zend_ast *) p; p += zend_ast_size(num_children); ast->kind = ZEND_AST_CONST_ENUM_INIT; ast->attr = 0; ast->lineno = 0; @@ -563,19 +564,25 @@ static zend_ast_ref *create_enum_case_ast( ast->child[1] = (zend_ast *) p; p += sizeof(zend_ast_zval); ast->child[1]->kind = ZEND_AST_ZVAL; ast->child[1]->attr = 0; - ZEND_ASSERT(ZSTR_IS_INTERNED(case_name)); - ZVAL_STR(zend_ast_get_zval(ast->child[1]), case_name); + ZVAL_NULL(zend_ast_get_zval(ast->child[1])); Z_LINENO_P(zend_ast_get_zval(ast->child[1])) = 0; + ast->child[2] = (zend_ast *) p; p += sizeof(zend_ast_zval); + ast->child[2]->kind = ZEND_AST_ZVAL; + ast->child[2]->attr = 0; + ZEND_ASSERT(ZSTR_IS_INTERNED(case_name)); + ZVAL_STR(zend_ast_get_zval(ast->child[2]), case_name); + Z_LINENO_P(zend_ast_get_zval(ast->child[2])) = 0; + if (value) { - ast->child[2] = (zend_ast *) p; p += sizeof(zend_ast_zval); - ast->child[2]->kind = ZEND_AST_ZVAL; - ast->child[2]->attr = 0; + ast->child[3] = (zend_ast *) p; p += sizeof(zend_ast_zval); + ast->child[3]->kind = ZEND_AST_ZVAL; + ast->child[3]->attr = 0; ZEND_ASSERT(!Z_REFCOUNTED_P(value)); - ZVAL_COPY_VALUE(zend_ast_get_zval(ast->child[2]), value); - Z_LINENO_P(zend_ast_get_zval(ast->child[2])) = 0; + ZVAL_COPY_VALUE(zend_ast_get_zval(ast->child[3]), value); + Z_LINENO_P(zend_ast_get_zval(ast->child[3])) = 0; } else { - ast->child[2] = NULL; + ast->child[3] = NULL; } return ref; From ddbe6e8e61d3989b7cf7453eac85fadfdfa5d19a Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Mon, 12 Jan 2026 16:50:02 +0100 Subject: [PATCH 02/23] Store enum case id in ZEND_AST_CONST_ENUM_INIT --- Zend/zend_compile.c | 8 +++++++- Zend/zend_enum.c | 26 +++++++++++++++++++++++--- Zend/zend_enum.h | 1 + 3 files changed, 31 insertions(+), 4 deletions(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index b927a57a90cde..13bc4dd894dd7 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -9565,6 +9565,11 @@ static void zend_compile_enum_case(zend_ast *ast) ZVAL_STR_COPY(&class_name_zval, enum_class_name); zend_ast *class_name_ast = zend_ast_create_zval(&class_name_zval); + zval case_id_zval; + zend_long case_id = zend_enum_next_case_id(enum_class); + ZVAL_LONG(&case_id_zval, case_id); + zend_ast *case_id_ast = zend_ast_create_zval(&case_id_zval); + zval case_name_zval; ZVAL_STR_COPY(&case_name_zval, enum_case_name); zend_ast *case_name_ast = zend_ast_create_zval(&case_name_zval); @@ -9582,7 +9587,8 @@ static void zend_compile_enum_case(zend_ast *ast) ZSTR_VAL(enum_class_name)); } - zend_ast *const_enum_init_ast = zend_ast_create(ZEND_AST_CONST_ENUM_INIT, class_name_ast, NULL, case_name_ast, case_value_ast); + zend_ast *const_enum_init_ast = zend_ast_create(ZEND_AST_CONST_ENUM_INIT, + class_name_ast, case_id_ast, case_name_ast, case_value_ast); zval value_zv; zend_const_expr_to_zval(&value_zv, &const_enum_init_ast, /* allow_dynamic */ false); diff --git a/Zend/zend_enum.c b/Zend/zend_enum.c index 37ed4201833bc..a25d89457dc45 100644 --- a/Zend/zend_enum.c +++ b/Zend/zend_enum.c @@ -539,7 +539,8 @@ ZEND_API zend_class_entry *zend_register_internal_enum( } static zend_ast_ref *create_enum_case_ast( - zend_string *class_name, zend_string *case_name, zval *value) { + zend_string *class_name, zend_long case_id, zend_string *case_name, + zval *value) { // TODO: Use custom node type for enum cases? const size_t num_children = ZEND_AST_CONST_ENUM_INIT >> ZEND_AST_NUM_CHILDREN_SHIFT; size_t size = sizeof(zend_ast_ref) + zend_ast_size(num_children) @@ -564,7 +565,7 @@ static zend_ast_ref *create_enum_case_ast( ast->child[1] = (zend_ast *) p; p += sizeof(zend_ast_zval); ast->child[1]->kind = ZEND_AST_ZVAL; ast->child[1]->attr = 0; - ZVAL_NULL(zend_ast_get_zval(ast->child[1])); + ZVAL_LONG(zend_ast_get_zval(ast->child[1]), case_id); Z_LINENO_P(zend_ast_get_zval(ast->child[1])) = 0; ast->child[2] = (zend_ast *) p; p += sizeof(zend_ast_zval); @@ -588,6 +589,23 @@ static zend_ast_ref *create_enum_case_ast( return ref; } +zend_long zend_enum_next_case_id(zend_class_entry *enum_class) +{ + ZEND_HASH_REVERSE_FOREACH_VAL(&enum_class->constants_table, zval *zv) { + zend_class_constant *c = Z_PTR_P(zv); + if (!(ZEND_CLASS_CONST_FLAGS(c) & ZEND_CLASS_CONST_IS_CASE)) { + continue; + } + ZEND_ASSERT(Z_TYPE(c->value) == IS_CONSTANT_AST); + zend_ast *ast = Z_ASTVAL(c->value); + + ZEND_ASSERT(ast->kind == ZEND_AST_CONST_ENUM_INIT); + return Z_LVAL_P(zend_ast_get_zval(ast->child[1])) + 1; + } ZEND_HASH_FOREACH_END(); + + return 1; +} + ZEND_API void zend_enum_add_case(zend_class_entry *ce, zend_string *case_name, zval *value) { if (value) { @@ -609,9 +627,11 @@ ZEND_API void zend_enum_add_case(zend_class_entry *ce, zend_string *case_name, z ZEND_ASSERT(ce->enum_backing_type == IS_UNDEF); } + zend_long case_id = zend_enum_next_case_id(ce); + zval ast_zv; Z_TYPE_INFO(ast_zv) = IS_CONSTANT_AST; - Z_AST(ast_zv) = create_enum_case_ast(ce->name, case_name, value); + Z_AST(ast_zv) = create_enum_case_ast(ce->name, case_id, case_name, value); zend_class_constant *c = zend_declare_class_constant_ex( ce, case_name, &ast_zv, ZEND_ACC_PUBLIC, NULL); ZEND_CLASS_CONST_FLAGS(c) |= ZEND_CLASS_CONST_IS_CASE; diff --git a/Zend/zend_enum.h b/Zend/zend_enum.h index d6c820189475a..7e8a838337c33 100644 --- a/Zend/zend_enum.h +++ b/Zend/zend_enum.h @@ -38,6 +38,7 @@ zend_object *zend_enum_new(zval *result, zend_class_entry *ce, zend_string *case void zend_verify_enum(const zend_class_entry *ce); void zend_enum_register_funcs(zend_class_entry *ce); void zend_enum_register_props(zend_class_entry *ce); +zend_long zend_enum_next_case_id(zend_class_entry *enum_class); ZEND_API zend_class_entry *zend_register_internal_enum( const char *name, uint8_t type, const zend_function_entry *functions); From 7cb52e1dedc6c4bf207edee657af36b099965fdb Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Mon, 12 Jan 2026 17:16:49 +0100 Subject: [PATCH 03/23] Store enum case id in instance --- Zend/zend_ast.c | 5 ++++- Zend/zend_enum.c | 17 +++++++++++++++-- Zend/zend_enum.h | 2 +- 3 files changed, 20 insertions(+), 4 deletions(-) diff --git a/Zend/zend_ast.c b/Zend/zend_ast.c index 0674683ac2f47..81e7d719b3853 100644 --- a/Zend/zend_ast.c +++ b/Zend/zend_ast.c @@ -995,6 +995,9 @@ static zend_result ZEND_FASTCALL zend_ast_evaluate_inner( zend_ast *class_name_ast = ast->child[0]; zend_string *class_name = zend_ast_get_str(class_name_ast); + zend_ast *case_id_ast = ast->child[1]; + zend_long case_id = Z_LVAL_P(zend_ast_get_zval(case_id_ast)); + zend_ast *case_name_ast = ast->child[2]; zend_string *case_name = zend_ast_get_str(case_name_ast); @@ -1009,7 +1012,7 @@ static zend_result ZEND_FASTCALL zend_ast_evaluate_inner( } zend_class_entry *ce = zend_lookup_class(class_name); - zend_enum_new(result, ce, case_name, case_value_ast != NULL ? &case_value_zv : NULL); + zend_enum_new(result, ce, case_id, case_name, case_value_ast != NULL ? &case_value_zv : NULL); zval_ptr_dtor_nogc(&case_value_zv); break; } diff --git a/Zend/zend_enum.c b/Zend/zend_enum.c index a25d89457dc45..3912e248697c0 100644 --- a/Zend/zend_enum.c +++ b/Zend/zend_enum.c @@ -36,13 +36,25 @@ ZEND_API zend_class_entry *zend_ce_unit_enum; ZEND_API zend_class_entry *zend_ce_backed_enum; ZEND_API zend_object_handlers zend_enum_object_handlers; +typedef struct _zend_enum_obj { + zend_long case_id; + zend_object std; +} zend_enum_obj; + static zend_arg_info zarginfo_class_UnitEnum_cases[sizeof(arginfo_class_UnitEnum_cases)/sizeof(zend_internal_arg_info)]; static zend_arg_info zarginfo_class_BackedEnum_from[sizeof(arginfo_class_BackedEnum_from)/sizeof(zend_internal_arg_info)]; static zend_arg_info zarginfo_class_BackedEnum_tryFrom[sizeof(arginfo_class_BackedEnum_tryFrom)/sizeof(zend_internal_arg_info)]; -zend_object *zend_enum_new(zval *result, zend_class_entry *ce, zend_string *case_name, zval *backing_value_zv) +zend_object *zend_enum_new(zval *result, zend_class_entry *ce, zend_long case_id, zend_string *case_name, zval *backing_value_zv) { - zend_object *zobj = zend_objects_new(ce); + zend_enum_obj *intern = zend_object_alloc(sizeof(zend_enum_obj), ce); + + zend_object_std_init(&intern->std, ce); + object_properties_init(&intern->std, ce); + + intern->case_id = case_id; + + zend_object *zobj = &intern->std; GC_ADD_FLAGS(zobj, GC_NOT_COLLECTABLE); ZVAL_OBJ(result, zobj); @@ -170,6 +182,7 @@ void zend_register_enum_ce(void) zend_ce_backed_enum->interface_gets_implemented = zend_implement_backed_enum; memcpy(&zend_enum_object_handlers, &std_object_handlers, sizeof(zend_object_handlers)); + zend_enum_object_handlers.offset = XtOffsetOf(zend_enum_obj, std); zend_enum_object_handlers.clone_obj = NULL; zend_enum_object_handlers.compare = zend_objects_not_comparable; } diff --git a/Zend/zend_enum.h b/Zend/zend_enum.h index 7e8a838337c33..dbaec58cb3f7a 100644 --- a/Zend/zend_enum.h +++ b/Zend/zend_enum.h @@ -34,7 +34,7 @@ void zend_enum_startup(void); void zend_register_enum_ce(void); void zend_enum_add_interfaces(zend_class_entry *ce); zend_result zend_enum_build_backed_enum_table(zend_class_entry *ce); -zend_object *zend_enum_new(zval *result, zend_class_entry *ce, zend_string *case_name, zval *backing_value_zv); +zend_object *zend_enum_new(zval *result, zend_class_entry *ce, zend_long case_id, zend_string *case_name, zval *backing_value_zv); void zend_verify_enum(const zend_class_entry *ce); void zend_enum_register_funcs(zend_class_entry *ce); void zend_enum_register_props(zend_class_entry *ce); From 04f5516130620d91119bc448de37e9a306268c2d Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Mon, 12 Jan 2026 17:37:56 +0100 Subject: [PATCH 04/23] Expose enum case_id internally --- Zend/zend_enum.c | 5 ----- Zend/zend_enum.h | 16 ++++++++++++++++ 2 files changed, 16 insertions(+), 5 deletions(-) diff --git a/Zend/zend_enum.c b/Zend/zend_enum.c index 3912e248697c0..358edc6f53ddb 100644 --- a/Zend/zend_enum.c +++ b/Zend/zend_enum.c @@ -36,11 +36,6 @@ ZEND_API zend_class_entry *zend_ce_unit_enum; ZEND_API zend_class_entry *zend_ce_backed_enum; ZEND_API zend_object_handlers zend_enum_object_handlers; -typedef struct _zend_enum_obj { - zend_long case_id; - zend_object std; -} zend_enum_obj; - static zend_arg_info zarginfo_class_UnitEnum_cases[sizeof(arginfo_class_UnitEnum_cases)/sizeof(zend_internal_arg_info)]; static zend_arg_info zarginfo_class_BackedEnum_from[sizeof(arginfo_class_BackedEnum_from)/sizeof(zend_internal_arg_info)]; static zend_arg_info zarginfo_class_BackedEnum_tryFrom[sizeof(arginfo_class_BackedEnum_tryFrom)/sizeof(zend_internal_arg_info)]; diff --git a/Zend/zend_enum.h b/Zend/zend_enum.h index dbaec58cb3f7a..5531126479342 100644 --- a/Zend/zend_enum.h +++ b/Zend/zend_enum.h @@ -30,6 +30,16 @@ extern ZEND_API zend_class_entry *zend_ce_unit_enum; extern ZEND_API zend_class_entry *zend_ce_backed_enum; extern ZEND_API zend_object_handlers zend_enum_object_handlers; +typedef struct _zend_enum_obj { + zend_long case_id; + zend_object std; +} zend_enum_obj; + +static inline zend_enum_obj *zend_enum_obj_from_obj(zend_object *zobj) { + ZEND_ASSERT(zobj->ce->ce_flags & ZEND_ACC_ENUM); + return (zend_enum_obj*)((char*)(zobj) - XtOffsetOf(zend_enum_obj, std)); +} + void zend_enum_startup(void); void zend_register_enum_ce(void); void zend_enum_add_interfaces(zend_class_entry *ce); @@ -48,6 +58,12 @@ ZEND_API zend_object *zend_enum_get_case(zend_class_entry *ce, zend_string *name ZEND_API zend_object *zend_enum_get_case_cstr(zend_class_entry *ce, const char *name); ZEND_API zend_result zend_enum_get_case_by_value(zend_object **result, zend_class_entry *ce, zend_long long_key, zend_string *string_key, bool try_from); +static zend_always_inline zend_long zend_enum_fetch_case_id(zend_object *zobj) +{ + ZEND_ASSERT(zobj->ce->ce_flags & ZEND_ACC_ENUM); + return zend_enum_obj_from_obj(zobj)->case_id; +} + static zend_always_inline zval *zend_enum_fetch_case_name(zend_object *zobj) { ZEND_ASSERT(zobj->ce->ce_flags & ZEND_ACC_ENUM); From 931ef2e9c6e1e3d5061019e77710a8cce1e29a7a Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Mon, 12 Jan 2026 17:41:13 +0100 Subject: [PATCH 05/23] Generate C enum for internal enums --- build/gen_stub.php | 68 ++++++++++++++++++++++++++-- ext/dom/php_dom_decl.h | 8 ++++ ext/pcntl/pcntl_decl.h | 9 ++++ ext/random/random_decl.h | 8 ++++ ext/reflection/php_reflection_decl.h | 6 +++ ext/standard/basic_functions_decl.h | 12 +++++ ext/uri/php_uri_decl.h | 38 ++++++++++++++++ ext/zend_test/test_decl.h | 19 ++++++++ 8 files changed, 163 insertions(+), 5 deletions(-) create mode 100644 ext/dom/php_dom_decl.h create mode 100644 ext/pcntl/pcntl_decl.h create mode 100644 ext/random/random_decl.h create mode 100644 ext/reflection/php_reflection_decl.h create mode 100644 ext/standard/basic_functions_decl.h create mode 100644 ext/uri/php_uri_decl.h create mode 100644 ext/zend_test/test_decl.h diff --git a/build/gen_stub.php b/build/gen_stub.php index 9b1e829a50cb3..a92e7a3b6701d 100755 --- a/build/gen_stub.php +++ b/build/gen_stub.php @@ -82,6 +82,7 @@ function processStubFile(string $stubFile, Context $context, bool $includeOnly = $stubFilenameWithoutExtension = str_replace(".stub.php", "", $stubFile); $arginfoFile = "{$stubFilenameWithoutExtension}_arginfo.h"; $legacyFile = "{$stubFilenameWithoutExtension}_legacy_arginfo.h"; + $declFile = "{$stubFilenameWithoutExtension}_decl.h"; $stubCode = file_get_contents($stubFile); $stubHash = sha1(str_replace("\r\n", "\n", $stubCode)); @@ -122,7 +123,7 @@ function processStubFile(string $stubFile, Context $context, bool $includeOnly = return $fileInfo; } - $arginfoCode = generateArgInfoCode( + [$arginfoCode, $declCode] = generateArgInfoCode( basename($stubFilenameWithoutExtension), $fileInfo, $context->allConstInfos, @@ -130,12 +131,17 @@ function processStubFile(string $stubFile, Context $context, bool $includeOnly = ); if ($context->forceRegeneration || $stubHash !== $oldStubHash) { reportFilePutContents($arginfoFile, $arginfoCode); + if ($declCode !== '') { + reportFilePutContents($declFile, $declCode); + } else if (file_exists($declCode)) { + unlink($declCode); + } } if ($fileInfo->shouldGenerateLegacyArginfo()) { $legacyFileInfo = $fileInfo->getLegacyVersion(); - $arginfoCode = generateArgInfoCode( + [$arginfoCode] = generateArgInfoCode( basename($stubFilenameWithoutExtension), $legacyFileInfo, $context->allConstInfos, @@ -3278,7 +3284,7 @@ protected function addModifiersToFieldSynopsis(DOMDocument $doc, DOMElement $fie } class EnumCaseInfo { - private /* readonly */ string $name; + public /* readonly */ string $name; private /* readonly */ ?Expr $value; public function __construct(string $name, ?Expr $value) { @@ -3661,6 +3667,38 @@ function (Name $item) { return $code; } + public function getCDeclarations(): string + { + if ($this->type !== "enum") { + return ''; + } + + $code = ''; + + if ($this->cond) { + $code .= "#if {$this->cond}\n"; + } + + $cEnumName = 'zend_enum_' . str_replace('\\', '_', $this->name->toString()); + + $code .= "typedef enum _{$cEnumName} {\n"; + + $i = 1; + foreach ($this->enumCaseInfos as $case) { + $cName = 'ZEND_ENUM_' . str_replace('\\', '_', $this->name->toString()) . '_' . $case->name; + $code .= "\t{$cName} = {$i},\n"; + $i++; + } + + $code .= "} {$cEnumName};\n"; + + if ($this->cond) { + $code .= "#endif\n"; + } + + return $code; + } + private function getFlagsByPhpVersion(): VersionFlags { $php70Flags = []; @@ -4515,6 +4553,19 @@ public function generateClassEntryCode(array $allConstInfos): string { return $code; } + + public function generateClassEntryCDeclarations(): string { + $code = ""; + + foreach ($this->classInfos as $class) { + $cdecl = $class->getCDeclarations(); + if ($cdecl !== '') { + $code .= "\n" . $cdecl; + } + } + + return $code; + } } class DocCommentTag { @@ -5150,13 +5201,14 @@ function generateCodeWithConditions( /** * @param array $allConstInfos + * @return array{string, string} */ function generateArgInfoCode( string $stubFilenameWithoutExtension, FileInfo $fileInfo, array $allConstInfos, string $stubHash -): string { +): array { $code = "/* This is a generated file, edit the .stub.php file instead.\n" . " * Stub hash: $stubHash */\n"; @@ -5250,7 +5302,13 @@ static function (FuncInfo $funcInfo) use ($fileInfo, &$generatedFunctionDeclarat $code .= $fileInfo->generateClassEntryCode($allConstInfos); } - return $code; + + $declCode = $fileInfo->generateClassEntryCDeclarations(); + if ($declCode !== '') { + $declCode = "/* This is a generated file, edit the .stub.php file instead. */\n" . $declCode; + } + + return [$code, $declCode]; } /** @param FuncInfo[] $funcInfos */ diff --git a/ext/dom/php_dom_decl.h b/ext/dom/php_dom_decl.h new file mode 100644 index 0000000000000..77b855c89b608 --- /dev/null +++ b/ext/dom/php_dom_decl.h @@ -0,0 +1,8 @@ +/* This is a generated file, edit the .stub.php file instead. */ + +typedef enum _zend_enum_Dom_AdjacentPosition { + ZEND_ENUM_Dom_AdjacentPosition_BeforeBegin = 1, + ZEND_ENUM_Dom_AdjacentPosition_AfterBegin = 2, + ZEND_ENUM_Dom_AdjacentPosition_BeforeEnd = 3, + ZEND_ENUM_Dom_AdjacentPosition_AfterEnd = 4, +} zend_enum_Dom_AdjacentPosition; diff --git a/ext/pcntl/pcntl_decl.h b/ext/pcntl/pcntl_decl.h new file mode 100644 index 0000000000000..ba36a44569649 --- /dev/null +++ b/ext/pcntl/pcntl_decl.h @@ -0,0 +1,9 @@ +/* This is a generated file, edit the .stub.php file instead. */ + +typedef enum _zend_enum_Pcntl_QosClass { + ZEND_ENUM_Pcntl_QosClass_UserInteractive = 1, + ZEND_ENUM_Pcntl_QosClass_UserInitiated = 2, + ZEND_ENUM_Pcntl_QosClass_Default = 3, + ZEND_ENUM_Pcntl_QosClass_Utility = 4, + ZEND_ENUM_Pcntl_QosClass_Background = 5, +} zend_enum_Pcntl_QosClass; diff --git a/ext/random/random_decl.h b/ext/random/random_decl.h new file mode 100644 index 0000000000000..aea80c8f1321e --- /dev/null +++ b/ext/random/random_decl.h @@ -0,0 +1,8 @@ +/* This is a generated file, edit the .stub.php file instead. */ + +typedef enum _zend_enum_Random_IntervalBoundary { + ZEND_ENUM_Random_IntervalBoundary_ClosedOpen = 1, + ZEND_ENUM_Random_IntervalBoundary_ClosedClosed = 2, + ZEND_ENUM_Random_IntervalBoundary_OpenClosed = 3, + ZEND_ENUM_Random_IntervalBoundary_OpenOpen = 4, +} zend_enum_Random_IntervalBoundary; diff --git a/ext/reflection/php_reflection_decl.h b/ext/reflection/php_reflection_decl.h new file mode 100644 index 0000000000000..0bdd6242ddc53 --- /dev/null +++ b/ext/reflection/php_reflection_decl.h @@ -0,0 +1,6 @@ +/* This is a generated file, edit the .stub.php file instead. */ + +typedef enum _zend_enum_PropertyHookType { + ZEND_ENUM_PropertyHookType_Get = 1, + ZEND_ENUM_PropertyHookType_Set = 2, +} zend_enum_PropertyHookType; diff --git a/ext/standard/basic_functions_decl.h b/ext/standard/basic_functions_decl.h new file mode 100644 index 0000000000000..662df3d5dd9a4 --- /dev/null +++ b/ext/standard/basic_functions_decl.h @@ -0,0 +1,12 @@ +/* This is a generated file, edit the .stub.php file instead. */ + +typedef enum _zend_enum_RoundingMode { + ZEND_ENUM_RoundingMode_HalfAwayFromZero = 1, + ZEND_ENUM_RoundingMode_HalfTowardsZero = 2, + ZEND_ENUM_RoundingMode_HalfEven = 3, + ZEND_ENUM_RoundingMode_HalfOdd = 4, + ZEND_ENUM_RoundingMode_TowardsZero = 5, + ZEND_ENUM_RoundingMode_AwayFromZero = 6, + ZEND_ENUM_RoundingMode_NegativeInfinity = 7, + ZEND_ENUM_RoundingMode_PositiveInfinity = 8, +} zend_enum_RoundingMode; diff --git a/ext/uri/php_uri_decl.h b/ext/uri/php_uri_decl.h new file mode 100644 index 0000000000000..360c16ed59438 --- /dev/null +++ b/ext/uri/php_uri_decl.h @@ -0,0 +1,38 @@ +/* This is a generated file, edit the .stub.php file instead. */ + +typedef enum _zend_enum_Uri_UriComparisonMode { + ZEND_ENUM_Uri_UriComparisonMode_IncludeFragment = 1, + ZEND_ENUM_Uri_UriComparisonMode_ExcludeFragment = 2, +} zend_enum_Uri_UriComparisonMode; + +typedef enum _zend_enum_Uri_WhatWg_UrlValidationErrorType { + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_DomainToAscii = 1, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_DomainToUnicode = 2, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_DomainInvalidCodePoint = 3, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_HostInvalidCodePoint = 4, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_Ipv4EmptyPart = 5, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_Ipv4TooManyParts = 6, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_Ipv4NonNumericPart = 7, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_Ipv4NonDecimalPart = 8, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_Ipv4OutOfRangePart = 9, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_Ipv6Unclosed = 10, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_Ipv6InvalidCompression = 11, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_Ipv6TooManyPieces = 12, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_Ipv6MultipleCompression = 13, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_Ipv6InvalidCodePoint = 14, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_Ipv6TooFewPieces = 15, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_Ipv4InIpv6TooManyPieces = 16, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_Ipv4InIpv6InvalidCodePoint = 17, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_Ipv4InIpv6OutOfRangePart = 18, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_Ipv4InIpv6TooFewParts = 19, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_InvalidUrlUnit = 20, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_SpecialSchemeMissingFollowingSolidus = 21, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_MissingSchemeNonRelativeUrl = 22, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_InvalidReverseSoldius = 23, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_InvalidCredentials = 24, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_HostMissing = 25, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_PortOutOfRange = 26, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_PortInvalid = 27, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_FileInvalidWindowsDriveLetter = 28, + ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_FileInvalidWindowsDriveLetterHost = 29, +} zend_enum_Uri_WhatWg_UrlValidationErrorType; diff --git a/ext/zend_test/test_decl.h b/ext/zend_test/test_decl.h new file mode 100644 index 0000000000000..8cefe41d98313 --- /dev/null +++ b/ext/zend_test/test_decl.h @@ -0,0 +1,19 @@ +/* This is a generated file, edit the .stub.php file instead. */ + +typedef enum _zend_enum_ZendTestUnitEnum { + ZEND_ENUM_ZendTestUnitEnum_Foo = 1, + ZEND_ENUM_ZendTestUnitEnum_Bar = 2, +} zend_enum_ZendTestUnitEnum; + +typedef enum _zend_enum_ZendTestStringEnum { + ZEND_ENUM_ZendTestStringEnum_Foo = 1, + ZEND_ENUM_ZendTestStringEnum_Bar = 2, + ZEND_ENUM_ZendTestStringEnum_Baz = 3, + ZEND_ENUM_ZendTestStringEnum_FortyTwo = 4, +} zend_enum_ZendTestStringEnum; + +typedef enum _zend_enum_ZendTestIntEnum { + ZEND_ENUM_ZendTestIntEnum_Foo = 1, + ZEND_ENUM_ZendTestIntEnum_Bar = 2, + ZEND_ENUM_ZendTestIntEnum_Baz = 3, +} zend_enum_ZendTestIntEnum; From 4ba42daac8e5df7f8628db2c230d2ab9c8cd0c69 Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Mon, 12 Jan 2026 19:17:14 +0100 Subject: [PATCH 06/23] Port ext/random --- ext/random/randomizer.c | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/ext/random/randomizer.c b/ext/random/randomizer.c index 2daf98661099a..a5b03b98c8a8a 100644 --- a/ext/random/randomizer.c +++ b/ext/random/randomizer.c @@ -20,6 +20,7 @@ #include "php.h" #include "php_random.h" +#include "random_decl.h" #include "ext/standard/php_array.h" #include "ext/standard/php_string.h" @@ -132,7 +133,7 @@ PHP_METHOD(Random_Randomizer, getFloat) php_random_randomizer *randomizer = Z_RANDOM_RANDOMIZER_P(ZEND_THIS); double min, max; zend_object *bounds = NULL; - int bounds_type = 'C' + sizeof("ClosedOpen") - 1; + zend_enum_Random_IntervalBoundary bounds_type = ZEND_ENUM_Random_IntervalBoundary_ClosedOpen; ZEND_PARSE_PARAMETERS_START(2, 3) Z_PARAM_DOUBLE(min) @@ -152,35 +153,32 @@ PHP_METHOD(Random_Randomizer, getFloat) } if (bounds) { - zval *case_name = zend_enum_fetch_case_name(bounds); - zend_string *bounds_name = Z_STR_P(case_name); - - bounds_type = ZSTR_VAL(bounds_name)[0] + ZSTR_LEN(bounds_name); + bounds_type = zend_enum_fetch_case_id(bounds); } switch (bounds_type) { - case 'C' + sizeof("ClosedOpen") - 1: + case ZEND_ENUM_Random_IntervalBoundary_ClosedOpen: if (UNEXPECTED(max <= min)) { zend_argument_value_error(2, "must be greater than argument #1 ($min)"); RETURN_THROWS(); } RETURN_DOUBLE(php_random_gammasection_closed_open(randomizer->engine, min, max)); - case 'C' + sizeof("ClosedClosed") - 1: + case ZEND_ENUM_Random_IntervalBoundary_ClosedClosed: if (UNEXPECTED(max < min)) { zend_argument_value_error(2, "must be greater than or equal to argument #1 ($min)"); RETURN_THROWS(); } RETURN_DOUBLE(php_random_gammasection_closed_closed(randomizer->engine, min, max)); - case 'O' + sizeof("OpenClosed") - 1: + case ZEND_ENUM_Random_IntervalBoundary_OpenClosed: if (UNEXPECTED(max <= min)) { zend_argument_value_error(2, "must be greater than argument #1 ($min)"); RETURN_THROWS(); } RETURN_DOUBLE(php_random_gammasection_open_closed(randomizer->engine, min, max)); - case 'O' + sizeof("OpenOpen") - 1: + case ZEND_ENUM_Random_IntervalBoundary_OpenOpen: if (UNEXPECTED(max <= min)) { zend_argument_value_error(2, "must be greater than argument #1 ($min)"); RETURN_THROWS(); From 1a8c2ab5094ffd4c2a0eada531e654e790a63b15 Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Mon, 12 Jan 2026 19:20:54 +0100 Subject: [PATCH 07/23] Z_PARAM_ENUM() --- Zend/zend_API.h | 7 +++++++ ext/random/randomizer.c | 7 +------ 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/Zend/zend_API.h b/Zend/zend_API.h index c1ccbf13666a5..d78ee6604e34d 100644 --- a/Zend/zend_API.h +++ b/Zend/zend_API.h @@ -2009,6 +2009,13 @@ ZEND_API ZEND_COLD void zend_class_redeclaration_error_ex(int type, zend_string #define Z_PARAM_OBJ_OF_CLASS_OR_LONG_OR_NULL(dest_obj, _ce, dest_long, is_null) \ Z_PARAM_OBJ_OF_CLASS_OR_LONG_EX(dest_obj, _ce, dest_long, is_null, 1) +#define Z_PARAM_ENUM(dest, _ce) \ + { \ + zend_object *_tmp = NULL; \ + Z_PARAM_OBJ_OF_CLASS(_tmp, _ce); \ + dest = zend_enum_fetch_case_id(_tmp); \ + } + /* old "p" */ #define Z_PARAM_PATH_EX(dest, dest_len, check_null, deref) \ Z_PARAM_PROLOGUE(deref, 0); \ diff --git a/ext/random/randomizer.c b/ext/random/randomizer.c index a5b03b98c8a8a..fbb0b85594ba3 100644 --- a/ext/random/randomizer.c +++ b/ext/random/randomizer.c @@ -132,14 +132,13 @@ PHP_METHOD(Random_Randomizer, getFloat) { php_random_randomizer *randomizer = Z_RANDOM_RANDOMIZER_P(ZEND_THIS); double min, max; - zend_object *bounds = NULL; zend_enum_Random_IntervalBoundary bounds_type = ZEND_ENUM_Random_IntervalBoundary_ClosedOpen; ZEND_PARSE_PARAMETERS_START(2, 3) Z_PARAM_DOUBLE(min) Z_PARAM_DOUBLE(max) Z_PARAM_OPTIONAL - Z_PARAM_OBJ_OF_CLASS(bounds, random_ce_Random_IntervalBoundary); + Z_PARAM_ENUM(bounds_type, random_ce_Random_IntervalBoundary); ZEND_PARSE_PARAMETERS_END(); if (!zend_finite(min)) { @@ -152,10 +151,6 @@ PHP_METHOD(Random_Randomizer, getFloat) RETURN_THROWS(); } - if (bounds) { - bounds_type = zend_enum_fetch_case_id(bounds); - } - switch (bounds_type) { case ZEND_ENUM_Random_IntervalBoundary_ClosedOpen: if (UNEXPECTED(max <= min)) { From b9bf559f1f846ad487bdf7f198cd6771a9a63fbf Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Mon, 12 Jan 2026 19:38:47 +0100 Subject: [PATCH 08/23] ext/dom --- ext/dom/element.c | 111 ++++++++++++++++++++++++++++++++-------------- 1 file changed, 77 insertions(+), 34 deletions(-) diff --git a/ext/dom/element.c b/ext/dom/element.c index 797f215e173d1..fcf01c286c5a9 100644 --- a/ext/dom/element.c +++ b/ext/dom/element.c @@ -28,6 +28,7 @@ #include "internal_helpers.h" #include "dom_properties.h" #include "token_list.h" +#include "php_dom_decl.h" /* * class DOMElement extends DOMNode @@ -1601,9 +1602,10 @@ PHP_METHOD(DOMElement, replaceChildren) #define INSERT_ADJACENT_RES_SYNTAX_FAILED INSERT_ADJACENT_RES_ADOPT_FAILED #define INSERT_ADJACENT_RES_PRE_INSERT_FAILED ((void*) -2) -static xmlNodePtr dom_insert_adjacent(const zend_string *where, xmlNodePtr thisp, dom_object *this_intern, xmlNodePtr otherp) +static xmlNodePtr dom_insert_adjacent(zend_enum_Dom_AdjacentPosition where, xmlNodePtr thisp, dom_object *this_intern, xmlNodePtr otherp) { - if (zend_string_equals_literal_ci(where, "beforebegin")) { + switch (where) { + case ZEND_ENUM_Dom_AdjacentPosition_BeforeBegin: if (thisp->parent == NULL) { return NULL; } @@ -1613,21 +1615,24 @@ static xmlNodePtr dom_insert_adjacent(const zend_string *where, xmlNodePtr thisp if (!php_dom_pre_insert(this_intern->document, otherp, thisp->parent, thisp)) { return INSERT_ADJACENT_RES_PRE_INSERT_FAILED; } - } else if (zend_string_equals_literal_ci(where, "afterbegin")) { + break; + case ZEND_ENUM_Dom_AdjacentPosition_AfterBegin: if (!php_dom_adopt_node(otherp, this_intern, thisp->doc)) { return INSERT_ADJACENT_RES_ADOPT_FAILED; } if (!php_dom_pre_insert(this_intern->document, otherp, thisp, thisp->children)) { return INSERT_ADJACENT_RES_PRE_INSERT_FAILED; } - } else if (zend_string_equals_literal_ci(where, "beforeend")) { + break; + case ZEND_ENUM_Dom_AdjacentPosition_BeforeEnd: if (!php_dom_adopt_node(otherp, this_intern, thisp->doc)) { return INSERT_ADJACENT_RES_ADOPT_FAILED; } if (!php_dom_pre_insert(this_intern->document, otherp, thisp, NULL)) { return INSERT_ADJACENT_RES_PRE_INSERT_FAILED; } - } else if (zend_string_equals_literal_ci(where, "afterend")) { + break; + case ZEND_ENUM_Dom_AdjacentPosition_AfterEnd: if (thisp->parent == NULL) { return NULL; } @@ -1637,9 +1642,9 @@ static xmlNodePtr dom_insert_adjacent(const zend_string *where, xmlNodePtr thisp if (!php_dom_pre_insert(this_intern->document, otherp, thisp->parent, thisp->next)) { return INSERT_ADJACENT_RES_PRE_INSERT_FAILED; } - } else { - php_dom_throw_error(SYNTAX_ERR, dom_get_strict_error(this_intern->document)); - return INSERT_ADJACENT_RES_SYNTAX_FAILED; + break; + default: + ZEND_UNREACHABLE(); } return otherp; } @@ -1647,7 +1652,7 @@ static xmlNodePtr dom_insert_adjacent(const zend_string *where, xmlNodePtr thisp /* {{{ URL: https://dom.spec.whatwg.org/#dom-element-insertadjacentelement Since: */ -static void dom_element_insert_adjacent_element(INTERNAL_FUNCTION_PARAMETERS, const zend_string *where, zval *element_zval) +static void dom_element_insert_adjacent_element(INTERNAL_FUNCTION_PARAMETERS, zend_enum_Dom_AdjacentPosition where, zval *element_zval) { zval *id; xmlNodePtr thisp, otherp; @@ -1666,12 +1671,41 @@ static void dom_element_insert_adjacent_element(INTERNAL_FUNCTION_PARAMETERS, co } } +static zend_result dom_adjacent_position_str_to_enum(zend_enum_Dom_AdjacentPosition *value, const zend_string *str) +{ + if (zend_string_equals_literal_ci(str, "beforebegin")) { + *value = ZEND_ENUM_Dom_AdjacentPosition_BeforeBegin; + } else if (zend_string_equals_literal_ci(str, "afterbegin")) { + *value = ZEND_ENUM_Dom_AdjacentPosition_AfterBegin; + } else if (zend_string_equals_literal_ci(str, "beforeend")) { + *value = ZEND_ENUM_Dom_AdjacentPosition_BeforeEnd; + } else if (zend_string_equals_literal_ci(str, "afterend")) { + *value = ZEND_ENUM_Dom_AdjacentPosition_AfterEnd; + } else { + return FAILURE; + } + + return SUCCESS; +} + PHP_METHOD(DOMElement, insertAdjacentElement) { - zend_string *where; + zend_string *where_str; + zend_enum_Dom_AdjacentPosition where; zval *element_zval; - if (zend_parse_parameters(ZEND_NUM_ARGS(), "SO", &where, &element_zval, dom_element_class_entry) != SUCCESS) { + if (zend_parse_parameters(ZEND_NUM_ARGS(), "SO", &where_str, &element_zval, dom_element_class_entry) != SUCCESS) { + RETURN_THROWS(); + } + + if (dom_adjacent_position_str_to_enum(&where, where_str) != SUCCESS) { + zval *id; + xmlNodePtr p; + dom_object *intern; + DOM_GET_THIS_OBJ(p, id, xmlNodePtr, intern); + (void)p; + + php_dom_throw_error(SYNTAX_ERR, dom_get_strict_error(intern->document)); RETURN_THROWS(); } @@ -1680,14 +1714,14 @@ PHP_METHOD(DOMElement, insertAdjacentElement) PHP_METHOD(Dom_Element, insertAdjacentElement) { - zval *element_zval, *where_zv; + zend_enum_Dom_AdjacentPosition where; + zval *element_zval; ZEND_PARSE_PARAMETERS_START(2, 2) - Z_PARAM_OBJECT_OF_CLASS(where_zv, dom_adjacent_position_class_entry) + Z_PARAM_ENUM(where, dom_adjacent_position_class_entry) Z_PARAM_OBJECT_OF_CLASS(element_zval, dom_modern_element_class_entry) ZEND_PARSE_PARAMETERS_END(); - const zend_string *where = Z_STR_P(zend_enum_fetch_case_name(Z_OBJ_P(where_zv))); dom_element_insert_adjacent_element(INTERNAL_FUNCTION_PARAM_PASSTHRU, where, element_zval); } /* }}} end DOMElement::insertAdjacentElement */ @@ -1695,7 +1729,7 @@ PHP_METHOD(Dom_Element, insertAdjacentElement) /* {{{ URL: https://dom.spec.whatwg.org/#dom-element-insertadjacenttext Since: */ -static void dom_element_insert_adjacent_text(INTERNAL_FUNCTION_PARAMETERS, const zend_string *where, const zend_string *data) +static void dom_element_insert_adjacent_text(INTERNAL_FUNCTION_PARAMETERS, zend_enum_Dom_AdjacentPosition where, const zend_string *data) { dom_object *this_intern; zval *id; @@ -1717,9 +1751,21 @@ static void dom_element_insert_adjacent_text(INTERNAL_FUNCTION_PARAMETERS, const PHP_METHOD(DOMElement, insertAdjacentText) { - zend_string *where, *data; + zend_string *where_str, *data; + zend_enum_Dom_AdjacentPosition where; - if (zend_parse_parameters(ZEND_NUM_ARGS(), "SS", &where, &data) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS(), "SS", &where_str, &data) == FAILURE) { + RETURN_THROWS(); + } + + if (dom_adjacent_position_str_to_enum(&where, where_str) != SUCCESS) { + zval *id; + xmlNodePtr p; + dom_object *intern; + DOM_GET_THIS_OBJ(p, id, xmlNodePtr, intern); + (void)p; + + php_dom_throw_error(SYNTAX_ERR, dom_get_strict_error(intern->document)); RETURN_THROWS(); } @@ -1728,15 +1774,14 @@ PHP_METHOD(DOMElement, insertAdjacentText) PHP_METHOD(Dom_Element, insertAdjacentText) { - zval *where_zv; + zend_enum_Dom_AdjacentPosition where; zend_string *data; ZEND_PARSE_PARAMETERS_START(2, 2) - Z_PARAM_OBJECT_OF_CLASS(where_zv, dom_adjacent_position_class_entry) + Z_PARAM_ENUM(where, dom_adjacent_position_class_entry) Z_PARAM_STR(data) ZEND_PARSE_PARAMETERS_END(); - const zend_string *where = Z_STR_P(zend_enum_fetch_case_name(Z_OBJ_P(where_zv))); dom_element_insert_adjacent_text(INTERNAL_FUNCTION_PARAM_PASSTHRU, where, data); } /* }}} end DOMElement::insertAdjacentText */ @@ -1744,7 +1789,7 @@ PHP_METHOD(Dom_Element, insertAdjacentText) /* https://html.spec.whatwg.org/#dom-element-insertadjacenthtml */ PHP_METHOD(Dom_Element, insertAdjacentHTML) { - zval *where_zv; + zend_enum_Dom_AdjacentPosition where; zend_string *string; dom_object *this_intern; @@ -1754,23 +1799,21 @@ PHP_METHOD(Dom_Element, insertAdjacentHTML) bool created_context = false; ZEND_PARSE_PARAMETERS_START(2, 2) - Z_PARAM_OBJECT_OF_CLASS(where_zv, dom_adjacent_position_class_entry) + Z_PARAM_ENUM(where, dom_adjacent_position_class_entry) Z_PARAM_STR(string) ZEND_PARSE_PARAMETERS_END(); DOM_GET_THIS_OBJ(thisp, id, xmlNodePtr, this_intern); - const zend_string *where = Z_STR_P(zend_enum_fetch_case_name(Z_OBJ_P(where_zv))); - /* 1. We don't do injection sinks. */ /* 2. Let context be NULL */ xmlNodePtr context = NULL; /* 3. Use the first matching item from this list: (...) */ - switch (ZSTR_LEN(where) + ZSTR_VAL(where)[2]) { - case sizeof("BeforeBegin") - 1 + 'f': - case sizeof("AfterEnd") - 1 + 't': + switch (where) { + case ZEND_ENUM_Dom_AdjacentPosition_BeforeBegin: + case ZEND_ENUM_Dom_AdjacentPosition_AfterEnd: /* 1. Set context to this's parent. */ context = thisp->parent; @@ -1780,8 +1823,8 @@ PHP_METHOD(Dom_Element, insertAdjacentHTML) RETURN_THROWS(); } break; - case sizeof("AfterBegin") - 1 + 't': - case sizeof("BeforeEnd") - 1 + 'f': + case ZEND_ENUM_Dom_AdjacentPosition_AfterBegin: + case ZEND_ENUM_Dom_AdjacentPosition_BeforeEnd: /* Set context to this. */ context = thisp; break; @@ -1811,17 +1854,17 @@ PHP_METHOD(Dom_Element, insertAdjacentHTML) php_libxml_invalidate_node_list_cache(this_intern->document); /* 6. Use the first matching item from this list: (...) */ - switch (ZSTR_LEN(where) + ZSTR_VAL(where)[2]) { - case sizeof("BeforeBegin") - 1 + 'f': + switch (where) { + case ZEND_ENUM_Dom_AdjacentPosition_BeforeBegin: php_dom_pre_insert(this_intern->document, fragment, thisp->parent, thisp); break; - case sizeof("AfterEnd") - 1 + 't': + case ZEND_ENUM_Dom_AdjacentPosition_AfterEnd: php_dom_pre_insert(this_intern->document, fragment, thisp->parent, thisp->next); break; - case sizeof("AfterBegin") - 1 + 't': + case ZEND_ENUM_Dom_AdjacentPosition_AfterBegin: php_dom_pre_insert(this_intern->document, fragment, thisp, thisp->children); break; - case sizeof("BeforeEnd") - 1 + 'f': + case ZEND_ENUM_Dom_AdjacentPosition_BeforeEnd: php_dom_node_append(this_intern->document, fragment, thisp); break; EMPTY_SWITCH_DEFAULT_CASE(); From 1fdeb577d00dc3f11b3af2d494bb8a2996ebb36c Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Mon, 12 Jan 2026 19:42:11 +0100 Subject: [PATCH 09/23] ext/pcntl --- ext/pcntl/pcntl.c | 30 ++++++++++++++++++++---------- 1 file changed, 20 insertions(+), 10 deletions(-) diff --git a/ext/pcntl/pcntl.c b/ext/pcntl/pcntl.c index 886a292ee290d..ff28ee3b64271 100644 --- a/ext/pcntl/pcntl.c +++ b/ext/pcntl/pcntl.c @@ -33,6 +33,7 @@ #include "php_ticks.h" #include "zend_fibers.h" #include "main/php_main.h" +#include "pcntl_decl.h" #if defined(HAVE_GETPRIORITY) || defined(HAVE_SETPRIORITY) || defined(HAVE_WAIT3) #include @@ -1823,19 +1824,28 @@ PHP_FUNCTION(pcntl_getcpu) #endif #if defined(HAVE_PTHREAD_SET_QOS_CLASS_SELF_NP) -static qos_class_t qos_zval_to_lval(const zval *qos_obj) +static qos_class_t qos_enum_to_pthread(zend_enum_Pcntl_QosClass entry) { - qos_class_t qos_class = QOS_CLASS_DEFAULT; - zend_string *entry = Z_STR_P(zend_enum_fetch_case_name(Z_OBJ_P(qos_obj))); + qos_class_t qos_class; - if (zend_string_equals_literal(entry, "UserInteractive")) { + switch (entry) { + cse ZEND_ENUM_Pcntl_QosClass_UserInteractive: qos_class = QOS_CLASS_USER_INTERACTIVE; - } else if (zend_string_equals_literal(entry, "UserInitiated")) { + break; + case ZEND_ENUM_Pcntl_QosClass_UserInitiated: qos_class = QOS_CLASS_USER_INITIATED; - } else if (zend_string_equals_literal(entry, "Utility")) { + break; + case ZEND_ENUM_Pcntl_QosClass_Utility: qos_class = QOS_CLASS_UTILITY; - } else if (zend_string_equals_literal(entry, "Background")) { + break; + case ZEND_ENUM_Pcntl_QosClass_Background: qos_class = QOS_CLASS_BACKGROUND; + break; + case ZEND_ENUM_Pcntl_QosClass_Default: + qos_class = QOS_CLASS_DEFAULT; + break; + default: + ZEND_UNREACHABLE(); } return qos_class; @@ -1886,13 +1896,13 @@ PHP_FUNCTION(pcntl_getqos_class) PHP_FUNCTION(pcntl_setqos_class) { - zval *qos_obj; + zend_enum_Pcntl_QosClass qos; ZEND_PARSE_PARAMETERS_START(1, 1) - Z_PARAM_OBJECT_OF_CLASS(qos_obj, QosClass_ce) + Z_PARAM_ENUM(qos, QosClass_ce) ZEND_PARSE_PARAMETERS_END(); - qos_class_t qos_class = qos_zval_to_lval(qos_obj); + qos_class_t qos_class = qos_enum_to_pthread(qos); if (UNEXPECTED(pthread_set_qos_class_self_np((qos_class_t)qos_class, 0) != 0)) { From 37402d406c238bca9b95d24f1dd9db0a01d0cddc Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Mon, 12 Jan 2026 19:47:55 +0100 Subject: [PATCH 10/23] ext/reflection --- ext/reflection/php_reflection.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c index 64e79651913fb..efe05b5aa356c 100644 --- a/ext/reflection/php_reflection.c +++ b/ext/reflection/php_reflection.c @@ -31,6 +31,7 @@ #include "php.h" #include "php_ini.h" #include "php_reflection.h" +#include "php_reflection_decl.h" #include "ext/standard/info.h" #include "ext/standard/sha1.h" #include "ext/random/php_random_csprng.h" @@ -6547,16 +6548,16 @@ ZEND_METHOD(ReflectionProperty, hasHook) reflection_object *intern; property_reference *ref; - zend_object *type; + zend_enum_PropertyHookType type; ZEND_PARSE_PARAMETERS_START(1, 1) - Z_PARAM_OBJ_OF_CLASS(type, reflection_property_hook_type_ptr) + Z_PARAM_ENUM(type, reflection_property_hook_type_ptr) ZEND_PARSE_PARAMETERS_END(); GET_REFLECTION_OBJECT_PTR(ref); zend_property_hook_kind kind; - if (zend_string_equals_literal(Z_STR_P(zend_enum_fetch_case_name(type)), "Get")) { + if (type == ZEND_ENUM_PropertyHookType_Get) { kind = ZEND_PROPERTY_HOOK_GET; } else { kind = ZEND_PROPERTY_HOOK_SET; @@ -6569,10 +6570,10 @@ ZEND_METHOD(ReflectionProperty, getHook) { reflection_object *intern; property_reference *ref; - zend_object *type; + zend_enum_PropertyHookType type; ZEND_PARSE_PARAMETERS_START(1, 1) - Z_PARAM_OBJ_OF_CLASS(type, reflection_property_hook_type_ptr) + Z_PARAM_ENUM(type, reflection_property_hook_type_ptr) ZEND_PARSE_PARAMETERS_END(); GET_REFLECTION_OBJECT_PTR(ref); @@ -6583,7 +6584,7 @@ ZEND_METHOD(ReflectionProperty, getHook) } zend_function *hook; - if (zend_string_equals_literal(Z_STR_P(zend_enum_fetch_case_name(type)), "Get")) { + if (type == ZEND_ENUM_PropertyHookType_Get) { hook = ref->prop->hooks[ZEND_PROPERTY_HOOK_GET]; } else { hook = ref->prop->hooks[ZEND_PROPERTY_HOOK_SET]; From 5c378101aced2f45be28e1c6605437974f1b49b4 Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Mon, 12 Jan 2026 19:52:02 +0100 Subject: [PATCH 11/23] ext/uri --- ext/uri/php_uri.c | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/ext/uri/php_uri.c b/ext/uri/php_uri.c index 77fc627b6a99d..ddc7e7ff5a92f 100644 --- a/ext/uri/php_uri.c +++ b/ext/uri/php_uri.c @@ -26,6 +26,7 @@ #include "ext/standard/info.h" #include "php_uri.h" +#include "php_uri_decl.h" #include "uri_parser_whatwg.h" #include "uri_parser_rfc3986.h" #include "uri_parser_php_parse_url.h" @@ -678,7 +679,7 @@ static void throw_cannot_recompose_uri_to_string(php_uri_object *object) zend_throw_exception_ex(php_uri_ce_error, 0, "Cannot recompose %s to a string", ZSTR_VAL(object->std.ce->name)); } -static void uri_equals(INTERNAL_FUNCTION_PARAMETERS, php_uri_object *that_object, zend_object *comparison_mode) +static void uri_equals(INTERNAL_FUNCTION_PARAMETERS, php_uri_object *that_object, zend_enum_Uri_UriComparisonMode comparison_mode) { php_uri_object *this_object = Z_URI_OBJECT_P(ZEND_THIS); ZEND_ASSERT(this_object->uri != NULL); @@ -691,11 +692,7 @@ static void uri_equals(INTERNAL_FUNCTION_PARAMETERS, php_uri_object *that_object RETURN_FALSE; } - bool exclude_fragment = true; - if (comparison_mode) { - zval *case_name = zend_enum_fetch_case_name(comparison_mode); - exclude_fragment = zend_string_equals_literal(Z_STR_P(case_name), "ExcludeFragment"); - } + bool exclude_fragment = comparison_mode == ZEND_ENUM_Uri_UriComparisonMode_ExcludeFragment; zend_string *this_str = this_object->parser->to_string( this_object->uri, PHP_URI_RECOMPOSITION_MODE_NORMALIZED_ASCII, exclude_fragment); @@ -721,12 +718,12 @@ static void uri_equals(INTERNAL_FUNCTION_PARAMETERS, php_uri_object *that_object PHP_METHOD(Uri_Rfc3986_Uri, equals) { zend_object *that_object; - zend_object *comparison_mode = NULL; + zend_enum_Uri_UriComparisonMode comparison_mode = ZEND_ENUM_Uri_UriComparisonMode_IncludeFragment; ZEND_PARSE_PARAMETERS_START(1, 2) Z_PARAM_OBJ_OF_CLASS(that_object, php_uri_ce_rfc3986_uri) Z_PARAM_OPTIONAL - Z_PARAM_OBJ_OF_CLASS(comparison_mode, php_uri_ce_comparison_mode) + Z_PARAM_ENUM(comparison_mode, php_uri_ce_comparison_mode) ZEND_PARSE_PARAMETERS_END(); uri_equals(INTERNAL_FUNCTION_PARAM_PASSTHRU, php_uri_object_from_obj(that_object), comparison_mode); @@ -917,12 +914,12 @@ PHP_METHOD(Uri_WhatWg_Url, getFragment) PHP_METHOD(Uri_WhatWg_Url, equals) { zend_object *that_object; - zend_object *comparison_mode = NULL; + zend_enum_Uri_UriComparisonMode comparison_mode = ZEND_ENUM_Uri_UriComparisonMode_IncludeFragment; ZEND_PARSE_PARAMETERS_START(1, 2) Z_PARAM_OBJ_OF_CLASS(that_object, php_uri_ce_whatwg_url) Z_PARAM_OPTIONAL - Z_PARAM_OBJ_OF_CLASS(comparison_mode, php_uri_ce_comparison_mode) + Z_PARAM_ENUM(comparison_mode, php_uri_ce_comparison_mode) ZEND_PARSE_PARAMETERS_END(); uri_equals(INTERNAL_FUNCTION_PARAM_PASSTHRU, php_uri_object_from_obj(that_object), comparison_mode); From 830fa827b2d9fd290618679e35d46e05bd02b84a Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Mon, 12 Jan 2026 20:15:43 +0100 Subject: [PATCH 12/23] ext/standard --- ext/standard/math.c | 26 ++++++++++++-------------- ext/standard/php_math_round_mode.h | 3 ++- 2 files changed, 14 insertions(+), 15 deletions(-) diff --git a/ext/standard/math.c b/ext/standard/math.c index 95384c06588ac..346f8e59db215 100644 --- a/ext/standard/math.c +++ b/ext/standard/math.c @@ -19,6 +19,7 @@ #include "php.h" #include "php_math.h" +#include "basic_functions_decl.h" #include "zend_bitset.h" #include "zend_enum.h" #include "zend_exceptions.h" @@ -304,27 +305,24 @@ PHP_FUNCTION(floor) } /* }}} */ -PHPAPI int php_math_round_mode_from_enum(zend_object *mode) +PHPAPI int php_math_round_mode_from_enum(zend_enum_RoundingMode mode) { - zval *case_name = zend_enum_fetch_case_name(mode); - zend_string *mode_name = Z_STR_P(case_name); - - switch (ZSTR_VAL(mode_name)[0] + ZSTR_VAL(mode_name)[4]) { - case 'H' + 'A': + switch (mode) { + case ZEND_ENUM_RoundingMode_HalfAwayFromZero: return PHP_ROUND_HALF_UP; - case 'H' + 'T': + case ZEND_ENUM_RoundingMode_HalfTowardsZero: return PHP_ROUND_HALF_DOWN; - case 'H' + 'E': + case ZEND_ENUM_RoundingMode_HalfEven: return PHP_ROUND_HALF_EVEN; - case 'H' + 'O': + case ZEND_ENUM_RoundingMode_HalfOdd: return PHP_ROUND_HALF_ODD; - case 'T' + 'r': + case ZEND_ENUM_RoundingMode_TowardsZero: return PHP_ROUND_TOWARD_ZERO; - case 'A' + 'F': + case ZEND_ENUM_RoundingMode_AwayFromZero: return PHP_ROUND_AWAY_FROM_ZERO; - case 'N' + 't': + case ZEND_ENUM_RoundingMode_NegativeInfinity: return PHP_ROUND_FLOOR; - case 'P' + 't': + case ZEND_ENUM_RoundingMode_PositiveInfinity: return PHP_ROUND_CEILING; EMPTY_SWITCH_DEFAULT_CASE(); } @@ -355,7 +353,7 @@ PHP_FUNCTION(round) } if (mode_object != NULL) { - mode = php_math_round_mode_from_enum(mode_object); + mode = php_math_round_mode_from_enum(zend_enum_fetch_case_id(mode_object)); } switch (mode) { diff --git a/ext/standard/php_math_round_mode.h b/ext/standard/php_math_round_mode.h index e8cbec6406681..9ab02de2c361d 100644 --- a/ext/standard/php_math_round_mode.h +++ b/ext/standard/php_math_round_mode.h @@ -16,6 +16,7 @@ */ #include "php.h" +#include "basic_functions_decl.h" /* Define rounding modes (all are round-to-nearest) */ #ifndef PHP_ROUND_HALF_UP @@ -52,4 +53,4 @@ extern PHPAPI zend_class_entry *rounding_mode_ce; -PHPAPI int php_math_round_mode_from_enum(zend_object *mode); +PHPAPI int php_math_round_mode_from_enum(zend_enum_RoundingMode mode); From d52a4f07fa984fa71682f9fc172ba94dedc975c5 Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Mon, 12 Jan 2026 20:20:44 +0100 Subject: [PATCH 13/23] ext/bcmath --- ext/bcmath/bcmath.c | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) diff --git a/ext/bcmath/bcmath.c b/ext/bcmath/bcmath.c index df2b96e68a715..7c4ba49872103 100644 --- a/ext/bcmath/bcmath.c +++ b/ext/bcmath/bcmath.c @@ -25,6 +25,7 @@ #include "php_ini.h" #include "zend_exceptions.h" #include "zend_interfaces.h" +#include "zend_enum.h" #include "bcmath_arginfo.h" #include "ext/standard/info.h" #include "php_bcmath.h" @@ -787,20 +788,18 @@ PHP_FUNCTION(bcround) { zend_string *numstr; zend_long precision = 0; - zend_long mode = PHP_ROUND_HALF_UP; - zend_object *mode_object = NULL; + zend_long mode; + zend_enum_RoundingMode mode_enum = ZEND_ENUM_RoundingMode_HalfAwayFromZero; bc_num num = NULL, result; ZEND_PARSE_PARAMETERS_START(1, 3) Z_PARAM_STR(numstr) Z_PARAM_OPTIONAL Z_PARAM_LONG(precision) - Z_PARAM_OBJ_OF_CLASS(mode_object, rounding_mode_ce) + Z_PARAM_ENUM(mode_enum, rounding_mode_ce) ZEND_PARSE_PARAMETERS_END(); - if (mode_object != NULL) { - mode = php_math_round_mode_from_enum(mode_object); - } + mode = php_math_round_mode_from_enum(mode_enum); switch (mode) { case PHP_ROUND_HALF_UP: @@ -1796,18 +1795,16 @@ PHP_METHOD(BcMath_Number, ceil) PHP_METHOD(BcMath_Number, round) { zend_long precision = 0; - zend_long rounding_mode = PHP_ROUND_HALF_UP; - zend_object *mode_object = NULL; + zend_long rounding_mode; + zend_enum_RoundingMode mode_enum = ZEND_ENUM_RoundingMode_HalfAwayFromZero; ZEND_PARSE_PARAMETERS_START(0, 2) Z_PARAM_OPTIONAL Z_PARAM_LONG(precision); - Z_PARAM_OBJ_OF_CLASS(mode_object, rounding_mode_ce); + Z_PARAM_ENUM(mode_enum, rounding_mode_ce); ZEND_PARSE_PARAMETERS_END(); - if (mode_object != NULL) { - rounding_mode = php_math_round_mode_from_enum(mode_object); - } + rounding_mode = php_math_round_mode_from_enum(mode_enum); switch (rounding_mode) { case PHP_ROUND_HALF_UP: @@ -1824,6 +1821,7 @@ PHP_METHOD(BcMath_Number, round) RETURN_THROWS(); } + bcmath_number_obj_t *intern = get_bcmath_number_from_zval(ZEND_THIS); bc_num ret = NULL; From d02e229ca3485a7f806780e799c8e612c2b2ad2e Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Tue, 13 Jan 2026 12:41:11 +0100 Subject: [PATCH 14/23] Remove underscore --- build/gen_stub.php | 2 +- ext/dom/php_dom_decl.h | 2 +- ext/pcntl/pcntl_decl.h | 2 +- ext/random/random_decl.h | 2 +- ext/reflection/php_reflection_decl.h | 2 +- ext/standard/basic_functions_decl.h | 2 +- ext/uri/php_uri_decl.h | 4 ++-- ext/zend_test/test_decl.h | 11 ++++++++--- 8 files changed, 16 insertions(+), 11 deletions(-) diff --git a/build/gen_stub.php b/build/gen_stub.php index a92e7a3b6701d..1fcb6f10438ba 100755 --- a/build/gen_stub.php +++ b/build/gen_stub.php @@ -3681,7 +3681,7 @@ public function getCDeclarations(): string $cEnumName = 'zend_enum_' . str_replace('\\', '_', $this->name->toString()); - $code .= "typedef enum _{$cEnumName} {\n"; + $code .= "typedef enum {$cEnumName} {\n"; $i = 1; foreach ($this->enumCaseInfos as $case) { diff --git a/ext/dom/php_dom_decl.h b/ext/dom/php_dom_decl.h index 77b855c89b608..fed8ea0c3527c 100644 --- a/ext/dom/php_dom_decl.h +++ b/ext/dom/php_dom_decl.h @@ -1,6 +1,6 @@ /* This is a generated file, edit the .stub.php file instead. */ -typedef enum _zend_enum_Dom_AdjacentPosition { +typedef enum zend_enum_Dom_AdjacentPosition { ZEND_ENUM_Dom_AdjacentPosition_BeforeBegin = 1, ZEND_ENUM_Dom_AdjacentPosition_AfterBegin = 2, ZEND_ENUM_Dom_AdjacentPosition_BeforeEnd = 3, diff --git a/ext/pcntl/pcntl_decl.h b/ext/pcntl/pcntl_decl.h index ba36a44569649..cae4e8057932e 100644 --- a/ext/pcntl/pcntl_decl.h +++ b/ext/pcntl/pcntl_decl.h @@ -1,6 +1,6 @@ /* This is a generated file, edit the .stub.php file instead. */ -typedef enum _zend_enum_Pcntl_QosClass { +typedef enum zend_enum_Pcntl_QosClass { ZEND_ENUM_Pcntl_QosClass_UserInteractive = 1, ZEND_ENUM_Pcntl_QosClass_UserInitiated = 2, ZEND_ENUM_Pcntl_QosClass_Default = 3, diff --git a/ext/random/random_decl.h b/ext/random/random_decl.h index aea80c8f1321e..2e8078397bd2b 100644 --- a/ext/random/random_decl.h +++ b/ext/random/random_decl.h @@ -1,6 +1,6 @@ /* This is a generated file, edit the .stub.php file instead. */ -typedef enum _zend_enum_Random_IntervalBoundary { +typedef enum zend_enum_Random_IntervalBoundary { ZEND_ENUM_Random_IntervalBoundary_ClosedOpen = 1, ZEND_ENUM_Random_IntervalBoundary_ClosedClosed = 2, ZEND_ENUM_Random_IntervalBoundary_OpenClosed = 3, diff --git a/ext/reflection/php_reflection_decl.h b/ext/reflection/php_reflection_decl.h index 0bdd6242ddc53..ac27efee50958 100644 --- a/ext/reflection/php_reflection_decl.h +++ b/ext/reflection/php_reflection_decl.h @@ -1,6 +1,6 @@ /* This is a generated file, edit the .stub.php file instead. */ -typedef enum _zend_enum_PropertyHookType { +typedef enum zend_enum_PropertyHookType { ZEND_ENUM_PropertyHookType_Get = 1, ZEND_ENUM_PropertyHookType_Set = 2, } zend_enum_PropertyHookType; diff --git a/ext/standard/basic_functions_decl.h b/ext/standard/basic_functions_decl.h index 662df3d5dd9a4..dea0601b573f7 100644 --- a/ext/standard/basic_functions_decl.h +++ b/ext/standard/basic_functions_decl.h @@ -1,6 +1,6 @@ /* This is a generated file, edit the .stub.php file instead. */ -typedef enum _zend_enum_RoundingMode { +typedef enum zend_enum_RoundingMode { ZEND_ENUM_RoundingMode_HalfAwayFromZero = 1, ZEND_ENUM_RoundingMode_HalfTowardsZero = 2, ZEND_ENUM_RoundingMode_HalfEven = 3, diff --git a/ext/uri/php_uri_decl.h b/ext/uri/php_uri_decl.h index 360c16ed59438..94a8397508803 100644 --- a/ext/uri/php_uri_decl.h +++ b/ext/uri/php_uri_decl.h @@ -1,11 +1,11 @@ /* This is a generated file, edit the .stub.php file instead. */ -typedef enum _zend_enum_Uri_UriComparisonMode { +typedef enum zend_enum_Uri_UriComparisonMode { ZEND_ENUM_Uri_UriComparisonMode_IncludeFragment = 1, ZEND_ENUM_Uri_UriComparisonMode_ExcludeFragment = 2, } zend_enum_Uri_UriComparisonMode; -typedef enum _zend_enum_Uri_WhatWg_UrlValidationErrorType { +typedef enum zend_enum_Uri_WhatWg_UrlValidationErrorType { ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_DomainToAscii = 1, ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_DomainToUnicode = 2, ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_DomainInvalidCodePoint = 3, diff --git a/ext/zend_test/test_decl.h b/ext/zend_test/test_decl.h index 8cefe41d98313..0f767a1ad80a7 100644 --- a/ext/zend_test/test_decl.h +++ b/ext/zend_test/test_decl.h @@ -1,19 +1,24 @@ /* This is a generated file, edit the .stub.php file instead. */ -typedef enum _zend_enum_ZendTestUnitEnum { +typedef enum zend_enum_ZendTestUnitEnum { ZEND_ENUM_ZendTestUnitEnum_Foo = 1, ZEND_ENUM_ZendTestUnitEnum_Bar = 2, } zend_enum_ZendTestUnitEnum; -typedef enum _zend_enum_ZendTestStringEnum { +typedef enum zend_enum_ZendTestStringEnum { ZEND_ENUM_ZendTestStringEnum_Foo = 1, ZEND_ENUM_ZendTestStringEnum_Bar = 2, ZEND_ENUM_ZendTestStringEnum_Baz = 3, ZEND_ENUM_ZendTestStringEnum_FortyTwo = 4, } zend_enum_ZendTestStringEnum; -typedef enum _zend_enum_ZendTestIntEnum { +typedef enum zend_enum_ZendTestIntEnum { ZEND_ENUM_ZendTestIntEnum_Foo = 1, ZEND_ENUM_ZendTestIntEnum_Bar = 2, ZEND_ENUM_ZendTestIntEnum_Baz = 3, } zend_enum_ZendTestIntEnum; + +typedef enum zend_enum_ZendTestEnumWithInterface { + ZEND_ENUM_ZendTestEnumWithInterface_Foo = 1, + ZEND_ENUM_ZendTestEnumWithInterface_Bar = 2, +} zend_enum_ZendTestEnumWithInterface; From 5ca5760deea0d8629dda1916559a97a9d45af822 Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Tue, 13 Jan 2026 12:48:06 +0100 Subject: [PATCH 15/23] Switch to int --- Zend/zend_ast.c | 2 +- Zend/zend_compile.c | 2 +- Zend/zend_enum.c | 8 ++++---- Zend/zend_enum.h | 8 ++++---- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/Zend/zend_ast.c b/Zend/zend_ast.c index 81e7d719b3853..f8b1a5ca71ee0 100644 --- a/Zend/zend_ast.c +++ b/Zend/zend_ast.c @@ -996,7 +996,7 @@ static zend_result ZEND_FASTCALL zend_ast_evaluate_inner( zend_string *class_name = zend_ast_get_str(class_name_ast); zend_ast *case_id_ast = ast->child[1]; - zend_long case_id = Z_LVAL_P(zend_ast_get_zval(case_id_ast)); + int case_id = (int)Z_LVAL_P(zend_ast_get_zval(case_id_ast)); zend_ast *case_name_ast = ast->child[2]; zend_string *case_name = zend_ast_get_str(case_name_ast); diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 13bc4dd894dd7..e8727745a739a 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -9566,7 +9566,7 @@ static void zend_compile_enum_case(zend_ast *ast) zend_ast *class_name_ast = zend_ast_create_zval(&class_name_zval); zval case_id_zval; - zend_long case_id = zend_enum_next_case_id(enum_class); + int case_id = zend_enum_next_case_id(enum_class); ZVAL_LONG(&case_id_zval, case_id); zend_ast *case_id_ast = zend_ast_create_zval(&case_id_zval); diff --git a/Zend/zend_enum.c b/Zend/zend_enum.c index 358edc6f53ddb..60a794b3051e3 100644 --- a/Zend/zend_enum.c +++ b/Zend/zend_enum.c @@ -40,7 +40,7 @@ static zend_arg_info zarginfo_class_UnitEnum_cases[sizeof(arginfo_class_UnitEnum static zend_arg_info zarginfo_class_BackedEnum_from[sizeof(arginfo_class_BackedEnum_from)/sizeof(zend_internal_arg_info)]; static zend_arg_info zarginfo_class_BackedEnum_tryFrom[sizeof(arginfo_class_BackedEnum_tryFrom)/sizeof(zend_internal_arg_info)]; -zend_object *zend_enum_new(zval *result, zend_class_entry *ce, zend_long case_id, zend_string *case_name, zval *backing_value_zv) +zend_object *zend_enum_new(zval *result, zend_class_entry *ce, int case_id, zend_string *case_name, zval *backing_value_zv) { zend_enum_obj *intern = zend_object_alloc(sizeof(zend_enum_obj), ce); @@ -547,7 +547,7 @@ ZEND_API zend_class_entry *zend_register_internal_enum( } static zend_ast_ref *create_enum_case_ast( - zend_string *class_name, zend_long case_id, zend_string *case_name, + zend_string *class_name, int case_id, zend_string *case_name, zval *value) { // TODO: Use custom node type for enum cases? const size_t num_children = ZEND_AST_CONST_ENUM_INIT >> ZEND_AST_NUM_CHILDREN_SHIFT; @@ -597,7 +597,7 @@ static zend_ast_ref *create_enum_case_ast( return ref; } -zend_long zend_enum_next_case_id(zend_class_entry *enum_class) +int zend_enum_next_case_id(zend_class_entry *enum_class) { ZEND_HASH_REVERSE_FOREACH_VAL(&enum_class->constants_table, zval *zv) { zend_class_constant *c = Z_PTR_P(zv); @@ -635,7 +635,7 @@ ZEND_API void zend_enum_add_case(zend_class_entry *ce, zend_string *case_name, z ZEND_ASSERT(ce->enum_backing_type == IS_UNDEF); } - zend_long case_id = zend_enum_next_case_id(ce); + int case_id = zend_enum_next_case_id(ce); zval ast_zv; Z_TYPE_INFO(ast_zv) = IS_CONSTANT_AST; diff --git a/Zend/zend_enum.h b/Zend/zend_enum.h index 5531126479342..b8a7758443d24 100644 --- a/Zend/zend_enum.h +++ b/Zend/zend_enum.h @@ -31,7 +31,7 @@ extern ZEND_API zend_class_entry *zend_ce_backed_enum; extern ZEND_API zend_object_handlers zend_enum_object_handlers; typedef struct _zend_enum_obj { - zend_long case_id; + int case_id; zend_object std; } zend_enum_obj; @@ -44,11 +44,11 @@ void zend_enum_startup(void); void zend_register_enum_ce(void); void zend_enum_add_interfaces(zend_class_entry *ce); zend_result zend_enum_build_backed_enum_table(zend_class_entry *ce); -zend_object *zend_enum_new(zval *result, zend_class_entry *ce, zend_long case_id, zend_string *case_name, zval *backing_value_zv); +zend_object *zend_enum_new(zval *result, zend_class_entry *ce, int case_id, zend_string *case_name, zval *backing_value_zv); void zend_verify_enum(const zend_class_entry *ce); void zend_enum_register_funcs(zend_class_entry *ce); void zend_enum_register_props(zend_class_entry *ce); -zend_long zend_enum_next_case_id(zend_class_entry *enum_class); +int zend_enum_next_case_id(zend_class_entry *enum_class); ZEND_API zend_class_entry *zend_register_internal_enum( const char *name, uint8_t type, const zend_function_entry *functions); @@ -58,7 +58,7 @@ ZEND_API zend_object *zend_enum_get_case(zend_class_entry *ce, zend_string *name ZEND_API zend_object *zend_enum_get_case_cstr(zend_class_entry *ce, const char *name); ZEND_API zend_result zend_enum_get_case_by_value(zend_object **result, zend_class_entry *ce, zend_long long_key, zend_string *string_key, bool try_from); -static zend_always_inline zend_long zend_enum_fetch_case_id(zend_object *zobj) +static zend_always_inline int zend_enum_fetch_case_id(zend_object *zobj) { ZEND_ASSERT(zobj->ce->ce_flags & ZEND_ACC_ENUM); return zend_enum_obj_from_obj(zobj)->case_id; From a4b7313f238ee8e55dbffc3d290307fd6f0e2663 Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Tue, 13 Jan 2026 13:00:51 +0100 Subject: [PATCH 16/23] Fix build --- ext/pcntl/pcntl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/pcntl/pcntl.c b/ext/pcntl/pcntl.c index ff28ee3b64271..7ac5b7d5d6b83 100644 --- a/ext/pcntl/pcntl.c +++ b/ext/pcntl/pcntl.c @@ -1829,7 +1829,7 @@ static qos_class_t qos_enum_to_pthread(zend_enum_Pcntl_QosClass entry) qos_class_t qos_class; switch (entry) { - cse ZEND_ENUM_Pcntl_QosClass_UserInteractive: + case ZEND_ENUM_Pcntl_QosClass_UserInteractive: qos_class = QOS_CLASS_USER_INTERACTIVE; break; case ZEND_ENUM_Pcntl_QosClass_UserInitiated: From 734389ec97ecf8252b49abf25ab69d65446abf9c Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Tue, 13 Jan 2026 13:02:07 +0100 Subject: [PATCH 17/23] Mark generated files --- .gitattributes | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitattributes b/.gitattributes index 8dea3f8bbafbd..74fd9f995e8da 100644 --- a/.gitattributes +++ b/.gitattributes @@ -21,6 +21,7 @@ # Collapse generated files within git and pull request diff. **/*_arginfo.h linguist-generated -diff +**/*_decl.h linguist-generated -diff /main/debug_gdb_scripts.c linguist-generated -diff /Zend/zend_vm_execute.h linguist-generated -diff /Zend/zend_vm_handlers.h linguist-generated -diff From adfa2892d00e000f7a42da3f34fef5c2ab08a5ef Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Tue, 13 Jan 2026 13:13:47 +0100 Subject: [PATCH 18/23] Header guards --- build/gen_stub.php | 8 +++++++- ext/dom/php_dom_decl.h | 5 +++++ ext/pcntl/pcntl_decl.h | 5 +++++ ext/random/random_decl.h | 5 +++++ ext/reflection/php_reflection_decl.h | 5 +++++ ext/standard/basic_functions_decl.h | 5 +++++ ext/uri/php_uri_decl.h | 5 +++++ ext/zend_test/test_decl.h | 5 +++++ 8 files changed, 42 insertions(+), 1 deletion(-) diff --git a/build/gen_stub.php b/build/gen_stub.php index 1fcb6f10438ba..5747bd09583e7 100755 --- a/build/gen_stub.php +++ b/build/gen_stub.php @@ -5305,7 +5305,13 @@ static function (FuncInfo $funcInfo) use ($fileInfo, &$generatedFunctionDeclarat $declCode = $fileInfo->generateClassEntryCDeclarations(); if ($declCode !== '') { - $declCode = "/* This is a generated file, edit the .stub.php file instead. */\n" . $declCode; + $headerName = "ZEND_" . strtoupper($stubFilenameWithoutExtension) . "_DECL_{$stubHash}_H"; + $declCode = "/* This is a generated file, edit the .stub.php file instead. */\n" + . "\n" + . "#ifndef {$headerName}\n" + . "#define {$headerName}\n" + . $declCode . "\n" + . "#endif /* {$headerName} */\n"; } return [$code, $declCode]; diff --git a/ext/dom/php_dom_decl.h b/ext/dom/php_dom_decl.h index fed8ea0c3527c..a3db244630c90 100644 --- a/ext/dom/php_dom_decl.h +++ b/ext/dom/php_dom_decl.h @@ -1,8 +1,13 @@ /* This is a generated file, edit the .stub.php file instead. */ +#ifndef ZEND_PHP_DOM_DECL_e3495cb89e4466d9102abb10bf6461989b7c8ba9_H +#define ZEND_PHP_DOM_DECL_e3495cb89e4466d9102abb10bf6461989b7c8ba9_H + typedef enum zend_enum_Dom_AdjacentPosition { ZEND_ENUM_Dom_AdjacentPosition_BeforeBegin = 1, ZEND_ENUM_Dom_AdjacentPosition_AfterBegin = 2, ZEND_ENUM_Dom_AdjacentPosition_BeforeEnd = 3, ZEND_ENUM_Dom_AdjacentPosition_AfterEnd = 4, } zend_enum_Dom_AdjacentPosition; + +#endif /* ZEND_PHP_DOM_DECL_e3495cb89e4466d9102abb10bf6461989b7c8ba9_H */ diff --git a/ext/pcntl/pcntl_decl.h b/ext/pcntl/pcntl_decl.h index cae4e8057932e..d1110fe5194f3 100644 --- a/ext/pcntl/pcntl_decl.h +++ b/ext/pcntl/pcntl_decl.h @@ -1,5 +1,8 @@ /* This is a generated file, edit the .stub.php file instead. */ +#ifndef ZEND_PCNTL_DECL_5e4b066d70fa264c7de3ba4b2113369c34c33e43_H +#define ZEND_PCNTL_DECL_5e4b066d70fa264c7de3ba4b2113369c34c33e43_H + typedef enum zend_enum_Pcntl_QosClass { ZEND_ENUM_Pcntl_QosClass_UserInteractive = 1, ZEND_ENUM_Pcntl_QosClass_UserInitiated = 2, @@ -7,3 +10,5 @@ typedef enum zend_enum_Pcntl_QosClass { ZEND_ENUM_Pcntl_QosClass_Utility = 4, ZEND_ENUM_Pcntl_QosClass_Background = 5, } zend_enum_Pcntl_QosClass; + +#endif /* ZEND_PCNTL_DECL_5e4b066d70fa264c7de3ba4b2113369c34c33e43_H */ diff --git a/ext/random/random_decl.h b/ext/random/random_decl.h index 2e8078397bd2b..1bd1399b0cf8f 100644 --- a/ext/random/random_decl.h +++ b/ext/random/random_decl.h @@ -1,8 +1,13 @@ /* This is a generated file, edit the .stub.php file instead. */ +#ifndef ZEND_RANDOM_DECL_416be19494555016195600e488d79f0dd35f2620_H +#define ZEND_RANDOM_DECL_416be19494555016195600e488d79f0dd35f2620_H + typedef enum zend_enum_Random_IntervalBoundary { ZEND_ENUM_Random_IntervalBoundary_ClosedOpen = 1, ZEND_ENUM_Random_IntervalBoundary_ClosedClosed = 2, ZEND_ENUM_Random_IntervalBoundary_OpenClosed = 3, ZEND_ENUM_Random_IntervalBoundary_OpenOpen = 4, } zend_enum_Random_IntervalBoundary; + +#endif /* ZEND_RANDOM_DECL_416be19494555016195600e488d79f0dd35f2620_H */ diff --git a/ext/reflection/php_reflection_decl.h b/ext/reflection/php_reflection_decl.h index ac27efee50958..39dc8672d1bcc 100644 --- a/ext/reflection/php_reflection_decl.h +++ b/ext/reflection/php_reflection_decl.h @@ -1,6 +1,11 @@ /* This is a generated file, edit the .stub.php file instead. */ +#ifndef ZEND_PHP_REFLECTION_DECL_fd645a0b0db39d94ca25b39ffe64d7f05bad6bea_H +#define ZEND_PHP_REFLECTION_DECL_fd645a0b0db39d94ca25b39ffe64d7f05bad6bea_H + typedef enum zend_enum_PropertyHookType { ZEND_ENUM_PropertyHookType_Get = 1, ZEND_ENUM_PropertyHookType_Set = 2, } zend_enum_PropertyHookType; + +#endif /* ZEND_PHP_REFLECTION_DECL_fd645a0b0db39d94ca25b39ffe64d7f05bad6bea_H */ diff --git a/ext/standard/basic_functions_decl.h b/ext/standard/basic_functions_decl.h index dea0601b573f7..02c654c5d084b 100644 --- a/ext/standard/basic_functions_decl.h +++ b/ext/standard/basic_functions_decl.h @@ -1,5 +1,8 @@ /* This is a generated file, edit the .stub.php file instead. */ +#ifndef ZEND_BASIC_FUNCTIONS_DECL_1a1667a5c59111f096a758d5bb4aa7cf3ec09cfe_H +#define ZEND_BASIC_FUNCTIONS_DECL_1a1667a5c59111f096a758d5bb4aa7cf3ec09cfe_H + typedef enum zend_enum_RoundingMode { ZEND_ENUM_RoundingMode_HalfAwayFromZero = 1, ZEND_ENUM_RoundingMode_HalfTowardsZero = 2, @@ -10,3 +13,5 @@ typedef enum zend_enum_RoundingMode { ZEND_ENUM_RoundingMode_NegativeInfinity = 7, ZEND_ENUM_RoundingMode_PositiveInfinity = 8, } zend_enum_RoundingMode; + +#endif /* ZEND_BASIC_FUNCTIONS_DECL_1a1667a5c59111f096a758d5bb4aa7cf3ec09cfe_H */ diff --git a/ext/uri/php_uri_decl.h b/ext/uri/php_uri_decl.h index 94a8397508803..91305fab20fb7 100644 --- a/ext/uri/php_uri_decl.h +++ b/ext/uri/php_uri_decl.h @@ -1,5 +1,8 @@ /* This is a generated file, edit the .stub.php file instead. */ +#ifndef ZEND_PHP_URI_DECL_f3c524798d1933a400cc9377cfbfdcbaf77b87f0_H +#define ZEND_PHP_URI_DECL_f3c524798d1933a400cc9377cfbfdcbaf77b87f0_H + typedef enum zend_enum_Uri_UriComparisonMode { ZEND_ENUM_Uri_UriComparisonMode_IncludeFragment = 1, ZEND_ENUM_Uri_UriComparisonMode_ExcludeFragment = 2, @@ -36,3 +39,5 @@ typedef enum zend_enum_Uri_WhatWg_UrlValidationErrorType { ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_FileInvalidWindowsDriveLetter = 28, ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_FileInvalidWindowsDriveLetterHost = 29, } zend_enum_Uri_WhatWg_UrlValidationErrorType; + +#endif /* ZEND_PHP_URI_DECL_f3c524798d1933a400cc9377cfbfdcbaf77b87f0_H */ diff --git a/ext/zend_test/test_decl.h b/ext/zend_test/test_decl.h index 0f767a1ad80a7..875f3a2b452c1 100644 --- a/ext/zend_test/test_decl.h +++ b/ext/zend_test/test_decl.h @@ -1,5 +1,8 @@ /* This is a generated file, edit the .stub.php file instead. */ +#ifndef ZEND_TEST_DECL_25b63d5be5822cf0b717150dde07625cdd503c24_H +#define ZEND_TEST_DECL_25b63d5be5822cf0b717150dde07625cdd503c24_H + typedef enum zend_enum_ZendTestUnitEnum { ZEND_ENUM_ZendTestUnitEnum_Foo = 1, ZEND_ENUM_ZendTestUnitEnum_Bar = 2, @@ -22,3 +25,5 @@ typedef enum zend_enum_ZendTestEnumWithInterface { ZEND_ENUM_ZendTestEnumWithInterface_Foo = 1, ZEND_ENUM_ZendTestEnumWithInterface_Bar = 2, } zend_enum_ZendTestEnumWithInterface; + +#endif /* ZEND_TEST_DECL_25b63d5be5822cf0b717150dde07625cdd503c24_H */ From 0af48e054a188259fcf0f8d7b95573aa42152f9d Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Tue, 13 Jan 2026 13:27:29 +0100 Subject: [PATCH 19/23] WS --- ext/bcmath/bcmath.c | 1 - 1 file changed, 1 deletion(-) diff --git a/ext/bcmath/bcmath.c b/ext/bcmath/bcmath.c index 7c4ba49872103..2f545c142207a 100644 --- a/ext/bcmath/bcmath.c +++ b/ext/bcmath/bcmath.c @@ -1821,7 +1821,6 @@ PHP_METHOD(BcMath_Number, round) RETURN_THROWS(); } - bcmath_number_obj_t *intern = get_bcmath_number_from_zval(ZEND_THIS); bc_num ret = NULL; From 8607f51ada7a78c4b68eb569ee4a7d56a86d9bf3 Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Tue, 13 Jan 2026 15:12:00 +0100 Subject: [PATCH 20/23] Remove default case The compiler should now be able to tell us if we forget one case --- ext/dom/element.c | 2 -- ext/pcntl/pcntl.c | 2 -- ext/random/randomizer.c | 2 -- ext/standard/math.c | 3 ++- 4 files changed, 2 insertions(+), 7 deletions(-) diff --git a/ext/dom/element.c b/ext/dom/element.c index fcf01c286c5a9..b18bf16b881c8 100644 --- a/ext/dom/element.c +++ b/ext/dom/element.c @@ -1643,8 +1643,6 @@ static xmlNodePtr dom_insert_adjacent(zend_enum_Dom_AdjacentPosition where, xmlN return INSERT_ADJACENT_RES_PRE_INSERT_FAILED; } break; - default: - ZEND_UNREACHABLE(); } return otherp; } diff --git a/ext/pcntl/pcntl.c b/ext/pcntl/pcntl.c index 7ac5b7d5d6b83..1de4e2f978b15 100644 --- a/ext/pcntl/pcntl.c +++ b/ext/pcntl/pcntl.c @@ -1844,8 +1844,6 @@ static qos_class_t qos_enum_to_pthread(zend_enum_Pcntl_QosClass entry) case ZEND_ENUM_Pcntl_QosClass_Default: qos_class = QOS_CLASS_DEFAULT; break; - default: - ZEND_UNREACHABLE(); } return qos_class; diff --git a/ext/random/randomizer.c b/ext/random/randomizer.c index fbb0b85594ba3..28a814fa60559 100644 --- a/ext/random/randomizer.c +++ b/ext/random/randomizer.c @@ -187,8 +187,6 @@ PHP_METHOD(Random_Randomizer, getFloat) } return; - default: - ZEND_UNREACHABLE(); } } /* }}} */ diff --git a/ext/standard/math.c b/ext/standard/math.c index 346f8e59db215..19081e91cdad3 100644 --- a/ext/standard/math.c +++ b/ext/standard/math.c @@ -324,8 +324,9 @@ PHPAPI int php_math_round_mode_from_enum(zend_enum_RoundingMode mode) return PHP_ROUND_FLOOR; case ZEND_ENUM_RoundingMode_PositiveInfinity: return PHP_ROUND_CEILING; - EMPTY_SWITCH_DEFAULT_CASE(); } + + ZEND_UNREACHABLE(); } /* {{{ Returns the number rounded to specified precision */ From 804e7fa7b3f7f999c657ae122883daeaee1a368b Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Tue, 13 Jan 2026 15:22:47 +0100 Subject: [PATCH 21/23] Include _decl.h from the extension main header --- ext/dom/element.c | 1 - ext/dom/php_dom.h | 1 + ext/pcntl/pcntl.c | 1 - ext/pcntl/php_pcntl.h | 2 ++ ext/random/php_random.h | 1 + ext/random/randomizer.c | 1 - ext/reflection/php_reflection.c | 1 - ext/reflection/php_reflection.h | 1 + ext/standard/basic_functions.h | 2 ++ ext/standard/math.c | 1 - ext/uri/php_uri.c | 1 - ext/uri/php_uri_common.h | 2 ++ 12 files changed, 9 insertions(+), 6 deletions(-) diff --git a/ext/dom/element.c b/ext/dom/element.c index b18bf16b881c8..25bd306bcd808 100644 --- a/ext/dom/element.c +++ b/ext/dom/element.c @@ -28,7 +28,6 @@ #include "internal_helpers.h" #include "dom_properties.h" #include "token_list.h" -#include "php_dom_decl.h" /* * class DOMElement extends DOMNode diff --git a/ext/dom/php_dom.h b/ext/dom/php_dom.h index e44f74eadeb37..e93000044f00e 100644 --- a/ext/dom/php_dom.h +++ b/ext/dom/php_dom.h @@ -54,6 +54,7 @@ extern zend_module_entry dom_module_entry; #include "xpath_callbacks.h" #include "zend_exceptions.h" #include "dom_ce.h" +#include "php_dom_decl.h" /* DOM API_VERSION, please bump it up, if you change anything in the API therefore it's easier for the script-programmers to check, what's working how diff --git a/ext/pcntl/pcntl.c b/ext/pcntl/pcntl.c index 1de4e2f978b15..00906bb71760b 100644 --- a/ext/pcntl/pcntl.c +++ b/ext/pcntl/pcntl.c @@ -33,7 +33,6 @@ #include "php_ticks.h" #include "zend_fibers.h" #include "main/php_main.h" -#include "pcntl_decl.h" #if defined(HAVE_GETPRIORITY) || defined(HAVE_SETPRIORITY) || defined(HAVE_WAIT3) #include diff --git a/ext/pcntl/php_pcntl.h b/ext/pcntl/php_pcntl.h index f2cc0d59195f4..fb151e207b94c 100644 --- a/ext/pcntl/php_pcntl.h +++ b/ext/pcntl/php_pcntl.h @@ -17,6 +17,8 @@ #ifndef PHP_PCNTL_H #define PHP_PCNTL_H +#include "pcntl_decl.h" + #if defined(HAVE_DECL_WCONTINUED) && HAVE_DECL_WCONTINUED == 1 && defined(HAVE_WIFCONTINUED) && HAVE_WIFCONTINUED == 1 #define HAVE_WCONTINUED 1 #endif diff --git a/ext/random/php_random.h b/ext/random/php_random.h index 9db8c8ba19052..e4d6b4bdf3d93 100644 --- a/ext/random/php_random.h +++ b/ext/random/php_random.h @@ -34,6 +34,7 @@ # include "php.h" # include "php_random_csprng.h" # include "php_random_uint128.h" +# include "random_decl.h" PHPAPI double php_combined_lcg(void); diff --git a/ext/random/randomizer.c b/ext/random/randomizer.c index 28a814fa60559..a576cd12955af 100644 --- a/ext/random/randomizer.c +++ b/ext/random/randomizer.c @@ -20,7 +20,6 @@ #include "php.h" #include "php_random.h" -#include "random_decl.h" #include "ext/standard/php_array.h" #include "ext/standard/php_string.h" diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c index efe05b5aa356c..256468e39a444 100644 --- a/ext/reflection/php_reflection.c +++ b/ext/reflection/php_reflection.c @@ -31,7 +31,6 @@ #include "php.h" #include "php_ini.h" #include "php_reflection.h" -#include "php_reflection_decl.h" #include "ext/standard/info.h" #include "ext/standard/sha1.h" #include "ext/random/php_random_csprng.h" diff --git a/ext/reflection/php_reflection.h b/ext/reflection/php_reflection.h index d676597fd0bed..dc22407342985 100644 --- a/ext/reflection/php_reflection.h +++ b/ext/reflection/php_reflection.h @@ -18,6 +18,7 @@ #define PHP_REFLECTION_H #include "php.h" +#include "php_reflection_decl.h" extern zend_module_entry reflection_module_entry; #define phpext_reflection_ptr &reflection_module_entry diff --git a/ext/standard/basic_functions.h b/ext/standard/basic_functions.h index e5b85fbc2d53c..004279b9d1ae7 100644 --- a/ext/standard/basic_functions.h +++ b/ext/standard/basic_functions.h @@ -27,6 +27,8 @@ #include "url_scanner_ex.h" +#include "basic_functions_decl.h" + #if defined(_WIN32) && !defined(__clang__) #include #endif diff --git a/ext/standard/math.c b/ext/standard/math.c index 19081e91cdad3..6418a020f4fad 100644 --- a/ext/standard/math.c +++ b/ext/standard/math.c @@ -19,7 +19,6 @@ #include "php.h" #include "php_math.h" -#include "basic_functions_decl.h" #include "zend_bitset.h" #include "zend_enum.h" #include "zend_exceptions.h" diff --git a/ext/uri/php_uri.c b/ext/uri/php_uri.c index ddc7e7ff5a92f..1a347d0fb98cb 100644 --- a/ext/uri/php_uri.c +++ b/ext/uri/php_uri.c @@ -26,7 +26,6 @@ #include "ext/standard/info.h" #include "php_uri.h" -#include "php_uri_decl.h" #include "uri_parser_whatwg.h" #include "uri_parser_rfc3986.h" #include "uri_parser_php_parse_url.h" diff --git a/ext/uri/php_uri_common.h b/ext/uri/php_uri_common.h index 109236879ae7f..2ae76cb2ee4dc 100644 --- a/ext/uri/php_uri_common.h +++ b/ext/uri/php_uri_common.h @@ -17,6 +17,8 @@ #ifndef PHP_URI_COMMON_H #define PHP_URI_COMMON_H +#include "php_uri_decl.h" + extern zend_class_entry *php_uri_ce_rfc3986_uri; extern zend_class_entry *php_uri_ce_whatwg_url; extern zend_class_entry *php_uri_ce_comparison_mode; From 816e94c81c43900cce19addfcb297008c4d97b8a Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Tue, 13 Jan 2026 15:29:45 +0100 Subject: [PATCH 22/23] Switch over enum constants --- ext/bcmath/bcmath.c | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/ext/bcmath/bcmath.c b/ext/bcmath/bcmath.c index 2f545c142207a..ee9d97c9c16dd 100644 --- a/ext/bcmath/bcmath.c +++ b/ext/bcmath/bcmath.c @@ -801,15 +801,15 @@ PHP_FUNCTION(bcround) mode = php_math_round_mode_from_enum(mode_enum); - switch (mode) { - case PHP_ROUND_HALF_UP: - case PHP_ROUND_HALF_DOWN: - case PHP_ROUND_HALF_EVEN: - case PHP_ROUND_HALF_ODD: - case PHP_ROUND_CEILING: - case PHP_ROUND_FLOOR: - case PHP_ROUND_TOWARD_ZERO: - case PHP_ROUND_AWAY_FROM_ZERO: + switch (mode_enum) { + case ZEND_ENUM_RoundingMode_HalfAwayFromZero: + case ZEND_ENUM_RoundingMode_HalfTowardsZero: + case ZEND_ENUM_RoundingMode_HalfEven: + case ZEND_ENUM_RoundingMode_HalfOdd: + case ZEND_ENUM_RoundingMode_TowardsZero: + case ZEND_ENUM_RoundingMode_AwayFromZero: + case ZEND_ENUM_RoundingMode_NegativeInfinity: + case ZEND_ENUM_RoundingMode_PositiveInfinity: break; default: /* This is currently unreachable, but might become reachable when new modes are added. */ @@ -1806,15 +1806,15 @@ PHP_METHOD(BcMath_Number, round) rounding_mode = php_math_round_mode_from_enum(mode_enum); - switch (rounding_mode) { - case PHP_ROUND_HALF_UP: - case PHP_ROUND_HALF_DOWN: - case PHP_ROUND_HALF_EVEN: - case PHP_ROUND_HALF_ODD: - case PHP_ROUND_CEILING: - case PHP_ROUND_FLOOR: - case PHP_ROUND_TOWARD_ZERO: - case PHP_ROUND_AWAY_FROM_ZERO: + switch (mode_enum) { + case ZEND_ENUM_RoundingMode_HalfAwayFromZero: + case ZEND_ENUM_RoundingMode_HalfTowardsZero: + case ZEND_ENUM_RoundingMode_HalfEven: + case ZEND_ENUM_RoundingMode_HalfOdd: + case ZEND_ENUM_RoundingMode_TowardsZero: + case ZEND_ENUM_RoundingMode_AwayFromZero: + case ZEND_ENUM_RoundingMode_NegativeInfinity: + case ZEND_ENUM_RoundingMode_PositiveInfinity: break; default: zend_argument_value_error(2, "is an unsupported rounding mode"); From 86141672fd4d868e4064567f0320d8cd60e99e40 Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Wed, 14 Jan 2026 11:41:34 +0100 Subject: [PATCH 23/23] Check that decl files are up to date --- Zend/zend_attributes_arginfo.h | 4 +- Zend/zend_builtin_functions_arginfo.h | 4 +- Zend/zend_closures_arginfo.h | 4 +- Zend/zend_constants_arginfo.h | 4 +- Zend/zend_enum_arginfo.h | 4 +- Zend/zend_exceptions_arginfo.h | 4 +- Zend/zend_fibers_arginfo.h | 4 +- Zend/zend_generators_arginfo.h | 4 +- Zend/zend_interfaces_arginfo.h | 4 +- Zend/zend_weakrefs_arginfo.h | 4 +- build/gen_stub.php | 46 +++++++++++++++---- ext/bcmath/bcmath_arginfo.h | 4 +- ext/bz2/bz2_arginfo.h | 4 +- ext/calendar/calendar_arginfo.h | 4 +- ext/com_dotnet/com_extension_arginfo.h | 4 +- ext/com_dotnet/com_persist_arginfo.h | 4 +- ext/ctype/ctype_arginfo.h | 4 +- ext/curl/curl_arginfo.h | 4 +- ext/curl/curl_file_arginfo.h | 4 +- ext/date/php_date_arginfo.h | 4 +- ext/dba/dba_arginfo.h | 4 +- ext/dl_test/dl_test_arginfo.h | 4 +- ext/dom/php_dom_arginfo.h | 5 +- ext/dom/php_dom_decl.h | 9 ++-- ext/enchant/enchant_arginfo.h | 4 +- ext/exif/exif_arginfo.h | 4 +- ext/ffi/ffi_arginfo.h | 4 +- ext/fileinfo/fileinfo_arginfo.h | 4 +- ext/filter/filter_arginfo.h | 4 +- ext/ftp/ftp_arginfo.h | 4 +- ext/gd/gd_arginfo.h | 4 +- ext/gettext/gettext_arginfo.h | 4 +- ext/gmp/gmp_arginfo.h | 4 +- ext/hash/hash_arginfo.h | 4 +- ext/iconv/iconv_arginfo.h | 4 +- .../breakiterator/breakiterator_arginfo.h | 4 +- .../breakiterator_iterators_arginfo.h | 4 +- ext/intl/calendar/calendar_arginfo.h | 4 +- ext/intl/collator/collator_arginfo.h | 4 +- ext/intl/common/common_arginfo.h | 4 +- ext/intl/converter/converter_arginfo.h | 4 +- ext/intl/dateformat/dateformat_arginfo.h | 4 +- .../dateformat/datepatterngenerator_arginfo.h | 4 +- ext/intl/formatter/formatter_arginfo.h | 4 +- .../listformatter/listformatter_arginfo.h | 4 +- ext/intl/locale/locale_arginfo.h | 4 +- ext/intl/msgformat/msgformat_arginfo.h | 4 +- ext/intl/normalizer/normalizer_arginfo.h | 4 +- ext/intl/php_intl_arginfo.h | 4 +- .../rangeformatter/rangeformatter_arginfo.h | 4 +- .../resourcebundle/resourcebundle_arginfo.h | 4 +- ext/intl/spoofchecker/spoofchecker_arginfo.h | 4 +- ext/intl/timezone/timezone_arginfo.h | 4 +- .../transliterator/transliterator_arginfo.h | 4 +- ext/intl/uchar/uchar_arginfo.h | 4 +- ext/json/json_arginfo.h | 4 +- ext/ldap/ldap_arginfo.h | 4 +- ext/libxml/libxml_arginfo.h | 4 +- ext/mbstring/mbstring_arginfo.h | 4 +- ext/mysqli/mysqli_arginfo.h | 4 +- ext/odbc/odbc_arginfo.h | 4 +- ext/opcache/opcache_arginfo.h | 4 +- ext/openssl/openssl_arginfo.h | 4 +- ext/openssl/openssl_pwhash_arginfo.h | 4 +- ext/pcntl/pcntl_arginfo.h | 5 +- ext/pcntl/pcntl_decl.h | 9 ++-- ext/pcre/php_pcre_arginfo.h | 4 +- ext/pdo/pdo_arginfo.h | 4 +- ext/pdo/pdo_dbh_arginfo.h | 4 +- ext/pdo/pdo_stmt_arginfo.h | 4 +- ext/pdo_dblib/pdo_dblib_arginfo.h | 4 +- ext/pdo_firebird/pdo_firebird_arginfo.h | 4 +- ext/pdo_mysql/pdo_mysql_arginfo.h | 4 +- ext/pdo_odbc/pdo_odbc_arginfo.h | 4 +- ext/pdo_pgsql/pdo_pgsql_arginfo.h | 4 +- ext/pdo_pgsql/pgsql_driver_arginfo.h | 4 +- ext/pdo_sqlite/pdo_sqlite_arginfo.h | 4 +- ext/pdo_sqlite/sqlite_driver_arginfo.h | 4 +- ext/pgsql/pgsql_arginfo.h | 4 +- ext/phar/phar_object_arginfo.h | 4 +- ext/posix/posix_arginfo.h | 4 +- ext/random/random_arginfo.h | 5 +- ext/random/random_decl.h | 9 ++-- ext/readline/readline_arginfo.h | 4 +- ext/reflection/php_reflection_arginfo.h | 5 +- ext/reflection/php_reflection_decl.h | 9 ++-- ext/session/session_arginfo.h | 4 +- ext/shmop/shmop_arginfo.h | 4 +- ext/simplexml/simplexml_arginfo.h | 4 +- ext/skeleton/skeleton_arginfo.h | 4 +- ext/snmp/snmp_arginfo.h | 4 +- ext/soap/soap_arginfo.h | 4 +- ext/sockets/sockets_arginfo.h | 4 +- ext/sodium/libsodium_arginfo.h | 4 +- ext/sodium/sodium_pwhash_arginfo.h | 4 +- ext/spl/php_spl_arginfo.h | 4 +- ext/spl/spl_array_arginfo.h | 4 +- ext/spl/spl_directory_arginfo.h | 4 +- ext/spl/spl_dllist_arginfo.h | 4 +- ext/spl/spl_exceptions_arginfo.h | 4 +- ext/spl/spl_fixedarray_arginfo.h | 4 +- ext/spl/spl_heap_arginfo.h | 4 +- ext/spl/spl_iterators_arginfo.h | 4 +- ext/spl/spl_observer_arginfo.h | 4 +- ext/sqlite3/sqlite3_arginfo.h | 4 +- ext/standard/basic_functions_arginfo.h | 5 +- ext/standard/basic_functions_decl.h | 9 ++-- ext/standard/dir_arginfo.h | 4 +- ext/standard/dl_arginfo.h | 4 +- ext/standard/file_arginfo.h | 4 +- ext/standard/password_arginfo.h | 4 +- ext/standard/user_filters_arginfo.h | 4 +- ext/sysvmsg/sysvmsg_arginfo.h | 4 +- ext/sysvsem/sysvsem_arginfo.h | 4 +- ext/sysvshm/sysvshm_arginfo.h | 4 +- ext/tidy/tidy_arginfo.h | 4 +- ext/tokenizer/tokenizer_arginfo.h | 4 +- ext/tokenizer/tokenizer_data_arginfo.h | 4 +- ext/uri/php_uri_arginfo.h | 5 +- ext/uri/php_uri_decl.h | 9 ++-- ext/xml/xml_arginfo.h | 4 +- ext/xmlreader/php_xmlreader_arginfo.h | 4 +- ext/xmlwriter/php_xmlwriter_arginfo.h | 4 +- ext/xsl/php_xsl_arginfo.h | 4 +- ext/zend_test/fiber_arginfo.h | 4 +- ext/zend_test/iterators_arginfo.h | 4 +- ext/zend_test/object_handlers_arginfo.h | 4 +- ext/zend_test/test_arginfo.h | 5 +- ext/zend_test/test_decl.h | 9 ++-- ext/zend_test/tmp_methods_arginfo.h | 4 +- ext/zip/php_zip_arginfo.h | 4 +- ext/zlib/zlib_arginfo.h | 4 +- main/main_arginfo.h | 4 +- main/streams/userspace_arginfo.h | 4 +- sapi/apache2handler/php_functions_arginfo.h | 4 +- sapi/cgi/cgi_main_arginfo.h | 4 +- sapi/cli/php_cli_process_title_arginfo.h | 4 +- sapi/cli/php_cli_server_arginfo.h | 4 +- sapi/fpm/fpm/fpm_main_arginfo.h | 4 +- sapi/litespeed/lsapi_main_arginfo.h | 4 +- sapi/phpdbg/phpdbg_arginfo.h | 4 +- 141 files changed, 344 insertions(+), 304 deletions(-) diff --git a/Zend/zend_attributes_arginfo.h b/Zend/zend_attributes_arginfo.h index ec8d8de4ee508..49f3a838607ec 100644 --- a/Zend/zend_attributes_arginfo.h +++ b/Zend/zend_attributes_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: b868cb33f41d9442f42d0cec84e33fcc09f5d88c */ +/* This is a generated file, edit zend_attributes.stub.php instead. + * Stub hash: f162d636dbb412d0d15bd9e15da32cddd79da019 */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Attribute___construct, 0, 0, 0) ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, flags, IS_LONG, 0, "Attribute::TARGET_ALL") diff --git a/Zend/zend_builtin_functions_arginfo.h b/Zend/zend_builtin_functions_arginfo.h index 17484eb03f253..7c21a6dcdc5fb 100644 --- a/Zend/zend_builtin_functions_arginfo.h +++ b/Zend/zend_builtin_functions_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 9b49f527064695c812cd204d9efc63c13681d942 */ +/* This is a generated file, edit zend_builtin_functions.stub.php instead. + * Stub hash: 7a82309f77fe0d79435dc0d80cc42c8cf9e05181 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_clone, 0, 1, IS_OBJECT, 0) ZEND_ARG_TYPE_INFO(0, object, IS_OBJECT, 0) diff --git a/Zend/zend_closures_arginfo.h b/Zend/zend_closures_arginfo.h index 4ce02c40e55a7..0df2c21113ec5 100644 --- a/Zend/zend_closures_arginfo.h +++ b/Zend/zend_closures_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: e0626e52adb2d38dad1140c1a28cc7774cc84500 */ +/* This is a generated file, edit zend_closures.stub.php instead. + * Stub hash: 0554b928581150fd9f01026184850f1b42b98522 */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Closure___construct, 0, 0, 0) ZEND_END_ARG_INFO() diff --git a/Zend/zend_constants_arginfo.h b/Zend/zend_constants_arginfo.h index 316b7e37615fd..0759b77d23717 100644 --- a/Zend/zend_constants_arginfo.h +++ b/Zend/zend_constants_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 569ccba4e0a93a9ce49c81c76955413188df390e */ +/* This is a generated file, edit zend_constants.stub.php instead. + * Stub hash: 6e262e3a0bf0cff42c8360457aec18c746e4e868 */ static void register_zend_constants_symbols(int module_number) { diff --git a/Zend/zend_enum_arginfo.h b/Zend/zend_enum_arginfo.h index 64c36ff3c33af..7fdfc41ee7ccf 100644 --- a/Zend/zend_enum_arginfo.h +++ b/Zend/zend_enum_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 7092f1d4ba651f077cff37050899f090f00abf22 */ +/* This is a generated file, edit zend_enum.stub.php instead. + * Stub hash: e67dfb1377650d3537440bc4ebcd7d9b9f1cf9d2 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_UnitEnum_cases, 0, 0, IS_ARRAY, 0) ZEND_END_ARG_INFO() diff --git a/Zend/zend_exceptions_arginfo.h b/Zend/zend_exceptions_arginfo.h index cef37a1f0f0b9..f193f043b6044 100644 --- a/Zend/zend_exceptions_arginfo.h +++ b/Zend/zend_exceptions_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: ba1562ca8fe2fe48c40bc52d10545aa989afd86c */ +/* This is a generated file, edit zend_exceptions.stub.php instead. + * Stub hash: 9f58693def15b468244d89bb9feaa5078b391bfa */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Throwable_getMessage, 0, 0, IS_STRING, 0) ZEND_END_ARG_INFO() diff --git a/Zend/zend_fibers_arginfo.h b/Zend/zend_fibers_arginfo.h index 9db4db8d802af..1677a69bd5468 100644 --- a/Zend/zend_fibers_arginfo.h +++ b/Zend/zend_fibers_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: e82bbc8e81fe98873a9a5697a4b38e63a24379da */ +/* This is a generated file, edit zend_fibers.stub.php instead. + * Stub hash: c05002d3fc4f0f6d653a87d7ce89fdd55e0df7cc */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Fiber___construct, 0, 0, 1) ZEND_ARG_TYPE_INFO(0, callback, IS_CALLABLE, 0) diff --git a/Zend/zend_generators_arginfo.h b/Zend/zend_generators_arginfo.h index 54a6744af1b64..c2cb5251f23cc 100644 --- a/Zend/zend_generators_arginfo.h +++ b/Zend/zend_generators_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: d376e984db0db6ccd9356f632f9d7e1382b2afb7 */ +/* This is a generated file, edit zend_generators.stub.php instead. + * Stub hash: f823338a833db862c1b1d4c9b82f23054a52a25b */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Generator_rewind, 0, 0, IS_VOID, 0) ZEND_END_ARG_INFO() diff --git a/Zend/zend_interfaces_arginfo.h b/Zend/zend_interfaces_arginfo.h index 8a90166b2d800..178ab2257b4e2 100644 --- a/Zend/zend_interfaces_arginfo.h +++ b/Zend/zend_interfaces_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: a9c915c11e5989d8c7cf2d704ada09ca765670c3 */ +/* This is a generated file, edit zend_interfaces.stub.php instead. + * Stub hash: dc29d8d9dae463fed153fc08d11d1222087caa3a */ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_OBJ_INFO_EX(arginfo_class_IteratorAggregate_getIterator, 0, 0, Traversable, 0) ZEND_END_ARG_INFO() diff --git a/Zend/zend_weakrefs_arginfo.h b/Zend/zend_weakrefs_arginfo.h index eba02f03fb13c..5ba551c618762 100644 --- a/Zend/zend_weakrefs_arginfo.h +++ b/Zend/zend_weakrefs_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: d91889851d9732d41e43fffddb6235d033c67534 */ +/* This is a generated file, edit zend_weakrefs.stub.php instead. + * Stub hash: 85e62bf02485a388738e33524a784399edd98d9f */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_WeakReference___construct, 0, 0, 0) ZEND_END_ARG_INFO() diff --git a/build/gen_stub.php b/build/gen_stub.php index 5747bd09583e7..b343be4f444b1 100755 --- a/build/gen_stub.php +++ b/build/gen_stub.php @@ -84,10 +84,20 @@ function processStubFile(string $stubFile, Context $context, bool $includeOnly = $legacyFile = "{$stubFilenameWithoutExtension}_legacy_arginfo.h"; $declFile = "{$stubFilenameWithoutExtension}_decl.h"; + /* Check if the stub file changed, by checking that the hash stored + * in the generated arginfo.h matches. + * Also check that the decl.h file has the same hash. At this point + * we don't know if a decl.h file is supposed to exist, so extract + * this information (whether a decl file should exist) from the + * arginfo.h file. */ $stubCode = file_get_contents($stubFile); - $stubHash = sha1(str_replace("\r\n", "\n", $stubCode)); + $stubHash = sha1(str_replace("\r\n", "\n", $stubCode) . '_v2'); $oldStubHash = extractStubHash($arginfoFile); - if ($stubHash === $oldStubHash && !$context->forceParse) { + $hasDeclHeader = extractHasDeclHeader($arginfoFile); + $oldStubHashDecl = extractStubHash($declFile); + $generatedFilesUpToDate = $stubHash === $oldStubHash + && ($hasDeclHeader ? $stubHash === $oldStubHashDecl : $oldStubHashDecl === null); + if ($generatedFilesUpToDate && !$context->forceParse) { /* Stub file did not change, do not regenerate. */ return null; } @@ -129,12 +139,12 @@ function processStubFile(string $stubFile, Context $context, bool $includeOnly = $context->allConstInfos, $stubHash ); - if ($context->forceRegeneration || $stubHash !== $oldStubHash) { + if ($context->forceRegeneration || !$generatedFilesUpToDate) { reportFilePutContents($arginfoFile, $arginfoCode); if ($declCode !== '') { reportFilePutContents($declFile, $declCode); - } else if (file_exists($declCode)) { - unlink($declCode); + } else if (file_exists($declFile)) { + unlink($declFile); } } @@ -147,7 +157,7 @@ function processStubFile(string $stubFile, Context $context, bool $includeOnly = $context->allConstInfos, $stubHash ); - if ($context->forceRegeneration || $stubHash !== $oldStubHash) { + if ($context->forceRegeneration || !$generatedFilesUpToDate) { reportFilePutContents($legacyFile, $arginfoCode); } } @@ -165,13 +175,22 @@ function extractStubHash(string $arginfoFile): ?string { } $arginfoCode = file_get_contents($arginfoFile); - if (!preg_match('/\* Stub hash: ([0-9a-f]+) \*/', $arginfoCode, $matches)) { + if (!preg_match('/\* Stub hash: ([0-9a-f]+)/', $arginfoCode, $matches)) { return null; } return $matches[1]; } +function extractHasDeclHeader(string $arginfoFile): bool { + if (!file_exists($arginfoFile)) { + return false; + } + + $arginfoCode = file_get_contents($arginfoFile); + return str_contains($arginfoCode, '* Has decl header: yes *'); +} + class Context { public bool $forceParse = false; public bool $forceRegeneration = false; @@ -5209,8 +5228,7 @@ function generateArgInfoCode( array $allConstInfos, string $stubHash ): array { - $code = "/* This is a generated file, edit the .stub.php file instead.\n" - . " * Stub hash: $stubHash */\n"; + $code = ""; $generatedFuncInfos = []; @@ -5303,10 +5321,13 @@ static function (FuncInfo $funcInfo) use ($fileInfo, &$generatedFunctionDeclarat } + $hasDeclFile = false; $declCode = $fileInfo->generateClassEntryCDeclarations(); if ($declCode !== '') { + $hasDeclFile = true; $headerName = "ZEND_" . strtoupper($stubFilenameWithoutExtension) . "_DECL_{$stubHash}_H"; - $declCode = "/* This is a generated file, edit the .stub.php file instead. */\n" + $declCode = "/* This is a generated file, edit {$stubFilenameWithoutExtension}.stub.php instead.\n" + . " * Stub hash: $stubHash */\n" . "\n" . "#ifndef {$headerName}\n" . "#define {$headerName}\n" @@ -5314,6 +5335,11 @@ static function (FuncInfo $funcInfo) use ($fileInfo, &$generatedFunctionDeclarat . "#endif /* {$headerName} */\n"; } + $code = "/* This is a generated file, edit {$stubFilenameWithoutExtension}.stub.php instead.\n" + . " * Stub hash: $stubHash" + . ($hasDeclFile ? "\n * Has decl header: yes */\n" : " */\n") + . $code; + return [$code, $declCode]; } diff --git a/ext/bcmath/bcmath_arginfo.h b/ext/bcmath/bcmath_arginfo.h index 15325603f211e..436fe910dec96 100644 --- a/ext/bcmath/bcmath_arginfo.h +++ b/ext/bcmath/bcmath_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 687d6fb392a9b0c1329152cc0f62341a73e427f4 */ +/* This is a generated file, edit bcmath.stub.php instead. + * Stub hash: 92823a89d2683efb741b1e48389a73d809f9efa8 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_bcadd, 0, 2, IS_STRING, 0) ZEND_ARG_TYPE_INFO(0, num1, IS_STRING, 0) diff --git a/ext/bz2/bz2_arginfo.h b/ext/bz2/bz2_arginfo.h index bac3b57023dcf..198b600ad1c86 100644 --- a/ext/bz2/bz2_arginfo.h +++ b/ext/bz2/bz2_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: c2c8e0fe1e3244c8cadafe60b65b7235c105b3c9 */ +/* This is a generated file, edit bz2.stub.php instead. + * Stub hash: e7d069727898e9b53907499279d1ce9d22ee106f */ ZEND_BEGIN_ARG_INFO_EX(arginfo_bzopen, 0, 0, 2) ZEND_ARG_INFO(0, file) diff --git a/ext/calendar/calendar_arginfo.h b/ext/calendar/calendar_arginfo.h index 68bf73492fadd..70856427d782d 100644 --- a/ext/calendar/calendar_arginfo.h +++ b/ext/calendar/calendar_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: f45116785b01842f56ff923a54f65ab839b3dd61 */ +/* This is a generated file, edit calendar.stub.php instead. + * Stub hash: e1492746fe0dd9d1c35381e8c22c316f1292d3a8 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_cal_days_in_month, 0, 3, IS_LONG, 0) ZEND_ARG_TYPE_INFO(0, calendar, IS_LONG, 0) diff --git a/ext/com_dotnet/com_extension_arginfo.h b/ext/com_dotnet/com_extension_arginfo.h index a2bcbf31c968b..0ce35de99a4fb 100644 --- a/ext/com_dotnet/com_extension_arginfo.h +++ b/ext/com_dotnet/com_extension_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 9b2eea541946c291eb002ee98997f3dcad8bdfce */ +/* This is a generated file, edit com_extension.stub.php instead. + * Stub hash: 07d248fcc69b3a90bf6ec6efd8ae15d9478c8f00 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_variant_set, 0, 2, IS_VOID, 0) ZEND_ARG_OBJ_INFO(0, variant, variant, 0) diff --git a/ext/com_dotnet/com_persist_arginfo.h b/ext/com_dotnet/com_persist_arginfo.h index 4449396e9ccef..90e2b10d88424 100644 --- a/ext/com_dotnet/com_persist_arginfo.h +++ b/ext/com_dotnet/com_persist_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: d14d30fb232f08da37ba0df0b9186eb8bac5e1a4 */ +/* This is a generated file, edit com_persist.stub.php instead. + * Stub hash: 46c8263791804a343e28af5ff7fe91eb9eaf08bf */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_COMPersistHelper___construct, 0, 0, 0) ZEND_ARG_OBJ_INFO_WITH_DEFAULT_VALUE(0, variant, variant, 1, "null") diff --git a/ext/ctype/ctype_arginfo.h b/ext/ctype/ctype_arginfo.h index 07ee0159dd7d3..70d35da6e8de5 100644 --- a/ext/ctype/ctype_arginfo.h +++ b/ext/ctype/ctype_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 155783e1858a7f24dbc1c3e810d5cffee5468bf7 */ +/* This is a generated file, edit ctype.stub.php instead. + * Stub hash: 63fb33e0c4f505ddce2442219cd17b0d9054db48 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_ctype_alnum, 0, 1, _IS_BOOL, 0) ZEND_ARG_TYPE_INFO(0, text, IS_MIXED, 0) diff --git a/ext/curl/curl_arginfo.h b/ext/curl/curl_arginfo.h index 25fac2948bf2e..b9b64abbe512c 100644 --- a/ext/curl/curl_arginfo.h +++ b/ext/curl/curl_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 10ebdc94560ed19ecd6b61a11b3dab5d32989d66 */ +/* This is a generated file, edit curl.stub.php instead. + * Stub hash: 5da54718ff65b4ba9cbb58dba5214be8676690da */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_curl_close, 0, 1, IS_VOID, 0) ZEND_ARG_OBJ_INFO(0, handle, CurlHandle, 0) diff --git a/ext/curl/curl_file_arginfo.h b/ext/curl/curl_file_arginfo.h index 9ddd1f39d8986..0015311161a26 100644 --- a/ext/curl/curl_file_arginfo.h +++ b/ext/curl/curl_file_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 0d09bd2f3b0a155cef25ca343319ecf470424d71 */ +/* This is a generated file, edit curl_file.stub.php instead. + * Stub hash: 43a6e8aaf38c6148f8f65231e70cd7a186536b82 */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_CURLFile___construct, 0, 0, 1) ZEND_ARG_TYPE_INFO(0, filename, IS_STRING, 0) diff --git a/ext/date/php_date_arginfo.h b/ext/date/php_date_arginfo.h index 74541e13a5c19..872694c56952b 100644 --- a/ext/date/php_date_arginfo.h +++ b/ext/date/php_date_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 8556e1b5f05ae9f78200f05f01d9f8e815cba49d */ +/* This is a generated file, edit php_date.stub.php instead. + * Stub hash: e241a8be63145ed3bbc87b38f676123b6b437496 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_strtotime, 0, 1, MAY_BE_LONG|MAY_BE_FALSE) ZEND_ARG_TYPE_INFO(0, datetime, IS_STRING, 0) diff --git a/ext/dba/dba_arginfo.h b/ext/dba/dba_arginfo.h index 6274c1dd43956..f9b451ec598cc 100644 --- a/ext/dba/dba_arginfo.h +++ b/ext/dba/dba_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: d7ff53b73d3921c41ffd8279ea724bcd3a6d8542 */ +/* This is a generated file, edit dba.stub.php instead. + * Stub hash: 78469c0b6e94800f52d9615cbb3cde3ed5b7f90b */ ZEND_BEGIN_ARG_WITH_RETURN_OBJ_TYPE_MASK_EX(arginfo_dba_popen, 0, 2, Dba\\Connection, MAY_BE_FALSE) ZEND_ARG_TYPE_INFO(0, path, IS_STRING, 0) diff --git a/ext/dl_test/dl_test_arginfo.h b/ext/dl_test/dl_test_arginfo.h index 0b246bd0df1ee..218250d24398c 100644 --- a/ext/dl_test/dl_test_arginfo.h +++ b/ext/dl_test/dl_test_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 3c47a0da41b4548eb68c4124bd54cbac22f60c01 */ +/* This is a generated file, edit dl_test.stub.php instead. + * Stub hash: 3c1f9111807e87587106869fc87ac8fa8db2aa8a */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_dl_test_test1, 0, 0, IS_VOID, 0) ZEND_END_ARG_INFO() diff --git a/ext/dom/php_dom_arginfo.h b/ext/dom/php_dom_arginfo.h index 1f3f9fd0a8a24..17dc479fcdcad 100644 --- a/ext/dom/php_dom_arginfo.h +++ b/ext/dom/php_dom_arginfo.h @@ -1,5 +1,6 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: e3495cb89e4466d9102abb10bf6461989b7c8ba9 */ +/* This is a generated file, edit php_dom.stub.php instead. + * Stub hash: d91f2c59f62e07522e448bdfb7dc4bb4da3810f7 + * Has decl header: yes */ ZEND_BEGIN_ARG_WITH_RETURN_OBJ_TYPE_MASK_EX(arginfo_dom_import_simplexml, 0, 1, DOMAttr|DOMElement, 0) ZEND_ARG_TYPE_INFO(0, node, IS_OBJECT, 0) diff --git a/ext/dom/php_dom_decl.h b/ext/dom/php_dom_decl.h index a3db244630c90..f7e2cbc5efa16 100644 --- a/ext/dom/php_dom_decl.h +++ b/ext/dom/php_dom_decl.h @@ -1,7 +1,8 @@ -/* This is a generated file, edit the .stub.php file instead. */ +/* This is a generated file, edit php_dom.stub.php instead. + * Stub hash: d91f2c59f62e07522e448bdfb7dc4bb4da3810f7 */ -#ifndef ZEND_PHP_DOM_DECL_e3495cb89e4466d9102abb10bf6461989b7c8ba9_H -#define ZEND_PHP_DOM_DECL_e3495cb89e4466d9102abb10bf6461989b7c8ba9_H +#ifndef ZEND_PHP_DOM_DECL_d91f2c59f62e07522e448bdfb7dc4bb4da3810f7_H +#define ZEND_PHP_DOM_DECL_d91f2c59f62e07522e448bdfb7dc4bb4da3810f7_H typedef enum zend_enum_Dom_AdjacentPosition { ZEND_ENUM_Dom_AdjacentPosition_BeforeBegin = 1, @@ -10,4 +11,4 @@ typedef enum zend_enum_Dom_AdjacentPosition { ZEND_ENUM_Dom_AdjacentPosition_AfterEnd = 4, } zend_enum_Dom_AdjacentPosition; -#endif /* ZEND_PHP_DOM_DECL_e3495cb89e4466d9102abb10bf6461989b7c8ba9_H */ +#endif /* ZEND_PHP_DOM_DECL_d91f2c59f62e07522e448bdfb7dc4bb4da3810f7_H */ diff --git a/ext/enchant/enchant_arginfo.h b/ext/enchant/enchant_arginfo.h index 01681072346a0..e88774cb20958 100644 --- a/ext/enchant/enchant_arginfo.h +++ b/ext/enchant/enchant_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 31974eb901477da53ede7476953d461d32f772ba */ +/* This is a generated file, edit enchant.stub.php instead. + * Stub hash: 7d43ba7e88f1adc55e5a3dd4dea40614d675a8b7 */ ZEND_BEGIN_ARG_WITH_RETURN_OBJ_TYPE_MASK_EX(arginfo_enchant_broker_init, 0, 0, EnchantBroker, MAY_BE_FALSE) ZEND_END_ARG_INFO() diff --git a/ext/exif/exif_arginfo.h b/ext/exif/exif_arginfo.h index c9e42b9a47704..5bf83a1a25cde 100644 --- a/ext/exif/exif_arginfo.h +++ b/ext/exif/exif_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 633b2db018fa1453845a854a6361f11f107f4653 */ +/* This is a generated file, edit exif.stub.php instead. + * Stub hash: a821c3755ce4e41b76d98eef7c605a4ff296cfa7 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_exif_tagname, 0, 1, MAY_BE_STRING|MAY_BE_FALSE) ZEND_ARG_TYPE_INFO(0, index, IS_LONG, 0) diff --git a/ext/ffi/ffi_arginfo.h b/ext/ffi/ffi_arginfo.h index 1485c973d9a11..a5182674cbf5a 100644 --- a/ext/ffi/ffi_arginfo.h +++ b/ext/ffi/ffi_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: d3626f5d39317876fc7d4f240b0758f17f3472c8 */ +/* This is a generated file, edit ffi.stub.php instead. + * Stub hash: 5faa1e0e0e39022d0678d7fb51a6a44041e31fe7 */ ZEND_BEGIN_ARG_WITH_RETURN_OBJ_INFO_EX(arginfo_class_FFI_cdef, 0, 0, FFI, 0) ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, code, IS_STRING, 0, "\"\"") diff --git a/ext/fileinfo/fileinfo_arginfo.h b/ext/fileinfo/fileinfo_arginfo.h index ac6ba0f591f98..a508483fff387 100644 --- a/ext/fileinfo/fileinfo_arginfo.h +++ b/ext/fileinfo/fileinfo_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 311d1049e32af017b44e260a00f13830714b1e96 */ +/* This is a generated file, edit fileinfo.stub.php instead. + * Stub hash: ecd3ac48a9658bca9f13bb4267aa50290a88aa06 */ ZEND_BEGIN_ARG_WITH_RETURN_OBJ_TYPE_MASK_EX(arginfo_finfo_open, 0, 0, finfo, MAY_BE_FALSE) ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, flags, IS_LONG, 0, "FILEINFO_NONE") diff --git a/ext/filter/filter_arginfo.h b/ext/filter/filter_arginfo.h index c777b6ffe77e0..6e60535f605ff 100644 --- a/ext/filter/filter_arginfo.h +++ b/ext/filter/filter_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: c3eb55dfec619af1e46be206f51a2b0893ed399f */ +/* This is a generated file, edit filter.stub.php instead. + * Stub hash: 6bfb91c6d21755ee8abd316683bfe6b6b417b7a3 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_filter_has_var, 0, 2, _IS_BOOL, 0) ZEND_ARG_TYPE_INFO(0, input_type, IS_LONG, 0) diff --git a/ext/ftp/ftp_arginfo.h b/ext/ftp/ftp_arginfo.h index 77bc47df03f69..aede818ceb230 100644 --- a/ext/ftp/ftp_arginfo.h +++ b/ext/ftp/ftp_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 29606d7114a0698b8ae231173a624b17c196ffec */ +/* This is a generated file, edit ftp.stub.php instead. + * Stub hash: 86639bcb2e0c3a521785f7be7920074f9a1c8091 */ ZEND_BEGIN_ARG_WITH_RETURN_OBJ_TYPE_MASK_EX(arginfo_ftp_connect, 0, 1, FTP\\Connection, MAY_BE_FALSE) ZEND_ARG_TYPE_INFO(0, hostname, IS_STRING, 0) diff --git a/ext/gd/gd_arginfo.h b/ext/gd/gd_arginfo.h index 87cbfa54b945d..63d200e61949e 100644 --- a/ext/gd/gd_arginfo.h +++ b/ext/gd/gd_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 2cdc0b485d9b62bb9021973d3c8cce0169b21ac0 */ +/* This is a generated file, edit gd.stub.php instead. + * Stub hash: b458babcc6a4ae5d3bb0115952a2a87b5ed20cad */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_gd_info, 0, 0, IS_ARRAY, 0) ZEND_END_ARG_INFO() diff --git a/ext/gettext/gettext_arginfo.h b/ext/gettext/gettext_arginfo.h index 265f6cd900edc..d6abcdab9dfc1 100644 --- a/ext/gettext/gettext_arginfo.h +++ b/ext/gettext/gettext_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: c675dc9492943bbac106c5906b75c31436964423 */ +/* This is a generated file, edit gettext.stub.php instead. + * Stub hash: 84c7721876b2cf5cfc3c1fb89156271c54b16bbf */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_textdomain, 0, 0, IS_STRING, 0) ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, domain, IS_STRING, 1, "null") diff --git a/ext/gmp/gmp_arginfo.h b/ext/gmp/gmp_arginfo.h index 31927d3e482bc..0dbace4a767de 100644 --- a/ext/gmp/gmp_arginfo.h +++ b/ext/gmp/gmp_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 3aabd5a5d2db0df15b249a425465ae718c13ab6b */ +/* This is a generated file, edit gmp.stub.php instead. + * Stub hash: cf0cd6a5c63ff8e532c35ef60de2d832175a9dd5 */ ZEND_BEGIN_ARG_WITH_RETURN_OBJ_INFO_EX(arginfo_gmp_init, 0, 1, GMP, 0) ZEND_ARG_TYPE_MASK(0, num, MAY_BE_LONG|MAY_BE_STRING, NULL) diff --git a/ext/hash/hash_arginfo.h b/ext/hash/hash_arginfo.h index 0fb4407221af4..2b6e1e716c458 100644 --- a/ext/hash/hash_arginfo.h +++ b/ext/hash/hash_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: b0fe91da9b0469b44a9647b774b9b00498592e30 */ +/* This is a generated file, edit hash.stub.php instead. + * Stub hash: 9b94f44b8a36111de1d1956c6b40ef2e8b180c4b */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_hash, 0, 2, IS_STRING, 0) ZEND_ARG_TYPE_INFO(0, algo, IS_STRING, 0) diff --git a/ext/iconv/iconv_arginfo.h b/ext/iconv/iconv_arginfo.h index df2ecad3898e9..345f572097426 100644 --- a/ext/iconv/iconv_arginfo.h +++ b/ext/iconv/iconv_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 4367fa431d3e4814e42d9aa514c10cae1d842d8f */ +/* This is a generated file, edit iconv.stub.php instead. + * Stub hash: e42b2857b622bbf5864df0e6817558b7c08a28e6 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_iconv_strlen, 0, 1, MAY_BE_LONG|MAY_BE_FALSE) ZEND_ARG_TYPE_INFO(0, string, IS_STRING, 0) diff --git a/ext/intl/breakiterator/breakiterator_arginfo.h b/ext/intl/breakiterator/breakiterator_arginfo.h index afaad17f03dbf..3ede9a5003bde 100644 --- a/ext/intl/breakiterator/breakiterator_arginfo.h +++ b/ext/intl/breakiterator/breakiterator_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 08122a53702dd08727cc88144419dcc4eb9299af */ +/* This is a generated file, edit breakiterator.stub.php instead. + * Stub hash: ebcdd096ed51cc743d15c9f5bb55fb0b1c266d27 */ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_OBJ_INFO_EX(arginfo_class_IntlBreakIterator_createCharacterInstance, 0, 0, IntlBreakIterator, 1) ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, locale, IS_STRING, 1, "null") diff --git a/ext/intl/breakiterator/breakiterator_iterators_arginfo.h b/ext/intl/breakiterator/breakiterator_iterators_arginfo.h index f4d0975a897f8..14a5ba9ddb957 100644 --- a/ext/intl/breakiterator/breakiterator_iterators_arginfo.h +++ b/ext/intl/breakiterator/breakiterator_iterators_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 5dc9ab2cc5862b2082fb9cd5cec909298921b115 */ +/* This is a generated file, edit breakiterator_iterators.stub.php instead. + * Stub hash: 79bded38c8da25cc83e35804dd12fa0728bebbcd */ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_OBJ_INFO_EX(arginfo_class_IntlPartsIterator_getBreakIterator, 0, 0, IntlBreakIterator, 0) ZEND_END_ARG_INFO() diff --git a/ext/intl/calendar/calendar_arginfo.h b/ext/intl/calendar/calendar_arginfo.h index f9c5a018d9a8c..b0b1cb739771d 100644 --- a/ext/intl/calendar/calendar_arginfo.h +++ b/ext/intl/calendar/calendar_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 2fc12d1fde65efbec4305f4934a3f4b25282a552 */ +/* This is a generated file, edit calendar.stub.php instead. + * Stub hash: 456f22e15ab1ca5badc2706a4913af6016757736 */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_IntlCalendar___construct, 0, 0, 0) ZEND_END_ARG_INFO() diff --git a/ext/intl/collator/collator_arginfo.h b/ext/intl/collator/collator_arginfo.h index a35adbd3d1e05..bee8b03eccf7f 100644 --- a/ext/intl/collator/collator_arginfo.h +++ b/ext/intl/collator/collator_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: cbe3c5f4c35d93f90c3e7164bdfc4e2fefc88c83 */ +/* This is a generated file, edit collator.stub.php instead. + * Stub hash: a12372cc2813498491364d9792aaf6d43f374dec */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Collator___construct, 0, 0, 1) ZEND_ARG_TYPE_INFO(0, locale, IS_STRING, 0) diff --git a/ext/intl/common/common_arginfo.h b/ext/intl/common/common_arginfo.h index 64b362a660a06..0ed6e4a49469c 100644 --- a/ext/intl/common/common_arginfo.h +++ b/ext/intl/common/common_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 9ed8bfc955a557c02171ec12b4634c60c6fb513e */ +/* This is a generated file, edit common.stub.php instead. + * Stub hash: fc3b8a439a8ca04a138542413bf6d2ccbc4c5a2d */ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_IntlIterator_current, 0, 0, IS_MIXED, 0) ZEND_END_ARG_INFO() diff --git a/ext/intl/converter/converter_arginfo.h b/ext/intl/converter/converter_arginfo.h index 9808e50b39dc8..a72bf23abeb4c 100644 --- a/ext/intl/converter/converter_arginfo.h +++ b/ext/intl/converter/converter_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: f351fbf3afd9753fb16c87903c3dbd5e4621c024 */ +/* This is a generated file, edit converter.stub.php instead. + * Stub hash: fa5b55d5fa2ef453fbc3f2232df5c8ce1d4d33ee */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_UConverter___construct, 0, 0, 0) ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, destination_encoding, IS_STRING, 1, "null") diff --git a/ext/intl/dateformat/dateformat_arginfo.h b/ext/intl/dateformat/dateformat_arginfo.h index 5a5c6a9f34c29..17e3dcf94ba77 100644 --- a/ext/intl/dateformat/dateformat_arginfo.h +++ b/ext/intl/dateformat/dateformat_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 160d05ec65c45b66b13eaecbef20b3c59bfb33d1 */ +/* This is a generated file, edit dateformat.stub.php instead. + * Stub hash: 43beec3c2c8d6e52d0a7d7061ee762d0ad383536 */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_IntlDateFormatter___construct, 0, 0, 1) ZEND_ARG_TYPE_INFO(0, locale, IS_STRING, 1) diff --git a/ext/intl/dateformat/datepatterngenerator_arginfo.h b/ext/intl/dateformat/datepatterngenerator_arginfo.h index 14327b0d69f88..a00fdde949df6 100644 --- a/ext/intl/dateformat/datepatterngenerator_arginfo.h +++ b/ext/intl/dateformat/datepatterngenerator_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 4456b13f7ed59847bbf129cd45b0d1f63ce70108 */ +/* This is a generated file, edit datepatterngenerator.stub.php instead. + * Stub hash: 3cad54dab7ddd6c0e52acb32108c7462d39ae744 */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_IntlDatePatternGenerator___construct, 0, 0, 0) ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, locale, IS_STRING, 1, "null") diff --git a/ext/intl/formatter/formatter_arginfo.h b/ext/intl/formatter/formatter_arginfo.h index df111763f8b96..d534d9fcfdf4e 100644 --- a/ext/intl/formatter/formatter_arginfo.h +++ b/ext/intl/formatter/formatter_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: d886941aa76837aed1da08845dbaff9442107203 */ +/* This is a generated file, edit formatter.stub.php instead. + * Stub hash: 65c80cf3fcb60b88f0829995c75bafefc441212b */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_NumberFormatter___construct, 0, 0, 2) ZEND_ARG_TYPE_INFO(0, locale, IS_STRING, 0) diff --git a/ext/intl/listformatter/listformatter_arginfo.h b/ext/intl/listformatter/listformatter_arginfo.h index fda62aac9691d..45022889056d4 100644 --- a/ext/intl/listformatter/listformatter_arginfo.h +++ b/ext/intl/listformatter/listformatter_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: cdbbdb55d1e53f422c5854460c3c6cc3d01360d7 */ +/* This is a generated file, edit listformatter.stub.php instead. + * Stub hash: 669dc7a82ef8ea85c15999ef4b0c827865e74919 */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_IntlListFormatter___construct, 0, 0, 1) ZEND_ARG_TYPE_INFO(0, locale, IS_STRING, 0) diff --git a/ext/intl/locale/locale_arginfo.h b/ext/intl/locale/locale_arginfo.h index e6fde7981a98c..eb62fae7900db 100644 --- a/ext/intl/locale/locale_arginfo.h +++ b/ext/intl/locale/locale_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: ff1f75bd34a52f57210734e2f5e29efb87566137 */ +/* This is a generated file, edit locale.stub.php instead. + * Stub hash: b636567fc6b8652c8381b24014d92ca591c1aff1 */ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_Locale_getDefault, 0, 0, IS_STRING, 0) ZEND_END_ARG_INFO() diff --git a/ext/intl/msgformat/msgformat_arginfo.h b/ext/intl/msgformat/msgformat_arginfo.h index 74353fbf93ae2..e00861e57b2cb 100644 --- a/ext/intl/msgformat/msgformat_arginfo.h +++ b/ext/intl/msgformat/msgformat_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: d595f5c582996ebb96ab39df8cb56c4cf6c8dfcf */ +/* This is a generated file, edit msgformat.stub.php instead. + * Stub hash: b0afb28094334b63df28bd77199170c9dbf916d1 */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_MessageFormatter___construct, 0, 0, 2) ZEND_ARG_TYPE_INFO(0, locale, IS_STRING, 0) diff --git a/ext/intl/normalizer/normalizer_arginfo.h b/ext/intl/normalizer/normalizer_arginfo.h index 23ce84b1c76e1..aa653809655ab 100644 --- a/ext/intl/normalizer/normalizer_arginfo.h +++ b/ext/intl/normalizer/normalizer_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 908a9587edd132a41100be09c9908e088f3fa055 */ +/* This is a generated file, edit normalizer.stub.php instead. + * Stub hash: ea69f1291fce7cd2de93155e018da6d584443c5a */ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_MASK_EX(arginfo_class_Normalizer_normalize, 0, 1, MAY_BE_STRING|MAY_BE_FALSE) ZEND_ARG_TYPE_INFO(0, string, IS_STRING, 0) diff --git a/ext/intl/php_intl_arginfo.h b/ext/intl/php_intl_arginfo.h index f778e4cacf3d4..12e9cc07609d0 100644 --- a/ext/intl/php_intl_arginfo.h +++ b/ext/intl/php_intl_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: d9e331c3a1ae46f8eae07ef0d39cb9990e74a0d1 */ +/* This is a generated file, edit php_intl.stub.php instead. + * Stub hash: 8ef9fa6990b906a1bbe5f1d01ef184f748ae6ebe */ ZEND_BEGIN_ARG_WITH_RETURN_OBJ_INFO_EX(arginfo_intlcal_create_instance, 0, 0, IntlCalendar, 1) ZEND_ARG_OBJ_TYPE_MASK(0, timezone, IntlTimeZone|DateTimeZone, MAY_BE_STRING|MAY_BE_NULL, "null") diff --git a/ext/intl/rangeformatter/rangeformatter_arginfo.h b/ext/intl/rangeformatter/rangeformatter_arginfo.h index ef3255415d16a..0d5944acd0e76 100644 --- a/ext/intl/rangeformatter/rangeformatter_arginfo.h +++ b/ext/intl/rangeformatter/rangeformatter_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 7029642524e32984e893e1e050a5e0bbf275c416 */ +/* This is a generated file, edit rangeformatter.stub.php instead. + * Stub hash: 97f483aee3bef46557c91db83268c09f818694c0 */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_IntlNumberRangeFormatter___construct, 0, 0, 0) ZEND_END_ARG_INFO() diff --git a/ext/intl/resourcebundle/resourcebundle_arginfo.h b/ext/intl/resourcebundle/resourcebundle_arginfo.h index f52de6314aa5d..20fe199f0342a 100644 --- a/ext/intl/resourcebundle/resourcebundle_arginfo.h +++ b/ext/intl/resourcebundle/resourcebundle_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: e302e5ca1abcb9b52e3c14abbd38b9e8f1461390 */ +/* This is a generated file, edit resourcebundle.stub.php instead. + * Stub hash: 6c1faed4ac86bc10157a8becbb47c7bf1853c5d6 */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_ResourceBundle___construct, 0, 0, 2) ZEND_ARG_TYPE_INFO(0, locale, IS_STRING, 1) diff --git a/ext/intl/spoofchecker/spoofchecker_arginfo.h b/ext/intl/spoofchecker/spoofchecker_arginfo.h index fa8996b8f24eb..2e971329acf4a 100644 --- a/ext/intl/spoofchecker/spoofchecker_arginfo.h +++ b/ext/intl/spoofchecker/spoofchecker_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 4834be57a3f0cb74dbc4422e609846139f09f6cb */ +/* This is a generated file, edit spoofchecker.stub.php instead. + * Stub hash: 05f11c45faa271f46a7ee71591c440fff120f435 */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Spoofchecker___construct, 0, 0, 0) ZEND_END_ARG_INFO() diff --git a/ext/intl/timezone/timezone_arginfo.h b/ext/intl/timezone/timezone_arginfo.h index 418d2901fe935..ccac0be28f650 100644 --- a/ext/intl/timezone/timezone_arginfo.h +++ b/ext/intl/timezone/timezone_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 22e652c6a05ade0a6fd3119e4742cd260ba27146 */ +/* This is a generated file, edit timezone.stub.php instead. + * Stub hash: 8632daa1d66e07dadbdaaa52d276dbe5bb3b7e3e */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_IntlTimeZone___construct, 0, 0, 0) ZEND_END_ARG_INFO() diff --git a/ext/intl/transliterator/transliterator_arginfo.h b/ext/intl/transliterator/transliterator_arginfo.h index c5a5bcc6090dd..de20a2156db53 100644 --- a/ext/intl/transliterator/transliterator_arginfo.h +++ b/ext/intl/transliterator/transliterator_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 300bcc64e5ddaf469bfe4a12e65a6677bf2aea88 */ +/* This is a generated file, edit transliterator.stub.php instead. + * Stub hash: 349a70c0b176f12a9bafcbe1a0d5644c628ecd9a */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Transliterator___construct, 0, 0, 0) ZEND_END_ARG_INFO() diff --git a/ext/intl/uchar/uchar_arginfo.h b/ext/intl/uchar/uchar_arginfo.h index 9f69dc597c219..658fe5b56e216 100644 --- a/ext/intl/uchar/uchar_arginfo.h +++ b/ext/intl/uchar/uchar_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 58fb5f326ee08cca73977720d3b055b0118d78bb */ +/* This is a generated file, edit uchar.stub.php instead. + * Stub hash: 76f8cee5927db92e91649d4e2da9ab94cac8466b */ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_IntlChar_hasBinaryProperty, 0, 2, _IS_BOOL, 1) ZEND_ARG_TYPE_MASK(0, codepoint, MAY_BE_LONG|MAY_BE_STRING, NULL) diff --git a/ext/json/json_arginfo.h b/ext/json/json_arginfo.h index 6b1eb0f1a50a3..1cecd44b29e59 100644 --- a/ext/json/json_arginfo.h +++ b/ext/json/json_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 0ceb50047401c4b9e878c09cc518eacc274f7fff */ +/* This is a generated file, edit json.stub.php instead. + * Stub hash: 0beef3d8b5d467f22253f019cbc47fe01567fb5a */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_json_encode, 0, 1, MAY_BE_STRING|MAY_BE_FALSE) ZEND_ARG_TYPE_INFO(0, value, IS_MIXED, 0) diff --git a/ext/ldap/ldap_arginfo.h b/ext/ldap/ldap_arginfo.h index 25aa03343ace0..02dfdd973e361 100644 --- a/ext/ldap/ldap_arginfo.h +++ b/ext/ldap/ldap_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 9e47a0d85336f0e149abbdf56468513c5d31780f */ +/* This is a generated file, edit ldap.stub.php instead. + * Stub hash: a5f818786f4be50da076f88d70643cee5ef887f6 */ #if defined(HAVE_ORALDAP) ZEND_BEGIN_ARG_WITH_RETURN_OBJ_TYPE_MASK_EX(arginfo_ldap_connect, 0, 0, LDAP\\Connection, MAY_BE_FALSE) diff --git a/ext/libxml/libxml_arginfo.h b/ext/libxml/libxml_arginfo.h index 9e3e07c83e503..647ad0d3e9e44 100644 --- a/ext/libxml/libxml_arginfo.h +++ b/ext/libxml/libxml_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 6dceb619736a3de55b84609a9e3aeb13405bbfde */ +/* This is a generated file, edit libxml.stub.php instead. + * Stub hash: b1eb9ff697340bc53e63fa700cebb3458cf2ede1 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_libxml_set_streams_context, 0, 1, IS_VOID, 0) ZEND_ARG_INFO(0, context) diff --git a/ext/mbstring/mbstring_arginfo.h b/ext/mbstring/mbstring_arginfo.h index 230dddf96941c..e67207d065bcb 100644 --- a/ext/mbstring/mbstring_arginfo.h +++ b/ext/mbstring/mbstring_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 03c07f68bea7d7b96e6dc11f180f45663b859ed3 */ +/* This is a generated file, edit mbstring.stub.php instead. + * Stub hash: e46326d63709e6d9f5abbfc1aa50d7e725abc4b2 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_mb_language, 0, 0, MAY_BE_STRING|MAY_BE_BOOL) ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, language, IS_STRING, 1, "null") diff --git a/ext/mysqli/mysqli_arginfo.h b/ext/mysqli/mysqli_arginfo.h index 789464a762538..11a1a50dabaa4 100644 --- a/ext/mysqli/mysqli_arginfo.h +++ b/ext/mysqli/mysqli_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: fecde55745fb219cb15fd35a54a71371ef2b8b7d */ +/* This is a generated file, edit mysqli.stub.php instead. + * Stub hash: 3de85ff952611031c26f47d43e2a07a2a17bd18f */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_mysqli_affected_rows, 0, 1, MAY_BE_LONG|MAY_BE_STRING) ZEND_ARG_OBJ_INFO(0, mysql, mysqli, 0) diff --git a/ext/odbc/odbc_arginfo.h b/ext/odbc/odbc_arginfo.h index 0298adf2c1c4f..6dfa651232468 100644 --- a/ext/odbc/odbc_arginfo.h +++ b/ext/odbc/odbc_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: f9ba28767b256dbcea087a65aa4bb5f5b509d6f3 */ +/* This is a generated file, edit odbc.stub.php instead. + * Stub hash: a1187e18d88bb80e459fb50ba26b4133ac185dfa */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_odbc_close_all, 0, 0, IS_VOID, 0) ZEND_END_ARG_INFO() diff --git a/ext/opcache/opcache_arginfo.h b/ext/opcache/opcache_arginfo.h index 7fff6b1eb0da9..22ed9aabfff95 100644 --- a/ext/opcache/opcache_arginfo.h +++ b/ext/opcache/opcache_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: a8de025fa96a78db3a26d53a18bb2b365d094eca */ +/* This is a generated file, edit opcache.stub.php instead. + * Stub hash: 52868e3b6e4e59d78ca99b86a78c0b5203421b60 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_opcache_reset, 0, 0, _IS_BOOL, 0) ZEND_END_ARG_INFO() diff --git a/ext/openssl/openssl_arginfo.h b/ext/openssl/openssl_arginfo.h index 796582c185bb6..46e44ca574b87 100644 --- a/ext/openssl/openssl_arginfo.h +++ b/ext/openssl/openssl_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 8233a8abc8ab7145d905d0fa51478edfe1e55a06 */ +/* This is a generated file, edit openssl.stub.php instead. + * Stub hash: baedf43e9a3343a20ff6eea93c6e54f23b0f5114 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_openssl_x509_export_to_file, 0, 2, _IS_BOOL, 0) ZEND_ARG_OBJ_TYPE_MASK(0, certificate, OpenSSLCertificate, MAY_BE_STRING, NULL) diff --git a/ext/openssl/openssl_pwhash_arginfo.h b/ext/openssl/openssl_pwhash_arginfo.h index 13ce9203f5c32..7b565b381725d 100644 --- a/ext/openssl/openssl_pwhash_arginfo.h +++ b/ext/openssl/openssl_pwhash_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 23ee957ba4945be3a21db58051e548729c3ff44e */ +/* This is a generated file, edit openssl_pwhash.stub.php instead. + * Stub hash: ed51d491aa59f3b39e39eb4a0c86bed15a37eb91 */ static void register_openssl_pwhash_symbols(int module_number) { diff --git a/ext/pcntl/pcntl_arginfo.h b/ext/pcntl/pcntl_arginfo.h index 8b2367a7c7042..28c6c9d61b055 100644 --- a/ext/pcntl/pcntl_arginfo.h +++ b/ext/pcntl/pcntl_arginfo.h @@ -1,5 +1,6 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 5e4b066d70fa264c7de3ba4b2113369c34c33e43 */ +/* This is a generated file, edit pcntl.stub.php instead. + * Stub hash: 5d5d372367a3e962a03dafbf52c6e519931d9d91 + * Has decl header: yes */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_pcntl_fork, 0, 0, IS_LONG, 0) ZEND_END_ARG_INFO() diff --git a/ext/pcntl/pcntl_decl.h b/ext/pcntl/pcntl_decl.h index d1110fe5194f3..323040da2445e 100644 --- a/ext/pcntl/pcntl_decl.h +++ b/ext/pcntl/pcntl_decl.h @@ -1,7 +1,8 @@ -/* This is a generated file, edit the .stub.php file instead. */ +/* This is a generated file, edit pcntl.stub.php instead. + * Stub hash: 5d5d372367a3e962a03dafbf52c6e519931d9d91 */ -#ifndef ZEND_PCNTL_DECL_5e4b066d70fa264c7de3ba4b2113369c34c33e43_H -#define ZEND_PCNTL_DECL_5e4b066d70fa264c7de3ba4b2113369c34c33e43_H +#ifndef ZEND_PCNTL_DECL_5d5d372367a3e962a03dafbf52c6e519931d9d91_H +#define ZEND_PCNTL_DECL_5d5d372367a3e962a03dafbf52c6e519931d9d91_H typedef enum zend_enum_Pcntl_QosClass { ZEND_ENUM_Pcntl_QosClass_UserInteractive = 1, @@ -11,4 +12,4 @@ typedef enum zend_enum_Pcntl_QosClass { ZEND_ENUM_Pcntl_QosClass_Background = 5, } zend_enum_Pcntl_QosClass; -#endif /* ZEND_PCNTL_DECL_5e4b066d70fa264c7de3ba4b2113369c34c33e43_H */ +#endif /* ZEND_PCNTL_DECL_5d5d372367a3e962a03dafbf52c6e519931d9d91_H */ diff --git a/ext/pcre/php_pcre_arginfo.h b/ext/pcre/php_pcre_arginfo.h index 86eaf0d8d60f3..9417f18fe02b0 100644 --- a/ext/pcre/php_pcre_arginfo.h +++ b/ext/pcre/php_pcre_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 63de1d37ab303e1d6af7c96eaeeba09d7f35d116 */ +/* This is a generated file, edit php_pcre.stub.php instead. + * Stub hash: 27f8c4f7d847b5d1ee85c11987941148d9555da9 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_preg_match, 0, 2, MAY_BE_LONG|MAY_BE_FALSE) ZEND_ARG_TYPE_INFO(0, pattern, IS_STRING, 0) diff --git a/ext/pdo/pdo_arginfo.h b/ext/pdo/pdo_arginfo.h index 8f452cf4b032c..2491f97020358 100644 --- a/ext/pdo/pdo_arginfo.h +++ b/ext/pdo/pdo_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: dc41dddeea1ae117c6f2f3447afb29bf6623b757 */ +/* This is a generated file, edit pdo.stub.php instead. + * Stub hash: c4e5a42ae3d2cb6822caf2017cf932591873c022 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_pdo_drivers, 0, 0, IS_ARRAY, 0) ZEND_END_ARG_INFO() diff --git a/ext/pdo/pdo_dbh_arginfo.h b/ext/pdo/pdo_dbh_arginfo.h index cc622a52e2688..be40676257ebd 100644 --- a/ext/pdo/pdo_dbh_arginfo.h +++ b/ext/pdo/pdo_dbh_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 006be61b2c519e7d9ca997a7f12135eb3e0f3500 */ +/* This is a generated file, edit pdo_dbh.stub.php instead. + * Stub hash: 82506fecf40bbcc20ae6fc9518c69165e379379f */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_PDO___construct, 0, 0, 1) ZEND_ARG_TYPE_INFO(0, dsn, IS_STRING, 0) diff --git a/ext/pdo/pdo_stmt_arginfo.h b/ext/pdo/pdo_stmt_arginfo.h index 0be8ee82d84d6..c0134db7aeda5 100644 --- a/ext/pdo/pdo_stmt_arginfo.h +++ b/ext/pdo/pdo_stmt_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 6a5b332ba4bfeceaca6aad734d38dabb66d82c97 */ +/* This is a generated file, edit pdo_stmt.stub.php instead. + * Stub hash: 5807f1b86c7602bc53f81ffbf31fed95353c79e1 */ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_PDOStatement_bindColumn, 0, 2, _IS_BOOL, 0) ZEND_ARG_TYPE_MASK(0, column, MAY_BE_STRING|MAY_BE_LONG, NULL) diff --git a/ext/pdo_dblib/pdo_dblib_arginfo.h b/ext/pdo_dblib/pdo_dblib_arginfo.h index 2452255265a33..62131118ac22f 100644 --- a/ext/pdo_dblib/pdo_dblib_arginfo.h +++ b/ext/pdo_dblib/pdo_dblib_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 95f297028aee0675523d6984c03a518e4fc431df */ +/* This is a generated file, edit pdo_dblib.stub.php instead. + * Stub hash: ada550a5c626565e2521e94910cbe48edcb8283d */ static zend_class_entry *register_class_Pdo_Dblib(zend_class_entry *class_entry_PDO) { diff --git a/ext/pdo_firebird/pdo_firebird_arginfo.h b/ext/pdo_firebird/pdo_firebird_arginfo.h index fd500a6130c0a..7b4667cfa9357 100644 --- a/ext/pdo_firebird/pdo_firebird_arginfo.h +++ b/ext/pdo_firebird/pdo_firebird_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: d36b2055abc48ae91c3442dda68fa2a28eb6d25b */ +/* This is a generated file, edit pdo_firebird.stub.php instead. + * Stub hash: e4697aebda9fb60ad32209fecdc242a81c03174c */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Pdo_Firebird_getApiVersion, 0, 0, IS_LONG, 0) ZEND_END_ARG_INFO() diff --git a/ext/pdo_mysql/pdo_mysql_arginfo.h b/ext/pdo_mysql/pdo_mysql_arginfo.h index 516109fa0520a..686ba903d453a 100644 --- a/ext/pdo_mysql/pdo_mysql_arginfo.h +++ b/ext/pdo_mysql/pdo_mysql_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 9d2c0327499693f1ca2825a9ad42ad769f44a24a */ +/* This is a generated file, edit pdo_mysql.stub.php instead. + * Stub hash: ac283136418556ed252b67b78e790be5637189a8 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Pdo_Mysql_getWarningCount, 0, 0, IS_LONG, 0) ZEND_END_ARG_INFO() diff --git a/ext/pdo_odbc/pdo_odbc_arginfo.h b/ext/pdo_odbc/pdo_odbc_arginfo.h index d8ee0524feb5f..081801cbb47cf 100644 --- a/ext/pdo_odbc/pdo_odbc_arginfo.h +++ b/ext/pdo_odbc/pdo_odbc_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 9136c911494c9e3462c49b3e58f4bcc15ebb2a9c */ +/* This is a generated file, edit pdo_odbc.stub.php instead. + * Stub hash: a9b29e4c09c22e62b32f3dde13532179ec69706c */ static void register_pdo_odbc_symbols(int module_number) { diff --git a/ext/pdo_pgsql/pdo_pgsql_arginfo.h b/ext/pdo_pgsql/pdo_pgsql_arginfo.h index 296207471a198..ee45062d16312 100644 --- a/ext/pdo_pgsql/pdo_pgsql_arginfo.h +++ b/ext/pdo_pgsql/pdo_pgsql_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 0ea21010467d661416f0858f2bda095583ea3a36 */ +/* This is a generated file, edit pdo_pgsql.stub.php instead. + * Stub hash: e63b904e73f71fdfbb9b4cff27ef0227d90cac6c */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Pdo_Pgsql_escapeIdentifier, 0, 1, IS_STRING, 0) ZEND_ARG_TYPE_INFO(0, input, IS_STRING, 0) diff --git a/ext/pdo_pgsql/pgsql_driver_arginfo.h b/ext/pdo_pgsql/pgsql_driver_arginfo.h index cd01e2e8e7160..ddddb00a84d9d 100644 --- a/ext/pdo_pgsql/pgsql_driver_arginfo.h +++ b/ext/pdo_pgsql/pgsql_driver_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 30c01b4d2e7f836b81a31dc0c1a115883eb41568 */ +/* This is a generated file, edit pgsql_driver.stub.php instead. + * Stub hash: 8664dac3e021991860b032d5ad4b0d415b22fabf */ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_PDO_PGSql_Ext_pgsqlCopyFromArray, 0, 2, _IS_BOOL, 0) ZEND_ARG_TYPE_INFO(0, tableName, IS_STRING, 0) diff --git a/ext/pdo_sqlite/pdo_sqlite_arginfo.h b/ext/pdo_sqlite/pdo_sqlite_arginfo.h index f50cdacdc2ec6..b183ef539f44f 100644 --- a/ext/pdo_sqlite/pdo_sqlite_arginfo.h +++ b/ext/pdo_sqlite/pdo_sqlite_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 721c46905fa8fb1e18d7196ed85c37f56049ea33 */ +/* This is a generated file, edit pdo_sqlite.stub.php instead. + * Stub hash: f6c7b3e1e92a47bb17aab32e654c716b295401c8 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Pdo_Sqlite_createAggregate, 0, 3, _IS_BOOL, 0) ZEND_ARG_TYPE_INFO(0, name, IS_STRING, 0) diff --git a/ext/pdo_sqlite/sqlite_driver_arginfo.h b/ext/pdo_sqlite/sqlite_driver_arginfo.h index 8785c187a97a9..ff82263ce4ba7 100644 --- a/ext/pdo_sqlite/sqlite_driver_arginfo.h +++ b/ext/pdo_sqlite/sqlite_driver_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: dc901bd60d17c1a2cdb40a118e2c6cd6eb0396e3 */ +/* This is a generated file, edit sqlite_driver.stub.php instead. + * Stub hash: 60cba77c6c10bdea8ddb570d0f1d994615feacaa */ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_PDO_SQLite_Ext_sqliteCreateFunction, 0, 2, _IS_BOOL, 0) ZEND_ARG_TYPE_INFO(0, name, IS_STRING, 0) diff --git a/ext/pgsql/pgsql_arginfo.h b/ext/pgsql/pgsql_arginfo.h index 2d9eec944356e..02a3762428da9 100644 --- a/ext/pgsql/pgsql_arginfo.h +++ b/ext/pgsql/pgsql_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 7c5c32d94c0ac05313d8b19915c6318b0678b75b */ +/* This is a generated file, edit pgsql.stub.php instead. + * Stub hash: 04770d14ad49eb3f80668c9570a12eb7e8e74ef7 */ ZEND_BEGIN_ARG_WITH_RETURN_OBJ_TYPE_MASK_EX(arginfo_pg_connect, 0, 1, PgSql\\Connection, MAY_BE_FALSE) ZEND_ARG_TYPE_INFO(0, connection_string, IS_STRING, 0) diff --git a/ext/phar/phar_object_arginfo.h b/ext/phar/phar_object_arginfo.h index c77876fc3647f..ff1139b6fc9a8 100644 --- a/ext/phar/phar_object_arginfo.h +++ b/ext/phar/phar_object_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 031dc8f07d2d9bac4a5f82f4ac2c5b3da5995405 */ +/* This is a generated file, edit phar_object.stub.php instead. + * Stub hash: baa38ddacf66b0909beec3e51dde98c0fcd7a783 */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar___construct, 0, 0, 1) ZEND_ARG_TYPE_INFO(0, filename, IS_STRING, 0) diff --git a/ext/posix/posix_arginfo.h b/ext/posix/posix_arginfo.h index dceac3eabc995..8c10d087fc25e 100644 --- a/ext/posix/posix_arginfo.h +++ b/ext/posix/posix_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 25e0aa769d72988ebca07fff96c8ed1fcb6b7d5e */ +/* This is a generated file, edit posix.stub.php instead. + * Stub hash: d6167cf921882c4b4bf247c205abb5985cab36bc */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_posix_kill, 0, 2, _IS_BOOL, 0) ZEND_ARG_TYPE_INFO(0, process_id, IS_LONG, 0) diff --git a/ext/random/random_arginfo.h b/ext/random/random_arginfo.h index 94c024b122369..786c45a3c13da 100644 --- a/ext/random/random_arginfo.h +++ b/ext/random/random_arginfo.h @@ -1,5 +1,6 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 416be19494555016195600e488d79f0dd35f2620 */ +/* This is a generated file, edit random.stub.php instead. + * Stub hash: 16b1be2da92880feb28676c64dcdac8b3d0689d1 + * Has decl header: yes */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_lcg_value, 0, 0, IS_DOUBLE, 0) ZEND_END_ARG_INFO() diff --git a/ext/random/random_decl.h b/ext/random/random_decl.h index 1bd1399b0cf8f..ced31b75a6ed5 100644 --- a/ext/random/random_decl.h +++ b/ext/random/random_decl.h @@ -1,7 +1,8 @@ -/* This is a generated file, edit the .stub.php file instead. */ +/* This is a generated file, edit random.stub.php instead. + * Stub hash: 16b1be2da92880feb28676c64dcdac8b3d0689d1 */ -#ifndef ZEND_RANDOM_DECL_416be19494555016195600e488d79f0dd35f2620_H -#define ZEND_RANDOM_DECL_416be19494555016195600e488d79f0dd35f2620_H +#ifndef ZEND_RANDOM_DECL_16b1be2da92880feb28676c64dcdac8b3d0689d1_H +#define ZEND_RANDOM_DECL_16b1be2da92880feb28676c64dcdac8b3d0689d1_H typedef enum zend_enum_Random_IntervalBoundary { ZEND_ENUM_Random_IntervalBoundary_ClosedOpen = 1, @@ -10,4 +11,4 @@ typedef enum zend_enum_Random_IntervalBoundary { ZEND_ENUM_Random_IntervalBoundary_OpenOpen = 4, } zend_enum_Random_IntervalBoundary; -#endif /* ZEND_RANDOM_DECL_416be19494555016195600e488d79f0dd35f2620_H */ +#endif /* ZEND_RANDOM_DECL_16b1be2da92880feb28676c64dcdac8b3d0689d1_H */ diff --git a/ext/readline/readline_arginfo.h b/ext/readline/readline_arginfo.h index c6fa7ee4590fc..091411442b2c1 100644 --- a/ext/readline/readline_arginfo.h +++ b/ext/readline/readline_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 7a314f75d9a89a9ea4d525515bb6bacdf7be6746 */ +/* This is a generated file, edit readline.stub.php instead. + * Stub hash: 6280d2829018200cec693d9781381b45152effe2 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_readline, 0, 0, MAY_BE_STRING|MAY_BE_FALSE) ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, prompt, IS_STRING, 1, "null") diff --git a/ext/reflection/php_reflection_arginfo.h b/ext/reflection/php_reflection_arginfo.h index 62275423b3caf..ba5ff5fbcf8da 100644 --- a/ext/reflection/php_reflection_arginfo.h +++ b/ext/reflection/php_reflection_arginfo.h @@ -1,5 +1,6 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: fd645a0b0db39d94ca25b39ffe64d7f05bad6bea */ +/* This is a generated file, edit php_reflection.stub.php instead. + * Stub hash: fd6682893f78c53fe56f0ad65fc6ec3938ea3701 + * Has decl header: yes */ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_Reflection_getModifierNames, 0, 1, IS_ARRAY, 0) ZEND_ARG_TYPE_INFO(0, modifiers, IS_LONG, 0) diff --git a/ext/reflection/php_reflection_decl.h b/ext/reflection/php_reflection_decl.h index 39dc8672d1bcc..32dd56c0da2e6 100644 --- a/ext/reflection/php_reflection_decl.h +++ b/ext/reflection/php_reflection_decl.h @@ -1,11 +1,12 @@ -/* This is a generated file, edit the .stub.php file instead. */ +/* This is a generated file, edit php_reflection.stub.php instead. + * Stub hash: fd6682893f78c53fe56f0ad65fc6ec3938ea3701 */ -#ifndef ZEND_PHP_REFLECTION_DECL_fd645a0b0db39d94ca25b39ffe64d7f05bad6bea_H -#define ZEND_PHP_REFLECTION_DECL_fd645a0b0db39d94ca25b39ffe64d7f05bad6bea_H +#ifndef ZEND_PHP_REFLECTION_DECL_fd6682893f78c53fe56f0ad65fc6ec3938ea3701_H +#define ZEND_PHP_REFLECTION_DECL_fd6682893f78c53fe56f0ad65fc6ec3938ea3701_H typedef enum zend_enum_PropertyHookType { ZEND_ENUM_PropertyHookType_Get = 1, ZEND_ENUM_PropertyHookType_Set = 2, } zend_enum_PropertyHookType; -#endif /* ZEND_PHP_REFLECTION_DECL_fd645a0b0db39d94ca25b39ffe64d7f05bad6bea_H */ +#endif /* ZEND_PHP_REFLECTION_DECL_fd6682893f78c53fe56f0ad65fc6ec3938ea3701_H */ diff --git a/ext/session/session_arginfo.h b/ext/session/session_arginfo.h index 3e0c889ae3c55..c144f0c6acd76 100644 --- a/ext/session/session_arginfo.h +++ b/ext/session/session_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 6bbbdc8c4a33d1ff9984b3d81e4f5c9b76efcb14 */ +/* This is a generated file, edit session.stub.php instead. + * Stub hash: 41a56bbf60502c9b0c389397337bc6bb49a4f07c */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_session_name, 0, 0, MAY_BE_STRING|MAY_BE_FALSE) ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, name, IS_STRING, 1, "null") diff --git a/ext/shmop/shmop_arginfo.h b/ext/shmop/shmop_arginfo.h index f376b8556d930..6c2362cb64a61 100644 --- a/ext/shmop/shmop_arginfo.h +++ b/ext/shmop/shmop_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: e7f250077b6721539caee96afe4ed392396018f9 */ +/* This is a generated file, edit shmop.stub.php instead. + * Stub hash: e194b229d5428d2bb10d98036044b212de613778 */ ZEND_BEGIN_ARG_WITH_RETURN_OBJ_TYPE_MASK_EX(arginfo_shmop_open, 0, 4, Shmop, MAY_BE_FALSE) ZEND_ARG_TYPE_INFO(0, key, IS_LONG, 0) diff --git a/ext/simplexml/simplexml_arginfo.h b/ext/simplexml/simplexml_arginfo.h index 90831f54c46e9..98182d63c8a5c 100644 --- a/ext/simplexml/simplexml_arginfo.h +++ b/ext/simplexml/simplexml_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: cee51320f0f09f14962fb72125ef8ff6073a642a */ +/* This is a generated file, edit simplexml.stub.php instead. + * Stub hash: 0657c2bc1e029f474dea92f9ad293874bc9d7897 */ ZEND_BEGIN_ARG_WITH_RETURN_OBJ_TYPE_MASK_EX(arginfo_simplexml_load_file, 0, 1, SimpleXMLElement, MAY_BE_FALSE) ZEND_ARG_TYPE_INFO(0, filename, IS_STRING, 0) diff --git a/ext/skeleton/skeleton_arginfo.h b/ext/skeleton/skeleton_arginfo.h index 50b6b7793ef5b..91859357a7154 100644 --- a/ext/skeleton/skeleton_arginfo.h +++ b/ext/skeleton/skeleton_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 54b0ffc3af871b189435266df516f7575c1b9675 */ +/* This is a generated file, edit skeleton.stub.php instead. + * Stub hash: 079118e7ab5e6309ff80f502efd463007f1767dd */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_test1, 0, 0, IS_VOID, 0) ZEND_END_ARG_INFO() diff --git a/ext/snmp/snmp_arginfo.h b/ext/snmp/snmp_arginfo.h index dd0fdee92969d..c761bcb5dd8e6 100644 --- a/ext/snmp/snmp_arginfo.h +++ b/ext/snmp/snmp_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: e2451ac3ea0fa5eb1158e8b7252e61c6794d514f */ +/* This is a generated file, edit snmp.stub.php instead. + * Stub hash: e3c6dd6813cac2b0cc45162082043ff7c2aced93 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_snmpget, 0, 3, IS_MIXED, 0) ZEND_ARG_TYPE_INFO(0, hostname, IS_STRING, 0) diff --git a/ext/soap/soap_arginfo.h b/ext/soap/soap_arginfo.h index 7efa15cde2f9d..af31190079f4a 100644 --- a/ext/soap/soap_arginfo.h +++ b/ext/soap/soap_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 24e266bf0933d5622f2a341db5b694ecb1740f13 */ +/* This is a generated file, edit soap.stub.php instead. + * Stub hash: 930749f784ddffa81320728b739757a531405d52 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_use_soap_error_handler, 0, 0, _IS_BOOL, 0) ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, enable, _IS_BOOL, 0, "true") diff --git a/ext/sockets/sockets_arginfo.h b/ext/sockets/sockets_arginfo.h index 0145d01252881..4ceeb6b735909 100644 --- a/ext/sockets/sockets_arginfo.h +++ b/ext/sockets/sockets_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 038081ca7bb98076d4b559d93b4c9300acc47160 */ +/* This is a generated file, edit sockets.stub.php instead. + * Stub hash: 15d1f2639d6a6aa7cad79e2090e60754eb8260c0 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_socket_select, 0, 4, MAY_BE_LONG|MAY_BE_FALSE) ZEND_ARG_TYPE_INFO(1, read, IS_ARRAY, 1) diff --git a/ext/sodium/libsodium_arginfo.h b/ext/sodium/libsodium_arginfo.h index 5fbd831c22e4a..20213c5b0790c 100644 --- a/ext/sodium/libsodium_arginfo.h +++ b/ext/sodium/libsodium_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 89cbb449ee6146dc8d50ba4bb1e76f83444a2db2 */ +/* This is a generated file, edit libsodium.stub.php instead. + * Stub hash: 30223b0bdb1f6e75385c044563421a8c5312c92f */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_sodium_crypto_aead_aes256gcm_is_available, 0, 0, _IS_BOOL, 0) ZEND_END_ARG_INFO() diff --git a/ext/sodium/sodium_pwhash_arginfo.h b/ext/sodium/sodium_pwhash_arginfo.h index d559a74fbc1fe..fe10469afbf9c 100644 --- a/ext/sodium/sodium_pwhash_arginfo.h +++ b/ext/sodium/sodium_pwhash_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: d1e804ceea5e18fc5a4eca50b318d98387b2a470 */ +/* This is a generated file, edit sodium_pwhash.stub.php instead. + * Stub hash: 35abfc291b33af598776f607758424654eb0d966 */ static void register_sodium_pwhash_symbols(int module_number) { diff --git a/ext/spl/php_spl_arginfo.h b/ext/spl/php_spl_arginfo.h index 68c71fc524bc5..1afeb49a0f05c 100644 --- a/ext/spl/php_spl_arginfo.h +++ b/ext/spl/php_spl_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 21ec2dcca99c85c90afcd319da76016a9f678dc2 */ +/* This is a generated file, edit php_spl.stub.php instead. + * Stub hash: a3f2124adb9ec0af0d9fd44c65571a57e469aae9 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_class_implements, 0, 1, MAY_BE_ARRAY|MAY_BE_FALSE) ZEND_ARG_INFO(0, object_or_class) diff --git a/ext/spl/spl_array_arginfo.h b/ext/spl/spl_array_arginfo.h index da3b7ddb8c909..1c03e883afe5e 100644 --- a/ext/spl/spl_array_arginfo.h +++ b/ext/spl/spl_array_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: c52e89992bd3c04877daab47f4328af0b6ce619e */ +/* This is a generated file, edit spl_array.stub.php instead. + * Stub hash: f5a3e2481c6b030899e9d4470c0b1506b137f18f */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_ArrayObject___construct, 0, 0, 0) ZEND_ARG_TYPE_MASK(0, array, MAY_BE_ARRAY|MAY_BE_OBJECT, "[]") diff --git a/ext/spl/spl_directory_arginfo.h b/ext/spl/spl_directory_arginfo.h index 3b37c1ed6fd0e..a80c2272ce03d 100644 --- a/ext/spl/spl_directory_arginfo.h +++ b/ext/spl/spl_directory_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 802429d736404c2d66601f640942c827b6e6e94b */ +/* This is a generated file, edit spl_directory.stub.php instead. + * Stub hash: 45620a8bddf642a1edad58dc07a8a369eb4b9d1c */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_SplFileInfo___construct, 0, 0, 1) ZEND_ARG_TYPE_INFO(0, filename, IS_STRING, 0) diff --git a/ext/spl/spl_dllist_arginfo.h b/ext/spl/spl_dllist_arginfo.h index e6ceb3dca42de..26ef917dc8b91 100644 --- a/ext/spl/spl_dllist_arginfo.h +++ b/ext/spl/spl_dllist_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 45e42d3a0589031651daee5653900d5a4fb61c3d */ +/* This is a generated file, edit spl_dllist.stub.php instead. + * Stub hash: d2718f331b5b8cfbb43d1225ee9e5acf4cd78764 */ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_SplDoublyLinkedList_add, 0, 2, IS_VOID, 0) ZEND_ARG_TYPE_INFO(0, index, IS_LONG, 0) diff --git a/ext/spl/spl_exceptions_arginfo.h b/ext/spl/spl_exceptions_arginfo.h index 568a91719aee8..d2a7719643bc9 100644 --- a/ext/spl/spl_exceptions_arginfo.h +++ b/ext/spl/spl_exceptions_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 07475caecc81ab3b38a04905f874615af1126289 */ +/* This is a generated file, edit spl_exceptions.stub.php instead. + * Stub hash: 84accf1abb00ca3defe047c0c4f6b1dcb49a2ecc */ static zend_class_entry *register_class_LogicException(zend_class_entry *class_entry_Exception) { diff --git a/ext/spl/spl_fixedarray_arginfo.h b/ext/spl/spl_fixedarray_arginfo.h index d3d84deabe6ec..06d392e712735 100644 --- a/ext/spl/spl_fixedarray_arginfo.h +++ b/ext/spl/spl_fixedarray_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 0c838fed60b29671fe04e63315ab662d8cb16f0c */ +/* This is a generated file, edit spl_fixedarray.stub.php instead. + * Stub hash: 91e864abe5e89907bdecd99151ea251b7a798b4e */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_SplFixedArray___construct, 0, 0, 0) ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, size, IS_LONG, 0, "0") diff --git a/ext/spl/spl_heap_arginfo.h b/ext/spl/spl_heap_arginfo.h index 8b79ee0902ddf..938bc345e223e 100644 --- a/ext/spl/spl_heap_arginfo.h +++ b/ext/spl/spl_heap_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 3256398ed9e798f141fd3cb73370c0d8b2dbd0f1 */ +/* This is a generated file, edit spl_heap.stub.php instead. + * Stub hash: dd75b60711423e8e25fedd16df97843cd03587f9 */ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_SplPriorityQueue_compare, 0, 2, IS_LONG, 0) ZEND_ARG_TYPE_INFO(0, priority1, IS_MIXED, 0) diff --git a/ext/spl/spl_iterators_arginfo.h b/ext/spl/spl_iterators_arginfo.h index ebd57693632d9..5304ee70100d5 100644 --- a/ext/spl/spl_iterators_arginfo.h +++ b/ext/spl/spl_iterators_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: ab66d2fff7ac7556d4244582a2bd3e83a3f95243 */ +/* This is a generated file, edit spl_iterators.stub.php instead. + * Stub hash: b25d0f3b99fc0fd830ba73b9ff02134124a9d355 */ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_EmptyIterator_current, 0, 0, IS_NEVER, 0) ZEND_END_ARG_INFO() diff --git a/ext/spl/spl_observer_arginfo.h b/ext/spl/spl_observer_arginfo.h index fec3ccb84203d..9d8c3ce085727 100644 --- a/ext/spl/spl_observer_arginfo.h +++ b/ext/spl/spl_observer_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 9dfd8bcf8946cbee550c9a46da07c424c3505408 */ +/* This is a generated file, edit spl_observer.stub.php instead. + * Stub hash: 45f13c7f322fccd4c82069545fa4408052a65c30 */ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_SplObserver_update, 0, 1, IS_VOID, 0) ZEND_ARG_OBJ_INFO(0, subject, SplSubject, 0) diff --git a/ext/sqlite3/sqlite3_arginfo.h b/ext/sqlite3/sqlite3_arginfo.h index 12c1c7d0ce961..6ca3ebe08c973 100644 --- a/ext/sqlite3/sqlite3_arginfo.h +++ b/ext/sqlite3/sqlite3_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: da91c32c6070c808d6e1b01894b5f8beedda7b45 */ +/* This is a generated file, edit sqlite3.stub.php instead. + * Stub hash: b282588220ae3a33706642253851bce6a6af9e4b */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_SQLite3___construct, 0, 0, 1) ZEND_ARG_TYPE_INFO(0, filename, IS_STRING, 0) diff --git a/ext/standard/basic_functions_arginfo.h b/ext/standard/basic_functions_arginfo.h index 6f202c01463fd..0fafc05f427eb 100644 --- a/ext/standard/basic_functions_arginfo.h +++ b/ext/standard/basic_functions_arginfo.h @@ -1,5 +1,6 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 1a1667a5c59111f096a758d5bb4aa7cf3ec09cfe */ +/* This is a generated file, edit basic_functions.stub.php instead. + * Stub hash: ac29e3514319062fade35cb8064c6cb59c672dd7 + * Has decl header: yes */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_set_time_limit, 0, 1, _IS_BOOL, 0) ZEND_ARG_TYPE_INFO(0, seconds, IS_LONG, 0) diff --git a/ext/standard/basic_functions_decl.h b/ext/standard/basic_functions_decl.h index 02c654c5d084b..1a1b3bb0c462a 100644 --- a/ext/standard/basic_functions_decl.h +++ b/ext/standard/basic_functions_decl.h @@ -1,7 +1,8 @@ -/* This is a generated file, edit the .stub.php file instead. */ +/* This is a generated file, edit basic_functions.stub.php instead. + * Stub hash: ac29e3514319062fade35cb8064c6cb59c672dd7 */ -#ifndef ZEND_BASIC_FUNCTIONS_DECL_1a1667a5c59111f096a758d5bb4aa7cf3ec09cfe_H -#define ZEND_BASIC_FUNCTIONS_DECL_1a1667a5c59111f096a758d5bb4aa7cf3ec09cfe_H +#ifndef ZEND_BASIC_FUNCTIONS_DECL_ac29e3514319062fade35cb8064c6cb59c672dd7_H +#define ZEND_BASIC_FUNCTIONS_DECL_ac29e3514319062fade35cb8064c6cb59c672dd7_H typedef enum zend_enum_RoundingMode { ZEND_ENUM_RoundingMode_HalfAwayFromZero = 1, @@ -14,4 +15,4 @@ typedef enum zend_enum_RoundingMode { ZEND_ENUM_RoundingMode_PositiveInfinity = 8, } zend_enum_RoundingMode; -#endif /* ZEND_BASIC_FUNCTIONS_DECL_1a1667a5c59111f096a758d5bb4aa7cf3ec09cfe_H */ +#endif /* ZEND_BASIC_FUNCTIONS_DECL_ac29e3514319062fade35cb8064c6cb59c672dd7_H */ diff --git a/ext/standard/dir_arginfo.h b/ext/standard/dir_arginfo.h index d4cfc19556353..626d7f68deea7 100644 --- a/ext/standard/dir_arginfo.h +++ b/ext/standard/dir_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: e21d382cd4001001874c49d8c5244efb57613910 */ +/* This is a generated file, edit dir.stub.php instead. + * Stub hash: 1b6f6f72ebf17ffabd6c362d901889478c44ec51 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Directory_close, 0, 0, IS_VOID, 0) ZEND_END_ARG_INFO() diff --git a/ext/standard/dl_arginfo.h b/ext/standard/dl_arginfo.h index 5a0780d28c1c6..d02d8c9230acc 100644 --- a/ext/standard/dl_arginfo.h +++ b/ext/standard/dl_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 7dac6edd98e3e17669ae4bf0be7db89678059ca0 */ +/* This is a generated file, edit dl.stub.php instead. + * Stub hash: c9cdb2dc5a3462ce9e8dcb6b67dbcdddaf8baa1b */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_dl, 0, 1, _IS_BOOL, 0) ZEND_ARG_TYPE_INFO(0, extension_filename, IS_STRING, 0) diff --git a/ext/standard/file_arginfo.h b/ext/standard/file_arginfo.h index 073e7951ad8c3..26bfc4ba77c84 100644 --- a/ext/standard/file_arginfo.h +++ b/ext/standard/file_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: c394e14cd32587ce9ad0503e21c6c4cf5b301697 */ +/* This is a generated file, edit file.stub.php instead. + * Stub hash: 57ea2343067a522acb01f25213283ec751569a73 */ static void register_file_symbols(int module_number) { diff --git a/ext/standard/password_arginfo.h b/ext/standard/password_arginfo.h index ec4876fe2a3cc..2341896ae584b 100644 --- a/ext/standard/password_arginfo.h +++ b/ext/standard/password_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: f61df8d477588718e0eb1b055e5a3e138e6bcad3 */ +/* This is a generated file, edit password.stub.php instead. + * Stub hash: d883ab7827df97208caf9c85a963b03228879c92 */ static void register_password_symbols(int module_number) { diff --git a/ext/standard/user_filters_arginfo.h b/ext/standard/user_filters_arginfo.h index 9fd13204e2322..0871ae3a75044 100644 --- a/ext/standard/user_filters_arginfo.h +++ b/ext/standard/user_filters_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 33264435fe01a2cc9aa21a4a087dbbf3c4007206 */ +/* This is a generated file, edit user_filters.stub.php instead. + * Stub hash: 8076533eb436ec69db21de8805927db337f70884 */ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_php_user_filter_filter, 0, 4, IS_LONG, 0) ZEND_ARG_INFO(0, in) diff --git a/ext/sysvmsg/sysvmsg_arginfo.h b/ext/sysvmsg/sysvmsg_arginfo.h index 26f81c0295be0..b02a60bef7ee1 100644 --- a/ext/sysvmsg/sysvmsg_arginfo.h +++ b/ext/sysvmsg/sysvmsg_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: ed5b1e4e5dda6a65ce336fc4daa975520c354f17 */ +/* This is a generated file, edit sysvmsg.stub.php instead. + * Stub hash: bc88e01b98e234fba2175b9b2709a6460fb93daf */ ZEND_BEGIN_ARG_WITH_RETURN_OBJ_TYPE_MASK_EX(arginfo_msg_get_queue, 0, 1, SysvMessageQueue, MAY_BE_FALSE) ZEND_ARG_TYPE_INFO(0, key, IS_LONG, 0) diff --git a/ext/sysvsem/sysvsem_arginfo.h b/ext/sysvsem/sysvsem_arginfo.h index 55bca0539fdde..11bccbe485823 100644 --- a/ext/sysvsem/sysvsem_arginfo.h +++ b/ext/sysvsem/sysvsem_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 946ea9d0d2156ced1bac460d7d5fc3420e1934bb */ +/* This is a generated file, edit sysvsem.stub.php instead. + * Stub hash: b735084b8a699b38aa9e1281e5a77a6203cd10e0 */ ZEND_BEGIN_ARG_WITH_RETURN_OBJ_TYPE_MASK_EX(arginfo_sem_get, 0, 1, SysvSemaphore, MAY_BE_FALSE) ZEND_ARG_TYPE_INFO(0, key, IS_LONG, 0) diff --git a/ext/sysvshm/sysvshm_arginfo.h b/ext/sysvshm/sysvshm_arginfo.h index c3b803c37aea6..fa9a6ba42d5ae 100644 --- a/ext/sysvshm/sysvshm_arginfo.h +++ b/ext/sysvshm/sysvshm_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 792c695a705678a3779d62cef8a5136069f98dee */ +/* This is a generated file, edit sysvshm.stub.php instead. + * Stub hash: f9cfe5ad168e7a425d088a6c43f702ad2c8f8d39 */ ZEND_BEGIN_ARG_WITH_RETURN_OBJ_TYPE_MASK_EX(arginfo_shm_attach, 0, 1, SysvSharedMemory, MAY_BE_FALSE) ZEND_ARG_TYPE_INFO(0, key, IS_LONG, 0) diff --git a/ext/tidy/tidy_arginfo.h b/ext/tidy/tidy_arginfo.h index 2448b3bca2940..76eaf45a8df0d 100644 --- a/ext/tidy/tidy_arginfo.h +++ b/ext/tidy/tidy_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 0e6561410a63658f76011c1ddcecdd1e68757f0a */ +/* This is a generated file, edit tidy.stub.php instead. + * Stub hash: f48fb5549e50b4e7660fc432d42a5cc1ba13f43f */ ZEND_BEGIN_ARG_WITH_RETURN_OBJ_TYPE_MASK_EX(arginfo_tidy_parse_string, 0, 1, tidy, MAY_BE_FALSE) ZEND_ARG_TYPE_INFO(0, string, IS_STRING, 0) diff --git a/ext/tokenizer/tokenizer_arginfo.h b/ext/tokenizer/tokenizer_arginfo.h index f5040b70cf280..ca47f01deda1e 100644 --- a/ext/tokenizer/tokenizer_arginfo.h +++ b/ext/tokenizer/tokenizer_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: a89f03303f8a7d254509ae2bc46a36bb79a3c900 */ +/* This is a generated file, edit tokenizer.stub.php instead. + * Stub hash: fb1463e1d6067621efde2f0bc44708b60b7a82a6 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_token_get_all, 0, 1, IS_ARRAY, 0) ZEND_ARG_TYPE_INFO(0, code, IS_STRING, 0) diff --git a/ext/tokenizer/tokenizer_data_arginfo.h b/ext/tokenizer/tokenizer_data_arginfo.h index 3a3cdaa468133..2ba74f5a89230 100644 --- a/ext/tokenizer/tokenizer_data_arginfo.h +++ b/ext/tokenizer/tokenizer_data_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: c5235344b7c651d27c2c33c90696a418a9c96837 */ +/* This is a generated file, edit tokenizer_data.stub.php instead. + * Stub hash: 2b0986ae40ccb45e392b6d9c6d35eb34b25abef4 */ static void register_tokenizer_data_symbols(int module_number) { diff --git a/ext/uri/php_uri_arginfo.h b/ext/uri/php_uri_arginfo.h index d3a9c4fde7bca..47951e130b73d 100644 --- a/ext/uri/php_uri_arginfo.h +++ b/ext/uri/php_uri_arginfo.h @@ -1,5 +1,6 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: f3c524798d1933a400cc9377cfbfdcbaf77b87f0 */ +/* This is a generated file, edit php_uri.stub.php instead. + * Stub hash: 06559ef117bcd8c91c6fdeb35a5bc85227c1196a + * Has decl header: yes */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Uri_Rfc3986_Uri_parse, 0, 1, IS_STATIC, 1) ZEND_ARG_TYPE_INFO(0, uri, IS_STRING, 0) diff --git a/ext/uri/php_uri_decl.h b/ext/uri/php_uri_decl.h index 91305fab20fb7..8daa04e999528 100644 --- a/ext/uri/php_uri_decl.h +++ b/ext/uri/php_uri_decl.h @@ -1,7 +1,8 @@ -/* This is a generated file, edit the .stub.php file instead. */ +/* This is a generated file, edit php_uri.stub.php instead. + * Stub hash: 06559ef117bcd8c91c6fdeb35a5bc85227c1196a */ -#ifndef ZEND_PHP_URI_DECL_f3c524798d1933a400cc9377cfbfdcbaf77b87f0_H -#define ZEND_PHP_URI_DECL_f3c524798d1933a400cc9377cfbfdcbaf77b87f0_H +#ifndef ZEND_PHP_URI_DECL_06559ef117bcd8c91c6fdeb35a5bc85227c1196a_H +#define ZEND_PHP_URI_DECL_06559ef117bcd8c91c6fdeb35a5bc85227c1196a_H typedef enum zend_enum_Uri_UriComparisonMode { ZEND_ENUM_Uri_UriComparisonMode_IncludeFragment = 1, @@ -40,4 +41,4 @@ typedef enum zend_enum_Uri_WhatWg_UrlValidationErrorType { ZEND_ENUM_Uri_WhatWg_UrlValidationErrorType_FileInvalidWindowsDriveLetterHost = 29, } zend_enum_Uri_WhatWg_UrlValidationErrorType; -#endif /* ZEND_PHP_URI_DECL_f3c524798d1933a400cc9377cfbfdcbaf77b87f0_H */ +#endif /* ZEND_PHP_URI_DECL_06559ef117bcd8c91c6fdeb35a5bc85227c1196a_H */ diff --git a/ext/xml/xml_arginfo.h b/ext/xml/xml_arginfo.h index 784424e7fd3ae..6eb0c6c896f71 100644 --- a/ext/xml/xml_arginfo.h +++ b/ext/xml/xml_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: c7838fb209d601be280dfdebfd135906afa36e8c */ +/* This is a generated file, edit xml.stub.php instead. + * Stub hash: 6355e164658330e2f4b26ac10001ae7306ab1516 */ ZEND_BEGIN_ARG_WITH_RETURN_OBJ_INFO_EX(arginfo_xml_parser_create, 0, 0, XMLParser, 0) ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, encoding, IS_STRING, 1, "null") diff --git a/ext/xmlreader/php_xmlreader_arginfo.h b/ext/xmlreader/php_xmlreader_arginfo.h index ef54bfa4c235f..60f1b31afc899 100644 --- a/ext/xmlreader/php_xmlreader_arginfo.h +++ b/ext/xmlreader/php_xmlreader_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 80288a0f40eabc7802a928963386616ea31e448d */ +/* This is a generated file, edit php_xmlreader.stub.php instead. + * Stub hash: cd6f704bc5ef76588831982149d86bc71e1ef53a */ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_XMLReader_close, 0, 0, IS_TRUE, 0) ZEND_END_ARG_INFO() diff --git a/ext/xmlwriter/php_xmlwriter_arginfo.h b/ext/xmlwriter/php_xmlwriter_arginfo.h index ebccf4225ba9f..5e671547b823a 100644 --- a/ext/xmlwriter/php_xmlwriter_arginfo.h +++ b/ext/xmlwriter/php_xmlwriter_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: fcc388de55bd6d21530d16f6a9ab5f0eb307c1ff */ +/* This is a generated file, edit php_xmlwriter.stub.php instead. + * Stub hash: 48e5317dfa3f627ae5b315335b5e73d56e329361 */ ZEND_BEGIN_ARG_WITH_RETURN_OBJ_TYPE_MASK_EX(arginfo_xmlwriter_open_uri, 0, 1, XMLWriter, MAY_BE_FALSE) ZEND_ARG_TYPE_INFO(0, uri, IS_STRING, 0) diff --git a/ext/xsl/php_xsl_arginfo.h b/ext/xsl/php_xsl_arginfo.h index b1f4fd7601c58..1d82627bfca7c 100644 --- a/ext/xsl/php_xsl_arginfo.h +++ b/ext/xsl/php_xsl_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: cb1005b601e72e8d36d0f6aa5d08872f5c7ea2e6 */ +/* This is a generated file, edit php_xsl.stub.php instead. + * Stub hash: 604f63573d5093a1b6fbeb18329e28a5bd2779da */ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_XSLTProcessor_importStylesheet, 0, 1, _IS_BOOL, 0) ZEND_ARG_TYPE_INFO(0, stylesheet, IS_OBJECT, 0) diff --git a/ext/zend_test/fiber_arginfo.h b/ext/zend_test/fiber_arginfo.h index e4a0b51bebc9d..630c2a0d82d6a 100644 --- a/ext/zend_test/fiber_arginfo.h +++ b/ext/zend_test/fiber_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 8cd7626122b050585503ccebe370a61781ff83f2 */ +/* This is a generated file, edit fiber.stub.php instead. + * Stub hash: 28dc430591e02cec512e2da417d36aa9456fe415 */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class__ZendTestFiber___construct, 0, 0, 1) ZEND_ARG_TYPE_INFO(0, callback, IS_CALLABLE, 0) diff --git a/ext/zend_test/iterators_arginfo.h b/ext/zend_test/iterators_arginfo.h index 3ec78808eaa19..d7f8644241ba9 100644 --- a/ext/zend_test/iterators_arginfo.h +++ b/ext/zend_test/iterators_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: f9558686a7393ddd4ba3302e811f70d4496317ee */ +/* This is a generated file, edit iterators.stub.php instead. + * Stub hash: edbd3689c6c51a2bea81c39087d62f3d72494755 */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_ZendTest_Iterators_TraversableTest___construct, 0, 0, 0) ZEND_END_ARG_INFO() diff --git a/ext/zend_test/object_handlers_arginfo.h b/ext/zend_test/object_handlers_arginfo.h index 0b8cff520c153..65ffb23a9361f 100644 --- a/ext/zend_test/object_handlers_arginfo.h +++ b/ext/zend_test/object_handlers_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 81be60f2c465ffe5c036739d072ab80d9c388907 */ +/* This is a generated file, edit object_handlers.stub.php instead. + * Stub hash: 8d882ddca17f778f41eca9945fb26da6db1a5105 */ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_DoOperationNoCast___construct, 0, 0, 1) ZEND_ARG_TYPE_INFO(0, val, IS_LONG, 0) diff --git a/ext/zend_test/test_arginfo.h b/ext/zend_test/test_arginfo.h index 681dca973b3fb..fba45aa6e1998 100644 --- a/ext/zend_test/test_arginfo.h +++ b/ext/zend_test/test_arginfo.h @@ -1,5 +1,6 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 25b63d5be5822cf0b717150dde07625cdd503c24 */ +/* This is a generated file, edit test.stub.php instead. + * Stub hash: 176a65a1f8990e8f5b4791baaab6b0c18effa272 + * Has decl header: yes */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_zend_trigger_bailout, 0, 0, IS_NEVER, 0) ZEND_END_ARG_INFO() diff --git a/ext/zend_test/test_decl.h b/ext/zend_test/test_decl.h index 875f3a2b452c1..a589715071d3c 100644 --- a/ext/zend_test/test_decl.h +++ b/ext/zend_test/test_decl.h @@ -1,7 +1,8 @@ -/* This is a generated file, edit the .stub.php file instead. */ +/* This is a generated file, edit test.stub.php instead. + * Stub hash: 176a65a1f8990e8f5b4791baaab6b0c18effa272 */ -#ifndef ZEND_TEST_DECL_25b63d5be5822cf0b717150dde07625cdd503c24_H -#define ZEND_TEST_DECL_25b63d5be5822cf0b717150dde07625cdd503c24_H +#ifndef ZEND_TEST_DECL_176a65a1f8990e8f5b4791baaab6b0c18effa272_H +#define ZEND_TEST_DECL_176a65a1f8990e8f5b4791baaab6b0c18effa272_H typedef enum zend_enum_ZendTestUnitEnum { ZEND_ENUM_ZendTestUnitEnum_Foo = 1, @@ -26,4 +27,4 @@ typedef enum zend_enum_ZendTestEnumWithInterface { ZEND_ENUM_ZendTestEnumWithInterface_Bar = 2, } zend_enum_ZendTestEnumWithInterface; -#endif /* ZEND_TEST_DECL_25b63d5be5822cf0b717150dde07625cdd503c24_H */ +#endif /* ZEND_TEST_DECL_176a65a1f8990e8f5b4791baaab6b0c18effa272_H */ diff --git a/ext/zend_test/tmp_methods_arginfo.h b/ext/zend_test/tmp_methods_arginfo.h index 92598a34ad8d6..ad94fa8eba7cd 100644 --- a/ext/zend_test/tmp_methods_arginfo.h +++ b/ext/zend_test/tmp_methods_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 7fd99c0b5a1957cb3a8c08a74421a720475bb46d */ +/* This is a generated file, edit tmp_methods.stub.php instead. + * Stub hash: 3061a681df156a72687b67b7625081d4394d31e0 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_ZendTestTmpMethods_testTmpMethodWithArgInfo, 0, 0, IS_VOID, 0) ZEND_ARG_OBJ_TYPE_MASK(0, tmpMethodParamName, Foo|Bar, MAY_BE_NULL, "null") diff --git a/ext/zip/php_zip_arginfo.h b/ext/zip/php_zip_arginfo.h index ba4f867e8af73..4f0d1470da3f1 100644 --- a/ext/zip/php_zip_arginfo.h +++ b/ext/zip/php_zip_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 1f77735273373672b9c8c5b92c46e23ea99faeaf */ +/* This is a generated file, edit php_zip.stub.php instead. + * Stub hash: f383aa073aa43ad5008b2ba66bb3f2b465ccf707 */ ZEND_BEGIN_ARG_INFO_EX(arginfo_zip_open, 0, 0, 1) ZEND_ARG_TYPE_INFO(0, filename, IS_STRING, 0) diff --git a/ext/zlib/zlib_arginfo.h b/ext/zlib/zlib_arginfo.h index 81d779c1b7d17..34c9bcf6300e6 100644 --- a/ext/zlib/zlib_arginfo.h +++ b/ext/zlib/zlib_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 4c5bea6d9f290c244c7bb27c77fe8007d43a40db */ +/* This is a generated file, edit zlib.stub.php instead. + * Stub hash: dec299dca8f3a94a42bca0964c318ee4ae3d8e38 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_ob_gzhandler, 0, 2, MAY_BE_STRING|MAY_BE_FALSE) ZEND_ARG_TYPE_INFO(0, data, IS_STRING, 0) diff --git a/main/main_arginfo.h b/main/main_arginfo.h index 3aa0b07e42c87..56f6a69b165a4 100644 --- a/main/main_arginfo.h +++ b/main/main_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: e8b81aa6f03d36f35def2bb1fcc3563b284a113b */ +/* This is a generated file, edit main.stub.php instead. + * Stub hash: bd5dbf3768832331886310e00e8facaa44331699 */ static void register_main_symbols(int module_number) { diff --git a/main/streams/userspace_arginfo.h b/main/streams/userspace_arginfo.h index 773472a24136b..c470a23d77fa4 100644 --- a/main/streams/userspace_arginfo.h +++ b/main/streams/userspace_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 9198095c858c95fcb31252ddfa24fe04787d0460 */ +/* This is a generated file, edit userspace.stub.php instead. + * Stub hash: 921c2b9c34ba5bd905b6a87a2e53aa153db950ad */ static void register_userspace_symbols(int module_number) { diff --git a/sapi/apache2handler/php_functions_arginfo.h b/sapi/apache2handler/php_functions_arginfo.h index c5657e9429cab..87bced9d241b1 100644 --- a/sapi/apache2handler/php_functions_arginfo.h +++ b/sapi/apache2handler/php_functions_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 130666f6f971fe7b43a450d922e4b3d092e78667 */ +/* This is a generated file, edit php_functions.stub.php instead. + * Stub hash: a46b124d0311f80b6e7067a3f2bfae1c93273e13 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_apache_lookup_uri, 0, 1, MAY_BE_OBJECT|MAY_BE_FALSE) ZEND_ARG_TYPE_INFO(0, filename, IS_STRING, 0) diff --git a/sapi/cgi/cgi_main_arginfo.h b/sapi/cgi/cgi_main_arginfo.h index 19ef6f01ad5ce..9a5083aba8bd0 100644 --- a/sapi/cgi/cgi_main_arginfo.h +++ b/sapi/cgi/cgi_main_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: df963adc6bc610cdd31861036889141fa9464ded */ +/* This is a generated file, edit cgi_main.stub.php instead. + * Stub hash: d12211af01f723fc4ee7b24fd6d43205521cbf66 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_apache_child_terminate, 0, 0, IS_VOID, 0) ZEND_END_ARG_INFO() diff --git a/sapi/cli/php_cli_process_title_arginfo.h b/sapi/cli/php_cli_process_title_arginfo.h index c4557f0c90464..0d7ef7f9a79b2 100644 --- a/sapi/cli/php_cli_process_title_arginfo.h +++ b/sapi/cli/php_cli_process_title_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: ee776e0c54fe4b66a98b3a0203af11c5f3082e38 */ +/* This is a generated file, edit php_cli_process_title.stub.php instead. + * Stub hash: c0943af234bc70b9c9728cd54e63d8009c41be51 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_cli_set_process_title, 0, 1, _IS_BOOL, 0) ZEND_ARG_TYPE_INFO(0, title, IS_STRING, 0) diff --git a/sapi/cli/php_cli_server_arginfo.h b/sapi/cli/php_cli_server_arginfo.h index dd4d67bd27378..fc1ea440c54ec 100644 --- a/sapi/cli/php_cli_server_arginfo.h +++ b/sapi/cli/php_cli_server_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 60cd531d36a34fe7c51982e9ec40b45d2a2a4ce7 */ +/* This is a generated file, edit php_cli_server.stub.php instead. + * Stub hash: 9f5c4968f928c37194ba00f8bf93d56a0f0fe16c */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_apache_request_headers, 0, 0, IS_ARRAY, 0) ZEND_END_ARG_INFO() diff --git a/sapi/fpm/fpm/fpm_main_arginfo.h b/sapi/fpm/fpm/fpm_main_arginfo.h index 2d6ae3cc79334..15f9cc12ba24b 100644 --- a/sapi/fpm/fpm/fpm_main_arginfo.h +++ b/sapi/fpm/fpm/fpm_main_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: b4ac4c0f1d91c354293e21185a2e6d9f99cc9fcc */ +/* This is a generated file, edit fpm_main.stub.php instead. + * Stub hash: 41b70820e2cfecb8a611303d8e485193ee111637 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_fastcgi_finish_request, 0, 0, _IS_BOOL, 0) ZEND_END_ARG_INFO() diff --git a/sapi/litespeed/lsapi_main_arginfo.h b/sapi/litespeed/lsapi_main_arginfo.h index 4ba5419fe49a1..286866e79951d 100644 --- a/sapi/litespeed/lsapi_main_arginfo.h +++ b/sapi/litespeed/lsapi_main_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 3419f4e77bd091e09e0cfc55d81f443d5a3396ff */ +/* This is a generated file, edit lsapi_main.stub.php instead. + * Stub hash: 582b137a2788ae1b15853c4b78da551419390da9 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_litespeed_request_headers, 0, 0, IS_ARRAY, 0) ZEND_END_ARG_INFO() diff --git a/sapi/phpdbg/phpdbg_arginfo.h b/sapi/phpdbg/phpdbg_arginfo.h index 71705bd661fed..a0de4b17390f3 100644 --- a/sapi/phpdbg/phpdbg_arginfo.h +++ b/sapi/phpdbg/phpdbg_arginfo.h @@ -1,5 +1,5 @@ -/* This is a generated file, edit the .stub.php file instead. - * Stub hash: 08e29f02953f23bfce6ce04f435227b4e5e61545 */ +/* This is a generated file, edit phpdbg.stub.php instead. + * Stub hash: b70a58c682c96e8ba660738a0d157af58e44e384 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_phpdbg_break_next, 0, 0, IS_VOID, 0) ZEND_END_ARG_INFO()