[development] when we run out of characters
vlado at dikini.net
Wed May 17 11:11:42 UTC 2006
> >> Let's just turn every module into a static class, and change the whole
> >> hook system to call namespace-contained methods rather than plain
> >> functions.
This does have a lot of merit - classes are the natural way to emulate
namespaces in php.
The only real problem we have with that is include and require in code.
It must be used in top level, AFAIK, in order for the class to be
visible to everywhere, might be wrong.
In php5+ this solution will give additional benefits long term. We will
be able to use __autoload() to manage module includes automatically,
rather than doing had checks. When/if drupal moves exclusively to php5
this will have a huge effect on code simplicity and possibly
> That may be a joke, but it isn't actually that horrible of an idea. I realize
> people'd never go for it but it *does* solve the namespace issue nicely.
More information about the development