php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #43359 Namespace accepts incorrect name
Submitted: 2007-11-21 11:12 UTC Modified: 2008-01-18 18:44 UTC
From: felipensp at gmail dot com Assigned: dmitry (profile)
Status: Closed Package: Scripting Engine problem
PHP Version: 5.3CVS-2007-11-21 (snap) OS:
Private report: No CVE-ID: None
 [2007-11-21 11:12 UTC] felipensp at gmail dot com
Description:
------------
See the code below.

Reproduce code:
---------------
<?php

namespace ::foo;
var_dump(__NAMESPACE__); // string(0) ""

---
<?php

namespace ::foo::bar; // Fatal error: Class 'foo' not found 


Expected result:
----------------
Fatal error with other message in both

Actual result:
--------------
string(0) ""
---
Fatal error: Class 'foo' not found

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2007-11-24 12:30 UTC] jani@php.net
Another namespace issue.
 [2008-01-18 18:44 UTC] felipe@php.net
This bug has been fixed in CVS.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.

Already fixed by Dmitry...
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Sun Jul 13 14:01:31 2025 UTC