Merge branch 'PHP-7.2'

* PHP-7.2:
  Revert BC break caused by fixing bug #74035
This commit is contained in:
Sara Golemon 2017-11-06 17:52:35 -05:00
commit c33008339e
3 changed files with 4 additions and 15 deletions

View file

@ -4722,7 +4722,7 @@ ZEND_METHOD(reflection_class, isInstance)
}
/* }}} */
/* {{{ proto public stdclass ReflectionClass::newInstance([mixed* args], ...)
/* {{{ proto public stdclass ReflectionClass::newInstance(mixed* args, ...)
Returns an instance of this class */
ZEND_METHOD(reflection_class, newInstance)
{
@ -6444,8 +6444,8 @@ ZEND_BEGIN_ARG_INFO(arginfo_reflection_class_isInstance, 0)
ZEND_ARG_INFO(0, object)
ZEND_END_ARG_INFO()
ZEND_BEGIN_ARG_INFO_EX(arginfo_reflection_class_newInstance, 0, 0, 0)
ZEND_ARG_VARIADIC_INFO(0, args)
ZEND_BEGIN_ARG_INFO(arginfo_reflection_class_newInstance, 0)
ZEND_ARG_INFO(0, args)
ZEND_END_ARG_INFO()
ZEND_BEGIN_ARG_INFO(arginfo_reflection_class_newInstanceWithoutConstructor, 0)

View file

@ -265,7 +265,7 @@ Class [ <internal:Reflection> class ReflectionClass implements Reflector ] {
Method [ <internal:Reflection> public method newInstance ] {
- Parameters [1] {
Parameter #0 [ <optional> ...$args ]
Parameter #0 [ <required> $args ]
}
}

View file

@ -1,11 +0,0 @@
--TEST--
Bug #74035: getNumberOfRequiredParameters wrong for ReflectionClass::newInstance
--FILE--
<?php
$r = new ReflectionClass(ReflectionClass::class);
$m = $r->getMethod('newInstance');
echo $m->getNumberOfRequiredParameters();
?>
--EXPECT--
0