php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #48569 Called from the global scope error on code that worked before
Submitted: 2009-06-16 17:29 UTC Modified: 2009-07-28 12:36 UTC
Votes:6
Avg. Score:3.7 ± 0.9
Reproduced:4 of 4 (100.0%)
Same Version:1 (25.0%)
Same OS:1 (25.0%)
From: ken at smallboxsoftware dot net Assigned: dmitry (profile)
Status: Wont fix Package: Scripting Engine problem
PHP Version: 5.3.0RC3 OS: RHEL 5.3
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2009-06-16 17:29 UTC] ken at smallboxsoftware dot net
Description:
------------
"Called from the global scope" error now appears in situations where it did not previously. 

for example: 

<?php
function foo() {
 include "macro_to_process_arguments.php";
}
?>

<?php
// macro_to_process_arguments.php
$args = func_get_args();
?>

Now triggers an error. 

Reproduce code:
---------------
Called from the global scope

Expected result:
----------------
Not to get the above error message. 


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-07-28 12:34 UTC] dmitry@php.net
It's not going to be fixed. It worked before not on purpose, but because of wired func_get_args() implementation.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Apr 28 19:01:28 2024 UTC