RefDiff: Detecting Refactorings in Version Histories
Authors:
- Danilo SilvaDSDanilo Silva
- Marco Tulio ValenteMVMarco Tulio Valente
Top Cited Papers
- 1 May 2017
- conference paper
- Published by Institute of Electrical and Electronics Engineers (IEEE)
- p. 269-279
Abstract
Refactoring is a well-known technique that is widely adopted by software engineers to improve the design and enable the evolution of a system. Knowing which refactoring operations were applied in a code change is a valuable information to understand software evolution, adapt software components, merge code changes, and other applications. In this paper, we present RefDiff, an automated approach that identifies refactorings performed between two code revisions in a git repository. RefDiff employs a combination of heuristics based on static analysis and code similarity to detect 13 well-known refactoring types. In an evaluation using an oracle of 448 known refactoring operations, distributed across seven Java projects, our approach achieved precision of 100% and recall of 88%. Moreover, our evaluation suggests that RefDiff has superior precision and recall than existing state-of-the-art approaches.Keywords
All Related Versions
This publication has 19 references indexed in Scilit:
- A field study of refactoring challenges and benefits2012
- When Does a Refactoring Induce Bugs? An Empirical Study2012
- Ref-Finder2010
- Template-based reconstruction of complex refactorings2010
- Making Program Refactoring SaferIEEE Software, 2010
- On the relation of refactorings and software defect prediction2008
- The JDEvAn tool suite in support of object-oriented evolutionary development2008
- Identifying Refactorings from Source-Code Changes2006
- CatchUp!2005
- Finding refactorings via change metricsACM SIGPLAN Notices, 2000