php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #49022 Able to define unusable functions
Submitted: 2009-07-22 20:35 UTC Modified: 2009-07-22 20:42 UTC
From: a dot dotreppe at aspyct dot org Assigned:
Status: Not a bug Package: Scripting Engine problem
PHP Version: 5.2SVN-2009-07-22 (snap) OS: Windows Vista 32bit
Private report: No CVE-ID: None
 [2009-07-22 20:35 UTC] a dot dotreppe at aspyct dot org
Description:
------------
There is a consistency problem between the names we can give to a function, and the names we can actually use.

For instance, I can create a function named _, but not use it.

Reproduce code:
---------------
// This will parse without error
function _($txt) {
    // Do some stuff
}


// This will cause a parse error
_('yes');


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-07-22 20:38 UTC] rasmus@php.net
Could you provide the actual error?  I doubt you are getting a parse error there.
 [2009-07-22 20:39 UTC] a dot dotreppe at aspyct dot org
That was an error from me, sorry.)
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Tue Jul 15 17:01:33 2025 UTC