php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #75374 ReflectionParameter::getDeclaringClass() can return n ull
Submitted: 2017-10-13 17:43 UTC Modified: 2018-01-29 22:53 UTC
From: benjamin dot morel at gmail dot com Assigned: vrana (profile)
Status: Closed Package: Documentation problem
PHP Version: Irrelevant OS: N/A
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: benjamin dot morel at gmail dot com
New email:
PHP Version: OS:

 

 [2017-10-13 17:43 UTC] benjamin dot morel at gmail dot com
Description:
------------
when called on a function (not method) parameter, ReflectionParameter::getDeclaringClass() returns null.

The documentation should reflect this, as it currently implies that a ReflectionClass is always returned.

Expected result:
----------------
public ReflectionClass|null ReflectionParameter::getDeclaringClass ( void )

Actual result:
--------------
public ReflectionClass ReflectionParameter::getDeclaringClass ( void )

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2018-01-29 22:53 UTC] vrana@php.net
Automatic comment from SVN on behalf of vrana
Revision: http://svn.php.net/viewvc/?view=revision&revision=344084
Log: Document return value for functions (bug #75374)
 [2018-01-29 22:53 UTC] vrana@php.net
-Status: Open +Status: Closed -Assigned To: +Assigned To: vrana
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 25 08:01:28 2024 UTC