On 06/19/2013 11:54 PM, Walter Bright wrote:
On 6/19/2013 4:01 AM, Szymon Gatner wrote:
This is not strictly D related but I am very curious about D's
community opinion
on the points made by non other than Jim Coplien here:
TDD strikes me as an ad-hoc way of constructing code, and is a poor
substitute for thinking about the problem as a whole. For example, I
don't really see how getting a square root function to pass its test
cases is going to lead one to implementing one of the classic algorithms
for computing square roots. I don't see how TDD for a compiler will lead
one to rediscover what is known about the best way to organize the logic
of a compiler.
TDD is "curve fitting" which is what one does when one has no
understanding.
Concrete example in DMD: 'forward reference error'.
D's support of unit testing is not an endorsement of TDD.