On Monday, 30 April 2012 at 01:08:28 UTC, Jonathan M Davis wrote:
On Sunday, April 29, 2012 17:50:48 Don wrote:
* package. I have no idea how a failed Java experiment got
incorporated
into D.
Really? In some cases, it's indispensable. For instance, once
std.datetime has
been split up, it will require it, or it would have duplicate a
bunch of
implementation-specific stuff which has no business in the
public API.
- Jonathan M Davis
It's entirely dependent on your coding style. For example, when
you look at Phobos you rarely (if ever?) see package functions.
This is because it's entirely module based with a strong degree
of separation between modules.
However, for someone coming from C#, removing package would be
awful. I personally use package quite often. For the most part, I
stick to one major class per file, and separate things across
library. There are plenty of things that I want other classes in
the package/static-library to use, but don't want to expose to
the public, and thus use package for.