Toward a novel taxonomy to capture code smells caused by refactoring

Mashail N. Alkhomsan*, Mohammad Alshayeb, Malak Baslyman

*Corresponding author for this work

Research output: Contribution to journalArticlepeer-review

1 Scopus citations

Abstract

Code smells tend to have an impact on software quality attributes such as reusability, maintainability, and understandability. These are code flaws that do not necessarily prevent the system from operating; rather, they increase the possibility of defects occurring in the future. Hence, to maintain code quality, code smells should be detected and corrected through refactoring. The objective of this paper is to investigate the associated risk of applying refactoring techniques and reveal the bad smells that may appear when fixing other bad smells. We conducted several controlled experiments to identify the smells that emerge after refactoring. The experiments resulted in a novel taxonomy revealing 9 bad smells that may appear as a result of fixing other bad smells. This represents the first study attempting to systematically identify and organize such refactoring-smell relationships into a taxonomy. The research results can assist developers in relating different bad smells to each other and helping them determine the refactoring technique that should be applied when certain smells are present. Moreover, the results can be beneficial in breaking the cycle of bad smells. Such knowledge tends to enhance code refactoring, which in turn will improve software quality and avoid technical debt.

Original languageEnglish
Article number103120
JournalScience of Computer Programming
Volume236
DOIs
StatePublished - Sep 2024

Bibliographical note

Publisher Copyright:
© 2024 Elsevier B.V.

Keywords

  • Code smell
  • Maintainability
  • Refactoring
  • Refactoring sequence
  • Technical debt

ASJC Scopus subject areas

  • Software
  • Information Systems
  • Modeling and Simulation
  • Computational Theory and Mathematics

Fingerprint

Dive into the research topics of 'Toward a novel taxonomy to capture code smells caused by refactoring'. Together they form a unique fingerprint.

Cite this