php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #49093 ReflectionFunction fails to work with functions in fully qualified namespaces
Submitted: 2009-07-28 22:48 UTC Modified: 2009-07-28 22:51 UTC
From: crystality at mail dot ru Assigned:
Status: Not a bug Package: Reflection related
PHP Version: 5.3.0 OS: Windows XP SP3
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: crystality at mail dot ru
New email:
PHP Version: OS:

 

 [2009-07-28 22:48 UTC] crystality at mail dot ru
Description:
------------
Just about the same bug I've reported in #47593
This time ReflectionFunction fails to work with functions with fully qualified namespaces.

Reproduce code:
---------------
namespace ns;
function func(){}
//new \ReflectionFunction('ns\func'); //Works
new \ReflectionFunction('\ns\func'); //Throws exception

Expected result:
----------------
new ReflectionFunction object created

Actual result:
--------------
Fatal error: Uncaught exception 'ReflectionException' with message 'Function \ns\func() does not exist' in ... 

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-07-28 22:51 UTC] crystality at mail dot ru
Since the php.net site bugged a bit, threw "Warning: Cannot modify header information - headers already sent by (output started at /home/Web/sites/php-bugs-web/include/auth.inc:30) in /home/Web/sites/php-bugs-web/report.php on line 195" and sent me my own bug-report, I've made this by mistake. Refer to 49092.)
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Dec 21 17:01:58 2024 UTC