One of the really cool tools my current group uses is the Code Review feature in Rational Software Architect. I have always thought (and many may argue) that I write reasonably legible code. I try to stick to best practices, make it look clean, well documented and well constructed. Well, unfortunately the default code review did not think as highly of my code as I. It found some great things and I was happy to learn them and change my code for the better. One really great aspect of the code review is that it not only picks out things you may not know but since it is automated it will find things that are just plane mistakes. One of the rules we used was to not allow for the instantiation of a new Boolean object. This is a waste of memory and not needed when you have the static methods Boolean.valueOf().
From the JavaDoc it clearly states:
public static Boolean valueOf(boolean b)
This is just one small example of what automation can give you. I did find many of the errors reported simply annoying because the automation doesn’t understand the context of the code however overall the tool is excellent and should be used by all teams that use RSA.