Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 1 addition & 5 deletions Zend/zend_builtin_functions_arginfo.h

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

54 changes: 9 additions & 45 deletions Zend/zend_exceptions_arginfo.h

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 1 addition & 5 deletions Zend/zend_generators_arginfo.h

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 1 addition & 5 deletions Zend/zend_interfaces_arginfo.h

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

16 changes: 10 additions & 6 deletions build/gen_stub.php
Original file line number Diff line number Diff line change
Expand Up @@ -3285,11 +3285,12 @@ public function getRegistration(array $allConstInfos): string
$flagCodes = generateVersionDependentFlagCode("%s", $this->getFlagsByPhpVersion(), $this->phpVersionIdMinimumCompatibility);
$flags = implode("", $flagCodes);

$classMethods = ($this->funcInfos === []) ? 'NULL' : "class_{$escapedName}_methods";
if ($this->type === "enum") {
$name = addslashes((string) $this->name);
$backingType = $this->enumBackingType
? $this->enumBackingType->toTypeCode() : "IS_UNDEF";
$code .= "\tzend_class_entry *class_entry = zend_register_internal_enum(\"$name\", $backingType, class_{$escapedName}_methods);\n";
$code .= "\tzend_class_entry *class_entry = zend_register_internal_enum(\"$name\", $backingType, $classMethods);\n";
if ($flags !== "") {
$code .= "\tclass_entry->ce_flags |= $flags\n";
}
Expand All @@ -3299,9 +3300,9 @@ public function getRegistration(array $allConstInfos): string
$className = $this->name->getLast();
$namespace = addslashes((string) $this->name->slice(0, -1));

$code .= "\tINIT_NS_CLASS_ENTRY(ce, \"$namespace\", \"$className\", class_{$escapedName}_methods);\n";
$code .= "\tINIT_NS_CLASS_ENTRY(ce, \"$namespace\", \"$className\", $classMethods);\n";
} else {
$code .= "\tINIT_CLASS_ENTRY(ce, \"$this->name\", class_{$escapedName}_methods);\n";
$code .= "\tINIT_CLASS_ENTRY(ce, \"$this->name\", $classMethods);\n";
}

if ($this->type === "class" || $this->type === "trait") {
Expand Down Expand Up @@ -5103,9 +5104,7 @@ static function (FuncInfo $funcInfo) use ($fileInfo, &$generatedFunctionDeclarat
}
);

if (!empty($fileInfo->funcInfos)) {
$code .= generateFunctionEntries(null, $fileInfo->funcInfos);
}
$code .= generateFunctionEntries(null, $fileInfo->funcInfos);

foreach ($fileInfo->classInfos as $classInfo) {
$code .= generateFunctionEntries($classInfo->name, $classInfo->funcInfos, $classInfo->cond);
Expand Down Expand Up @@ -5156,6 +5155,11 @@ function generateClassEntryCode(FileInfo $fileInfo, array $allConstInfos): strin

/** @param FuncInfo[] $funcInfos */
function generateFunctionEntries(?Name $className, array $funcInfos, ?string $cond = null): string {
// No need to add anything if there are no function entries
if ($funcInfos === []) {
return '';
}

$code = "\n";

if ($cond) {
Expand Down
12 changes: 2 additions & 10 deletions ext/com_dotnet/com_extension_arginfo.h

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

18 changes: 3 additions & 15 deletions ext/curl/curl_arginfo.h

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading