We decided to leave the existing functions but added comments about our suspicions, marked them as "deprecation candidate", wrote new ones that were only called from new code. We also heavily documented our additions. This approach is similar to changing public APIs: You rarely delete, you usually add and mark old code as deprecated so that existing software continues to function with the new API version.
To be able to update design/architecture, we first had to improve comprehensibility of existing code by removing clutter with these steps:
To be able to update design/architecture, we first had to improve comprehensibility of existing code by removing clutter with these steps:
- Renamed variables, functions and classes to make them easier to understand.
- There were a lot of repeating code due to creation of new classes by copy-pasting old classes. We moved common code to utility classes/namespaces which made classes a lot lighter.
No comments:
Post a Comment