Parallel execution of unittests

bearophile via Digitalmars-d digitalmars-d at puremagic.com
Mon May 5 06:59:36 PDT 2014


Jonathan M Davis:

> Honestly, I wouldn't even consider distributing something that 
> was only a
> single module in size unless it were on the scale of 
> std.datetime, which we've
> generally agreed is too large for a single module.
> So, a single module
> wouldn't have enough functionality to be worth distributing.

This reasoning style is similar to the Groucho Marx quote:
"I don't care to belong to any club that will have me as a member"

In the Python world online you can find thousands of 
single-module projects (few of them are mine). I have plenty of 
single D modules that encapsulate a single functionality. In 
Haskell cabal you can find many single modules that add 
functionality (plus larger projects like Diagrams).

And I think D has to strongly encourage the creation of such 
ecosystem of modules that you download and use in your programs. 
You can't have everything in the standard library, it's not wise 
to re-write them (like 2D vectors, I have already seen them 
implemented ten different times in the D world), and there are 
plenty of useful things that can be contained in single modules, 
especially if such modules can import the functionality of one or 
more other modules.


> And even if I were to distribute such a module, I'd let its
> documentation speak for itself
> and otherwise just expect the programmer to read the code.

A demo and the documentation are both useful. And the 
documentation can't replace stand-alone functionality.


> Regardless, the version specifier makes it easy to have a 
> version where main is defined for demos or whatever else
> you might want to do with it.

Bye,
bearophile


More information about the Digitalmars-d mailing list