Clones: what is that smell?
Title | Clones: what is that smell? |
Publication Type | Journal Article |
Year of Publication | 2012 |
Authors | Rahman, F, Bird, C, Devanbu, P |
Secondary Title | Empirical Software Engineering |
Volume | 17 |
Issue | 4-5 |
Pagination | 503 - 530 |
Date Published | 8/2012 |
ISSN Number | 1573-7616 |
Abstract | Clones are generally considered bad programming practice in software engineering folklore. They are identified as a bad smell (Fowler et al. 1999) and a major contributor to project maintenance difficulties. Clones inherently cause code bloat, thus increasing project size and maintenance costs. In this work, we try to validate the conventional wisdom empirically to see whether cloning makes code more defect prone. This paper analyses the relationship between cloning and defect proneness. For the four medium to large open source projects that we studied, we find that, first, the great majority of bugs are not significantly associated with clones. Second, we find that clones may be less defect prone than non-cloned code. Third, we find little evidence that clones with more copies are actually more error prone. Fourth, we find little evidence to support the claim that clone groups that span more than one file or directory are more defect prone than collocated clones. Finally, we find that developers do not need to put a disproportionately higher effort to fix clone dense bugs. Our findings do not support the claim that clones are really a “bad smell” (Fowler et al. 1999). Perhaps we can clone, and breathe easily, at the same time. |
DOI | 10.1007/s10664-011-9195-3 |
Short Title | Empir Software Eng |
Full Text |
- Log in or register to post comments
- Google Scholar
- DOI
- BibTeX
- Tagged
- EndNote XML