A software system undergoes many code changes, which may affect code quality and maintainability. Refactoring techniques are a common strategy for restructuring source code and improving internal architecture. However, refactoring activities are limited to a catalog of well-known modifications, and we intend to investigate modifications to the source code, looking for patterns that affect its internal quality. In this work, we present a process for identifying code improvements and then learning from the modifications. This process extracts syntactic patterns of code changes and classifies them based on their impact on software maintainability. We executed the classification process on 132,819 code changes from seven GitHub repositories, obtaining 2405 significant code change patterns. Most code change patterns involve simple modifications to structural elements that have only a slight impact on maintainability. These modifications include renaming or moving code elements, simple refactoring, and adding a new implementation. We analyzed both simple modification patterns and many modifications to identify their impact on internal source code quality. The results show how significant a subset of identified patterns is to internal source code quality, as it improves or reduces maintainability variation.
Garcia et al. (Tue,) studied this question.
Synapse has enriched 5 closely related papers on similar clinical questions. Consider them for comparative context: