devxlogo

Study: Code Refactoring Doesn’t Improve Quality

Study: Code Refactoring Doesn’t Improve Quality

A new study conducted by researchers in Sri Lanka has reached a startling conclusion: refactoring code doesn’t improve its quality. The report, titled “An Empirical Evaluation of Impact of Refactoring On Internal and External Measures of Code Quality,” applied common refactoring techniques to a small application. They then analyzed both the original and the refactored code using the Maintainability Index, Cyclomatic Complexity, Depth of Inheritance, Class Coupling, and Line of Code metrics in Visual Studio. They also asked computer science students to evaluate both versions.

The study found that the refactored code scored lower for analyzability, made bug fixes take longer and ran slower, although none of those difference were statistically significant. It also found no evidence that the refactored code consumed less memory than the original. The refactored code did score slightly higher on the Maintainability Index, but the difference was slight.

View article

devxblackblue

About Our Editorial Process

At DevX, we’re dedicated to tech entrepreneurship. Our team closely follows industry shifts, new products, AI breakthroughs, technology trends, and funding announcements. Articles undergo thorough editing to ensure accuracy and clarity, reflecting DevX’s style and supporting entrepreneurs in the tech sphere.

See our full editorial policy.

About Our Journalist