Use folders as a collection of modules. foo/bar.d => import foo.bar; You don't actually have to separate them into folders - the directory layout is up to you. But this is the simplest method. Learn more here: http://digitalmars.com/d/2.0/module.html