1
0
mirror of https://github.com/php/php-src.git synced 2026-03-24 00:02:20 +01:00

gen_stub: drop unused parameter in ConstInfo::getClassConstDeclaration()

This commit is contained in:
Daniel Scherzer
2025-09-04 11:56:12 +03:00
parent a8543dfdd2
commit a1d8e525f0

View File

@@ -2759,7 +2759,7 @@ class ConstInfo extends VariableLike
// Condition will be added by generateCodeWithConditions()
if ($this->name instanceof ClassConstName) {
$code = $this->getClassConstDeclaration($value, $allConstInfos);
$code = $this->getClassConstDeclaration($value);
} else {
$code = $this->getGlobalConstDeclaration($value);
}
@@ -2820,12 +2820,10 @@ class ConstInfo extends VariableLike
throw new Exception("Unimplemented constant type");
}
/** @param array<string, ConstInfo> $allConstInfos */
private function getClassConstDeclaration(EvaluatedValue $value, array $allConstInfos): string
private function getClassConstDeclaration(EvaluatedValue $value): string
{
$constName = $this->name->getDeclarationName();
// TODO $allConstInfos is unused
$zvalCode = $value->initializeZval("const_{$constName}_value");
$code = "\n" . $zvalCode;