Bug #51181 [Opn->Bgs]: eval is not work for using namespaces

From: Date: Tue, 02 Mar 2010 10:51:04 +0000
Subject: Bug #51181 [Opn->Bgs]: eval is not work for using namespaces
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-148165@lists.php.net to get a copy of this message
Edit report at http://bugs.php.net/bug.php?id=51181&edit=1

 ID:               51181
 Updated by:       jani@php.net
 Reported by:      abca_b_cabcom at hotmail dot com
 Summary:          eval is not work for using namespaces
-Status:           Open
+Status:           Bogus
 Type:             Bug
-Package:          *Compile Issues
+Package:          *General Issues
 Operating System: Doesn' matter
 PHP Version:      5.3.1

 New Comment:

Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system
is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.




Previous Comments:
------------------------------------------------------------------------
[2010-03-02 11:51:03] jani@php.net

-Status:  Open
+Status:  Bogus
-Package: *Compile Issues
+Package: *General Issues


------------------------------------------------------------------------
[2010-03-02 07:27:49] abca_b_cabcom at hotmail dot com

Description:
------------
eval('use test\me\test as testme;');

doesn't work

it produce
Fatal error: Class 'testme' not found
if I call the testme class

Test script:
---------------
//test.php
<?php

include './includes.php';

eval('use test\me\test as testme;');

$testme = new testme;

//Includes.php
<?php

include './test.class.php';

function testme() {
	return 'test\me\test';
}

//test.class.php
<?php

namespace test\me;

class test {
	function __construct() {
		echo 'here is run';
	}
}


Expected result:
----------------
There should be no error when i call the testme class

Actual result:
--------------
Fatal error occures


------------------------------------------------------------------------



-- 
Edit this bug report at http://bugs.php.net/bug.php?id=51181&edit=1


Thread (2 messages)

« previous php.bugs (#148165) next »