Endre søk
RefereraExporteraLink to record
Permanent link

Direct link
Referera
Referensformat
  • apa
  • ieee
  • modern-language-association-8th-edition
  • vancouver
  • Annet format
Fler format
Språk
  • de-DE
  • en-GB
  • en-US
  • fi-FI
  • nn-NO
  • nn-NB
  • sv-SE
  • Annet språk
Fler språk
Utmatningsformat
  • html
  • text
  • asciidoc
  • rtf
Understanding Code Understandability Improvements in Code Reviews
Univ Fed Pernambuco, BR-50732970 Recife, Brazil.;Fed Inst Pernambuco, BR-55540000 Palmares, Brazil..ORCID-id: 0000-0001-6815-9251
Univ Fed Pernambuco, BR-50732970 Recife, Brazil..
Univ Fed Pernambuco, BR-50732970 Recife, Brazil..ORCID-id: 0000-0002-6386-1591
KTH, Skolan för elektroteknik och datavetenskap (EECS), Datavetenskap, Teoretisk datalogi, TCS.ORCID-id: 0000-0003-3505-3383
Vise andre og tillknytning
2025 (engelsk)Inngår i: IEEE Transactions on Software Engineering, ISSN 0098-5589, E-ISSN 1939-3520, Vol. 51, nr 1, s. 14-37Artikkel i tidsskrift (Fagfellevurdert) Published
Abstract [en]

Context: Code understandability plays a crucial role in software development, as developers spend between 58% and 70% of their time reading source code. Improving code understandability can lead to enhanced productivity and save maintenance costs. Problem: Experimental studies aim to establish what makes code more or less understandable in a controlled setting, but ignore that what makes code easier to understand in the real world also depends on extraneous elements such as developers' background and project culture and guidelines. Not accounting for the influence of these factors may lead to results that are sound but have little external validity. Goal: We aim to investigate how developers improve code understandability during software development through code review comments. Our assumption is that code reviewers are specialists in code quality within a project. Method and Results: We manually analyzed 2,401 code review comments from Java open-source projects on GitHub and found that over 42% of all comments focus on improving code understandability, demonstrating the significance of this quality attribute in code reviews. We further explored a subset of 385 comments related to code understandability and identified eight categories of code understandability concerns, such as incomplete or inadequate code documentation, bad identifier, and unnecessary code. Among the suggestions to improve code understandability, 83.9% were accepted and integrated into the codebase. Among these, only two (less than 1%) ended up being reverted later. We also identified types of patches that improve code understandability, ranging from simple changes (e.g., removing unused code) to more context-dependent improvements (e.g., replacing method calling chains by existing API). Finally, we investigated the potential coverage of four well-known linters to flag the identified code understandability issues. These linters cover less than 30% of these issues, although some of them could be easily added as new rules. Implications: Our findings motivate and provide practical insight for the construction of tools to make code more understandable, e.g., understandability improvements are rarely reverted and thus can be used as reliable training data for specialized ML-based tools. This is also supported by our dataset, which can be used to train such models. Finally, our findings can also serve as a basis to develop evidence-based code style guides.

sted, utgiver, år, opplag, sider
Institute of Electrical and Electronics Engineers (IEEE) , 2025. Vol. 51, nr 1, s. 14-37
Emneord [en]
Codes, Reviews, Source coding, Software development management, Documentation, Security, Natural languages, Code understandability, code understandability smells, code review
HSV kategori
Identifikatorer
URN: urn:nbn:se:kth:diva-359532DOI: 10.1109/TSE.2024.3453783ISI: 001395714800006Scopus ID: 2-s2.0-85204075762OAI: oai:DiVA.org:kth-359532DiVA, id: diva2:1935311
Merknad

QC 20250206

Tilgjengelig fra: 2025-02-06 Laget: 2025-02-06 Sist oppdatert: 2025-02-06bibliografisk kontrollert

Open Access i DiVA

Fulltekst mangler i DiVA

Andre lenker

Forlagets fulltekstScopus

Person

Monperrus, Martin

Søk i DiVA

Av forfatter/redaktør
Oliveira, Delanode Oliveira, BeneditoMonperrus, Martin
Av organisasjonen
I samme tidsskrift
IEEE Transactions on Software Engineering

Søk utenfor DiVA

GoogleGoogle Scholar

doi
urn-nbn

Altmetric

doi
urn-nbn
Totalt: 78 treff
RefereraExporteraLink to record
Permanent link

Direct link
Referera
Referensformat
  • apa
  • ieee
  • modern-language-association-8th-edition
  • vancouver
  • Annet format
Fler format
Språk
  • de-DE
  • en-GB
  • en-US
  • fi-FI
  • nn-NO
  • nn-NB
  • sv-SE
  • Annet språk
Fler språk
Utmatningsformat
  • html
  • text
  • asciidoc
  • rtf