Modules and namespaces I have strange problem or maybe I'm doing something wrong. I've create my own module. My .info file looks like this:

...
files[] = DdFactory.inc
files[] = ArticleManager.inc
...


In ArticleManager.inc I have class ArticleManager (no namespace). Than I would like to use DFactory (namespace Dd) class in ArticleManager. 

Here is the beginning of DFactory.inc:

&lt;?php

namespace Dd;

class Factory
{
...


In ArticleManger I have:

$ob = new \Dd\Factory();


And error:

Fatal error:  Class 'Dd\Factory' not found


I can make it work in two ways. Or I have to remove namespaces than $ob = new Factory(); or I have to add include 'DFactory.inc' at top of ArticleManager.inc 

Could somebody tells me how to run it with namespaces and without the include? I'm using drupal 7.
Try the xautoload (http://drupal.org/project/xautoload) module to help with autoloading. It's faster and less fragile then the D7 core code registry.

XAutoload implements the PSR-0 standard, which is how Drupal 8 will handle namespaces, so it's the most future proof way.