Spork: Structured Merge for Java With Formatting Preservation - Archive ouverte HAL Accéder directement au contenu
Article Dans Une Revue IEEE Transactions on Software Engineering Année : 2023

Spork: Structured Merge for Java With Formatting Preservation

Résumé

The highly parallel workflows of modern software development have made merging of source code a common activity for developers. The state of the practice is based on line-based merge, which is ubiquitously used with "git merge". Line-based merge is however a generalized technique for any text that cannot leverage the structured nature of source code, making merge conflicts a common occurrence. As a remedy, research has proposed structured merge tools, which typically operate on abstract syntax trees instead of raw text. Structured merging greatly reduces the prevalence of merge conflicts but suffers from important limitations, the main ones being a tendency to alter the formatting of the merged code and being prone to excessive running times. In this paper, we present SPORK, a novel structured merge tool for JAVA. SPORK is unique as it preserves formatting to a significantly greater degree than comparable state-of-the-art tools. SPORK is also overall faster than the state of the art, in particular significantly reducing worst-case running times in practice. We demonstrate these properties by replaying 1740 real-world file merges collected from 119 open-source projects, and further demonstrate several key differences between SPORK and the state of the art with in-depth case studies.
Fichier principal
Vignette du fichier
2202.05329.pdf (530.13 Ko) Télécharger le fichier
Origine : Fichiers produits par l'(les) auteur(s)

Dates et versions

hal-04423078 , version 1 (29-01-2024)

Identifiants

Citer

Simon Larsen, Jean-Rémy Falleri, Benoit Baudry, Martin Monperrus. Spork: Structured Merge for Java With Formatting Preservation. IEEE Transactions on Software Engineering, 2023, 49 (1), pp.64 - 83. ⟨10.1109/tse.2022.3143766⟩. ⟨hal-04423078⟩

Collections

CNRS
7 Consultations
20 Téléchargements

Altmetric

Partager

Gmail Facebook X LinkedIn More