If I wrote a leading slash in use definition like this:
namespace Project;
use \Phalcon\Config;
class TestClass
{
public static function doSomething()
{
var_dump(new Config());
}
}
on runtime I got an error:
Fatal error: Class '\phalcon\config' not found in ...
PHP allow this syntax, but if the Zephir doesn't, it's a good reason to add a compiler warning, I think.
---
Want to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/6505517-runtime-error-with-leading-slash-in-used-classes?utm_campaign=plugin&utm_content=tracker%2F280146&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F280146&utm_medium=issues&utm_source=github).
If I wrote a leading slash in use definition like this:
on runtime I got an error:
PHP allow this syntax, but if the Zephir doesn't, it's a good reason to add a compiler warning, I think.