Walter Bright:
> Sorry, I'd overlooked that.

You have nothing to be sorry of, good Walter, you are not supposed to read 
every silly thing that I post on this newsgroups.

I like Design by Contract (DbC), even if I don't use it often. I think DbC is a 
very requested feature for Java because Java programmers already have good ways 
to perform unit testing. I think unit testing is more important & useful than 
DbC (even if their purpose is not the same). And I think current D built-in 
unit test system is handy and easy to use, but not good enough. Time ago I have 
listed few basic missing features. One of the most important ones is to be able 
to see the number and names of the unit tests that have failed. And D being so 
good at compile-time processing will need some way to do compile-time unit 
testing too, for example with a way to catch and summarize compile-time 
asserts, listing how many of them have failed.

I don't use DbC often, but I use unit tests a *lot* in D, I use them in every 
function and class I write in "production" code. In D I write 1-2 lines of unit 
tests for every line of code. I also use coverage analysis often (well, I'd 
like to use it, but LDC doesn't have this feature yet, and the coverage 
analysis of DMD is partially broken, especially for largish programs), and 
profiling (kinda missing in LDC).

Bye,
bearophile

Reply via email to