Cannot alias namespace with `use`
danog opened this issue · comments
Daniil Gentili commented
Code:
// src/n.php
namespace a;
use b;
include 'src/included.php';
new b\test();
// src/included.php
namespace b;
class test
{}
Result:
[daniil@daniil-arch jav]$ php src/n.php
[daniil@daniil-arch jav]$ jppm start
-> linux
-> app:run
-> install
Fatal error: Uncaught Error: Class 'a\b\test' not found in res://n.php on line 9, position 1
Stack Trace:
#0 <internal>() called at [res://n.php:1]
#1 {main}
thrown in res://n.php on line 9