# RefDiff: Detecting Refactorings in Version Histories

**Authors:** Danilo Silva, Marco Tulio Valente

arXiv: 1704.01544 · 2018-08-07

## TL;DR

RefDiff is an automated tool that accurately detects various refactoring operations between code revisions in git repositories, aiding understanding of software evolution.

## Contribution

RefDiff introduces a novel combination of heuristics based on static analysis and code similarity to identify 13 refactoring types with high precision and recall.

## Key findings

- Achieved 100% precision and 88% recall on an oracle of 448 refactorings.
- Outperformed existing state-of-the-art refactoring detection tools.
- Effective across seven Java projects.

## 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.

## Full text

_Full body text omitted from this summary view._ Fetch the complete paper as Markdown: https://tomesphere.com/paper/1704.01544/full.md

## Figures

10 figures with captions in the complete paper: https://tomesphere.com/paper/1704.01544/full.md

## References

24 references — full list in the complete paper: https://tomesphere.com/paper/1704.01544/full.md

---
Source: https://tomesphere.com/paper/1704.01544