Since 5.4, the ZEND_BEGIN_ARG_INFO_EX was replaced
by non _EX, causing Reflection to assume the
$context parameter is required.
- Core:
. Fixed bug #66286 (Incorrect object comparison with inheritance). (Nikita)
+ . Fixed bug #66509 (copy() arginfo has changed starting from 5.4). (willfitch)
- Session:
. Fixed bug #66481 (Calls to session_name() segfault when session.name is
ZEND_BEGIN_ARG_INFO(arginfo_fstat, 0)
ZEND_ARG_INFO(0, fp)
ZEND_END_ARG_INFO()
-ZEND_BEGIN_ARG_INFO(arginfo_copy, 0)
+ZEND_BEGIN_ARG_INFO_EX(arginfo_copy, 0, 0, 2)
ZEND_ARG_INFO(0, source_file)
ZEND_ARG_INFO(0, destination_file)
ZEND_ARG_INFO(0, context)
--- /dev/null
+--TEST--
+Bug #66509 (copy() showing $context parameter as required)
+--FILE--
+<?php
+
+$r = new \ReflectionFunction('copy');
+
+foreach($r->getParameters() as $p) {
+ var_dump($p->isOptional());
+}
+?>
+--EXPECT--
+bool(false)
+bool(false)
+bool(true)