I suppose the real question is, as a language standard and a community preference, should this be considered a bug? Should people be free to use X.Y.hs or X/Y.hs styles?

First off all, the support you mention seems to be incomplete, or very recent. At least my ghci 7.10 failed to import a module with a dot-name. But maybe my quick-and-dirty test was broken…

I'll also add a fun variation to the discussion. Let's say I have two modules named Bar.Foo, and Bar.Baz and submodules Bar.Foo.Internals and Bar.Baz.Internals. (eg. for testing purposes) It always bugged me that the usual approach would be this:

╶┮▬ Bar/
 ├─┮▬ Baz/
 │ ╰─╴  Internals.hs

 
├─┮▬ Foo/
 │ ╰─╴  Internals.hs

 ─╴ Baz.hs
 
╰──╴ Foo.hs

My gripe is that here related modules are in completely unrelated positions. One way to solve it with dot-names would be

╶┮▬ Bar/
─╴ Baz.hs 
 ├──╴ Baz.Internals.hs
 ├──╴ Foo.hs
 ╰──╴ Foo.Internals.hs

But that can lead to a lot of clutter fast. So here's a variation which goes to the other extreme. It is completely unsupported right now though:

╶┮▬ Bar/
 ├─┮▬ Baz/
 │ ─╴ Internals.hs
 │ ╰─╴ hs

 
─┮▬ Foo/
   ─╴ Internals.hs
   ╰─╴ hs

That hs name does look a bit ridiculous, but the idea is to have something like an index.html without reserving a name. If slashes and dots were 100% interchangeable, this would be the logical extension. Now related files are in related positions. Downside: The hs files don't have a file extension. (There could be a special case to use .hs as a special name instead, but that would lead to hidden files and break consistency…)

I realize this version probably won't gain much approval, but between this and throwing everything and the kitchen sink on the top level just because some tools don't offer opened-up nested hierarchical views into directory structures – I would choose this one, personally. Or maybe a mixture, depending on actual structure. But then both options are better than the one with unrelated positions, and the dot-name approach might at least be one that works right now.


Cheers,
MarLinn