From eb1e22b1dfdced77c82b62f223381fe12bb26e09 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?M=C3=A1t=C3=A9=20Kocsis?= Date: Thu, 8 Jan 2026 22:47:22 +0100 Subject: [PATCH] Fix constant references inside parameter default values when generating the manual --- build/gen_stub.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/gen_stub.php b/build/gen_stub.php index e1e225dc201..4a293972f04 100755 --- a/build/gen_stub.php +++ b/build/gen_stub.php @@ -2184,7 +2184,7 @@ OUPUT_EXAMPLE $defaultValue = $arg->getDefaultValueAsMethodSynopsisString(); if ($defaultValue !== null) { $initializer = $doc->createElement('initializer'); - if (preg_match('/^[a-zA-Z_][a-zA-Z_0-9]*$/', $defaultValue)) { + if (preg_match('/^[a-zA-Z_][a-zA-Z_0-9\:\\\\]*$/', $defaultValue)) { $constant = $doc->createElement('constant', $defaultValue); $initializer->appendChild($constant); } else {