Need review: explicit package protection

Jonathan M Davis via Digitalmars-d digitalmars-d at puremagic.com
Tue Jun 10 09:05:21 PDT 2014


On Tue, 10 Jun 2014 11:48:17 +0000
Dicebot via Digitalmars-d <digitalmars-d at puremagic.com> wrote:

> On Monday, 9 June 2014 at 13:51:30 UTC, Dejan Lekic wrote:
> > Issue #2)
> > Package module is not possible in projects with flat structure
> > (projects whose authors did not reserve directories for
> > packages.
> >
> > Example:
> > Imagine developer has *all* his D sources in
> > /home/dejan/src/d/myawesomeproject because he does not like big
> > directory structures. Say his project has two packages foo.bar
> > and foo.baz . And has following files in his project directory:
> >
> > tools.d // module foo.bar.tools;
> > control.d // module foo.bar.control;
> > screen.d // module foo.baz.screen;
> > window.d // module foo.baz.window;
> > package.d // can be only one 'package.d' within a single
> > directory!
> > main.d
> >
> > ...
>
> I'd call this "INVALID WON"T FIX" :) D module system is defined
> to have strong 1-to-1 matching with file system. Any attempt to
> circumvent that in favor of personal preferences is asking for
> trouble and is not worth supporting.

+1

- Jonathan M Davis


More information about the Digitalmars-d mailing list