Back to Search Start Over

How code composition strategies affect merge conflict resolution?

Authors :
S. Campos Junior, Heleno de
de Menezes, Gleiph Ghiotto L.
de Oliveira Barros, Márcio
van der Hoek, André
Paulino Murta, Leonardo Gresta
Source :
Journal of Software Engineering Research & Development; 2024, Vol. 12 Issue 1, p139-155, 17p
Publication Year :
2024

Abstract

Software developers often need to combine their contributions. This operation is called merge. When the contributions happen at the same physical region in the source code, the merge is marked as conflicting and must be manually resolved by the developers. Existing studies explore why conflicts happen, their characteristics, and how they are resolved. This paper investigates a subset of merge conflicts, which may be resolved using a combination of existing lines. We analyze 10,177 conflict chunks of popular projects that were resolved by combining existing lines, aiming at characterizing and finding patterns frequently addressed by developers to resolve them. We found that these conflicting chunks and their resolutions are usually small (they have a median of 6 LOC and 3 LOC, respectively). Moreover, 98.6% of the analyzed resolutions preserve the order of the lines in the conflicting chunks. We also found that 72.7% of the chunk resolutions do not interleave lines from different contributions more than once. Finally, developers prefer to resolve conflicts containing only Import statements using lines from the local version of the conflict. When used as heuristics for automatic merge resolution, these findings could reduce the search space by 94.7%, paving the road for future search-based software engineering tools for this problem. [ABSTRACT FROM AUTHOR]

Details

Language :
English
ISSN :
21951721
Volume :
12
Issue :
1
Database :
Complementary Index
Journal :
Journal of Software Engineering Research & Development
Publication Type :
Academic Journal
Accession number :
182589071
Full Text :
https://doi.org/10.5753/jserd.2024.3638