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

gen_stub: Fix undefined variable warning (#18821)

> PHP Warning:  Undefined variable $code in build/gen_stub.php on line 5322

Introduced in php/php-src#18735.
This commit is contained in:
Tim Düsterhus
2025-06-10 15:28:34 +02:00
committed by GitHub
parent 3399235bec
commit 5f9a0b568b

View File

@@ -5313,6 +5313,8 @@ function generateGlobalConstantAttributeInitialization(
$constInfos,
"",
static function (ConstInfo $constInfo) use ($allConstInfos, $phpVersionIdMinimumCompatibility) {
$code = "";
if ($constInfo->attributes === []) {
return null;
}