[php-src] PHP-8.6: [`%pS` migration] Use `%pS` in ext/bcmath (#23147)
| From: | Daniel Scherzer via GitHub | Date: | Mon, 05 Oct 2026 00:59:40 +0000 |
| Subject: | [php-src] PHP-8.6: [`%pS` migration] Use `%pS` in ext/bcmath (#23147) | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-141934@lists.php.net to get a copy of this message | ||
Author: Daniel Scherzer (DanielEScherzer)
Committer: GitHub (web-flow)
Pusher: DanielEScherzer
Date: 2026-10-04T17:59:37-07:00
Commit: https://github.com/php/php-src/commit/620cd6930f2da351d692f4144e0d2711c03fbd75
Raw diff: https://github.com/php/php-src/commit/620cd6930f2da351d692f4144e0d2711c03fbd75.diff
[
%pS migration] Use %pS in ext/bcmath (#23147)
Changed paths:
M ext/bcmath/bcmath.c
Diff:
diff --git a/ext/bcmath/bcmath.c b/ext/bcmath/bcmath.c
index dc693ad65e91..a7f8bc143a48 100644
--- a/ext/bcmath/bcmath.c
+++ b/ext/bcmath/bcmath.c
@@ -971,7 +971,7 @@ static zval *bcmath_number_write_property(zend_object *obj, zend_string *name, z
static void bcmath_number_unset_property(zend_object *obj, zend_string *name, void **cache_slot)
{
if (zend_string_equals(name, ZSTR_KNOWN(ZEND_STR_VALUE)) || zend_string_equals_literal(name,
"scale")) {
- zend_throw_error(NULL, "Cannot unset readonly property %s::$%s",
ZSTR_VAL(obj->ce->name), ZSTR_VAL(name));
+ zend_throw_error(NULL, "Cannot unset readonly property %pS::$%pS", obj->ce->name,
name);
return;
}
@@ -1406,8 +1406,8 @@ static int bcmath_number_compare(zval *op1, zval *op2)
Z_PARAM_PROLOGUE(0, 0); \
if (UNEXPECTED(!(zend_parse_arg_obj(_arg, &(dest_obj), ce, 0) || \
zend_parse_arg_str_or_long(_arg, &(dest_str), &(dest_long), &_dummy, 0, _i)))) { \
- zend_argument_type_error(_i, "must be of type int, string, or %s, %s given", \
- ZSTR_VAL(bcmath_number_ce->name), zend_zval_value_name(_arg)); \
+ zend_argument_type_error(_i, "must be of type int, string, or %pS, %s given", \
+ bcmath_number_ce->name, zend_zval_value_name(_arg)); \
_error_code = ZPP_ERROR_FAILURE; \
break; \
}
@@ -1900,7 +1900,7 @@ PHP_METHOD(BcMath_Number, __unserialize)
return;
fail:
- zend_throw_exception_ex(NULL, 0, "Invalid serialization data for %s object",
ZSTR_VAL(bcmath_number_ce->name));
+ zend_throw_exception_ex(NULL, 0, "Invalid serialization data for %pS object",
bcmath_number_ce->name);
RETURN_THROWS();
}