[php-src] master: Merge branch 'PHP-8.6'

From: Date: Wed, 04 Nov 2026 23:34:55 +0000
Subject: [php-src] master: Merge branch 'PHP-8.6'
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-143338@lists.php.net to get a copy of this message
Author: Jorg Sowa (jorgsowa) Date: 2026-11-05T00:21:19+01:00 Commit: https://github.com/php/php-src/commit/7e29fba97d11852373b098e35d2b0328bb437fcb Raw diff: https://github.com/php/php-src/commit/7e29fba97d11852373b098e35d2b0328bb437fcb.diff Merge branch 'PHP-8.6' Changed paths: A Zend/tests/assert/expect_interface_extends.phpt M Zend/zend_ast.c Diff: diff --git a/Zend/tests/assert/expect_interface_extends.phpt b/Zend/tests/assert/expect_interface_extends.phpt new file mode 100644 index 000000000000..61775ffb9c21 --- /dev/null +++ b/Zend/tests/assert/expect_interface_extends.phpt @@ -0,0 +1,22 @@ +--TEST-- +AST printing of interface extends list +--INI-- +zend.assertions=1 +--FILE-- +<?php + +try { + assert(false && function () { + interface I extends A, B {} + }); +} catch (AssertionError $e) { + echo $e->getMessage(), "\n"; +} + +?> +--EXPECT-- +assert(false && function () { + interface I extends A, B { + } + +}) diff --git a/Zend/zend_ast.c b/Zend/zend_ast.c index ca02f68e3a65..60732096dfca 100644 --- a/Zend/zend_ast.c +++ b/Zend/zend_ast.c @@ -2131,7 +2131,7 @@ static ZEND_COLD void zend_ast_export_class_no_header(smart_str *str, const zend zend_ast_export_ns_name(str, decl->child[0], 0, indent); } if (decl->child[1]) { - smart_str_appends(str, " implements "); + smart_str_appends(str, (decl->flags & ZEND_ACC_INTERFACE) ? " extends " : " implements "); zend_ast_export_ex(str, decl->child[1], 0, indent); } smart_str_appends(str, " {\n");

« previous php.cvs (#143338) next »