php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #70303 Incorrect constructor reflection for ArrayObject
Submitted: 2015-08-19 13:15 UTC Modified: 2015-08-19 14:36 UTC
From: rasmus at mindplay dot dk Assigned: cmb (profile)
Status: Closed Package: Reflection related
PHP Version: 5.6.12 OS:
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: rasmus at mindplay dot dk
New email:
PHP Version: OS:

 

 [2015-08-19 13:15 UTC] rasmus at mindplay dot dk
Description:
------------
The constructor reflection for ArrayObject is wrong - the first parameter is optional, yet is reflected as non-optional.


Test script:
---------------
$f = new ReflectionClass('ArrayObject');

$c = $f->getConstructor();

$params = $c->getParameters();

$param = $params[0];

var_dump($param->isOptional());


Expected result:
----------------
bool(true)


Actual result:
--------------
bool(false)

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2015-08-19 13:58 UTC] cmb@php.net
-Status: Open +Status: Verified -Assigned To: +Assigned To: cmb
 [2015-08-19 13:58 UTC] cmb@php.net
Confirmed: <https://3v4l.org/07FU2> and <https://3v4l.org/gAh5F>.
 [2015-08-19 14:35 UTC] cmb@php.net
Automatic comment on behalf of cmb
Revision: http://git.php.net/?p=php-src.git;a=commit;h=484b92919bd3b06f3eae845bc1a592da58bef64e
Log: Fix #70303: Incorrect constructor reflection for ArrayObject
 [2015-08-19 14:35 UTC] cmb@php.net
-Status: Verified +Status: Closed
 [2015-08-19 14:36 UTC] cmb@php.net
The fix for this bug has been committed.

Thank you for the report, and for helping us make PHP better.
 [2015-09-03 18:10 UTC] ab@php.net
Automatic comment on behalf of cmb
Revision: http://git.php.net/?p=php-src.git;a=commit;h=484b92919bd3b06f3eae845bc1a592da58bef64e
Log: Fix #70303: Incorrect constructor reflection for ArrayObject
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon Dec 30 17:01:29 2024 UTC