Today while working on an Arraylist implementation in C and find
myself working hard to find a very strange bug. As of now I still
haven't found the cause, and will probably be working on it for some
time more tonight.
I only found this bug because I decided to make heavy use of C
assertions. This reminds me of just how important testing is the
process of developing good software. Had I omitted these assertions,
the code would have seemed to work correctly, only given me error
ridden results, which usually take much longer to debug.
It is strange that there is so little desire to test first among
programmers. Lack of testing invariably leads to long painful bouts of
working through seemingly correct, but functionally wrong,
code. Hopefully the ideas of software correctness and testing will take
root more firmly in the future.
No comments:
Post a Comment