php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #60170 Example contradicts explanation above
Submitted: 2011-10-29 18:35 UTC Modified: 2011-10-29 19:30 UTC
From: Laurent dot Lyaudet at gmail dot com Assigned:
Status: Closed Package: Documentation problem
PHP Version: Irrelevant OS:
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: Laurent dot Lyaudet at gmail dot com
New email:
PHP Version: OS:

 

 [2011-10-29 18:35 UTC] Laurent dot Lyaudet at gmail dot com
Description:
------------
---
From manual page: http://www.php.net/language.namespaces.rules
---
Unless I've misunderstood something, I think there is the following error in the manual:
In example 1, call to F(); is said to be resolved as \A\F() then \F() in case of failure. But it contradicts rule 2 above that said that this unqualified name should have been translated using import to \C\E().


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2011-10-29 19:30 UTC] Laurent dot Lyaudet at gmail dot com
-Status: Open +Status: Closed
 [2011-10-29 19:30 UTC] Laurent dot Lyaudet at gmail dot com
I forgot that import couldn't apply to functions and constants. The non-uniform behavior of import is quite a "non-feature".
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Nov 21 13:01:29 2024 UTC