Chapter 5. Clues to Complexity
Here are clues that tell you that your code may be too complex:
- You have to add "hacks" to make things keep working.
- Other developers keep asking you how some part of the code works.
- Other developers keep misusing your code, and causing bugs.
- Reading a line of code takes longer than an instant for an experienced developer.
- You feel scared to modify this part of the code.
- Management seriously considers hiring more than one developer to work on a single class or file.
- It's hard to figure out how to add a feature.
- Developers often argue about how things should be implemented in this part of the code.
- People make utterly nonsensical changes to this part of the code very often, which you catch only during code review, or only after the change has been checked in.
-Max