LarryRoth.net

Just my thoughts

FindBugs helps you fix your code

There is a good article at IBM Developer Works about using the FindBugs static code analysis tool. Test cases are important, but when you inherit code, a good static analysis code tool can really help you out. The article is a couple years old, but still quite relevant. I thought this comment summed it up nicely. From the article:
Much of the knowledge of how a class works (or is supposed to work) evaporates shortly after it is written, in the form of implicit assumptions, invariants, and expected use cases that are clear in the developer's head but never get written down in the form of design notes, comments, or documentation. Existing code is always harder to work with than new code.1
Even with strong test cases, you can still miss more complex bug patterns. FindBugs can help you out.
[1] Java theory and practice: Kill bugs dead, http://www-128.ibm.com/developerworks/java/library/j-jtp06294.html, posted June 29, 2004, viewed July 20, 2006
blog comments powered by Disqus