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

Use fast zpp for ReflectionClass constructor

At this point zpp overhead makes up a significant part of this
function.
This commit is contained in:
Nikita Popov
2019-05-08 17:04:28 +02:00
parent 90e285f6fd
commit e4e6820d10

View File

@@ -3669,13 +3669,13 @@ static void reflection_class_object_ctor(INTERNAL_FUNCTION_PARAMETERS, int is_ob
zend_class_entry *ce;
if (is_object) {
if (zend_parse_parameters(ZEND_NUM_ARGS(), "o", &argument) == FAILURE) {
return;
}
ZEND_PARSE_PARAMETERS_START(1, 1)
Z_PARAM_OBJECT(argument)
ZEND_PARSE_PARAMETERS_END();
} else {
if (zend_parse_parameters(ZEND_NUM_ARGS(), "z", &argument) == FAILURE) {
return;
}
ZEND_PARSE_PARAMETERS_START(1, 1)
Z_PARAM_ZVAL(argument)
ZEND_PARSE_PARAMETERS_END();
}
object = ZEND_THIS;