ICSE 2025
Sat 26 April - Sun 4 May 2025 Ottawa, Ontario, Canada

Developers spend most of their time reading code. Previous studies have shown that less understandable code hinders developers’ productivity, making reading and debugging code harder and raising maintenance costs. In this research, we investigate how Atoms of Confusion (AoCs)–a set of low-level programming idioms for C-like languages proposed as a potential source of code confusion–can affect program comprehension and code quality. Specifically, we investigate (1) the impact of AoCs in the Open-Source Software (OSS) development community with Mining Software Repository (MSR) techniques, (2) how developers perceive how AoCs can affect comprehension, and (3) how Large Language Models (LLMs) can be used to refactor AoCs when appropriate. To this end, our preliminary study explores the defect-proneness of AoCs in open-source Java projects. We discovered that AoCs generally did not affect defect-proneness in opensource Java projects, but future works are needed to investigate how developers interact with AoCs under various circumstances, such as different projects and programming languages. As our next steps, we aim to gather developers’ perceptions of AoCs by conducting developer surveys. Next, based on these empirical findings, we will study how to LLMs can help refactor AoCs according to specific contexts such as developer experience and project convention. We expect this work will offer insights for researchers seeking to understand cognitive challenges in coding and practitioners looking to implement more effective strategies for enhancing code understandability and maintainability.