In Code Complete 2nd Edition, Steve McConnell wrote the following (page 732):
Techniques that make good code look good and bad code look bad are more useful than techniques that make all code look good.
I have an argue about that and Eclipse code format rules with a colleague. He said that badly looking code makes refactoring and cleaning up bad code harder, since he needs more effort to understand the code. On the other hand I've found that code that looks bad is similar to a "be careful" warning. I reminds me that I have to think it through twice before modifying anything to make sure I won't broke anything. Furthermore, it probably forces developers to restructure their code to be a little bit more beautiful and better structured.
Another thing is
@SuppressFBWarnings annotations for false positive FindBugs warnings which also makes the code harder to maintain since these annotations look bad, break the structure of code and they're hard to read. On the other hand I think these also save time. When a developer finds some code that smells and FindBugs has already found it the developer probably has a reason why it's OK (or why somebody thought it's OK) in the
justification element of the annotation.
Are there other reasons why is it worth or not to make bad code to look bad or it is rather a psychology question and both formatting are acceptable?