Re: [PHP-DEV] RFC - Namespace initializers

2011-01-05 Thread Nicolas Grekas
at runtime namespace resolution, static code analysis is now very hard In general case, it always was so. Think of $foo-$bar() Maybe I was too strong about the term general case. What I though about is that although variable calls have always been there, they are both statistically rare and

Re: [PHP-DEV] RFC - Namespace initializers

2011-01-05 Thread Michael Morris
One of the first things I tried when I seriously started exploring namespaces was the ideal of dynamic runtime loading. Consider class \A\Foo. I have a project that has \B\Foo extends \A\Foo. For that project though I want the autoloader to pull an unqualified request for Foo from \B\Foo even if

[PHP-DEV] RFC - Namespace initializers

2010-12-31 Thread Nicolas Grekas
Dear all, this RFC started by me having a problem on these subjects (not only me I think) : - namespaced functions and constants loading, or rather not-autoloading, - interfaces loading (this time, autoloading). About namespaced functions and constants, the fact that they are not autoloaded

Re: [PHP-DEV] RFC - Namespace initializers

2010-12-31 Thread Larry Garfield
On Friday, December 31, 2010 7:56:39 am Nicolas Grekas wrote: Dear all, this RFC started by me having a problem on these subjects (not only me I think) : - namespaced functions and constants loading, or rather not-autoloading, - interfaces loading (this time, autoloading). snip So, my

Re: [PHP-DEV] RFC - Namespace initializers

2010-12-31 Thread Stas Malyshev
Hi! About namespaced functions and constants, the fact that they are not autoloaded makes them useless for any code that wants some good packaging. For example I looked at the Doctrine2 code, and (tell me if This is not true. You can always load stuff manually - in fact, many languages don't