首页> 外文会议>IEEE International Conference on Software Maintenance and Evolution >#ifdef Directives and Program Comprehension: The Dilemma between Correctness and Preference
【24h】

#ifdef Directives and Program Comprehension: The Dilemma between Correctness and Preference

机译:#ifdef指令和程序理解:正确性与偏好之间的困境

获取原文

摘要

Many organizations and open-source projects use the C preprocessor (CPP) to implement configurability in their software systems. Despite extensive research, existing studies on the effects of CPP use on program comprehension are still limited to experiences, opinions, and empirical studies with narrow scopes. So, it is unclear whether the CPP actually leads to what is sometimes referred to as "#ifdef hell." In this paper, we expand the existing evidence on program comprehension in the presence of CPP directives, but we also highlight a surprising dilemma. We conducted an empirical study, including an experiment and a questionnaire, on the impact of refactoring CPP directives with 521 experienced software developers. The results indicate that, in contrast to previous findings, comprehension performance slightly worsened in terms of correctness when our participants worked on code with refactored CPP directives. However, in alignment with previous findings, they preferred the refactored code, considering it more comprehensible and easier to work with. This dilemma of objective performance versus subjective preference is a surprising outcome that has not been found before. We argue that our work motivates the need for more studies to understand this dilemma—which may significantly impact common beliefs in research and practice.
机译:许多组织和开源项目都使用C预处理程序(CPP)在其软件系统中实现可配置性。尽管进行了广泛的研究,但有关CPP使用对程序理解的影响的现有研究仍仅限于经验,观点和范围狭窄的实证研究。因此,目前尚不清楚CPP是否真正导致了有时被称为“ #ifdef地狱”的事件。在本文中,我们在存在CPP指令的情况下扩展了有关程序理解的现有证据,但同时也突出了一个令人惊讶的难题。我们对521位经验丰富的软件开发人员进行了关于重构CPP指令的影响的实证研究,包括实验和问卷调查。结果表明,与以前的发现相比,当我们的参与者使用重构的CPP指令编写代码时,在正确性方面,理解性能略有下降。但是,与以前的发现一致,他们更喜欢重构的代码,因为它更易于理解且更易于使用。客观表现与主观偏好之间的两难选择是一个前所未有的令人惊讶的结果。我们认为,我们的工作促使人们需要进行更多的研究来理解这一难题,这可能会极大地影响人们对研究和实践的普遍信念。

著录项

相似文献

  • 外文文献
  • 中文文献
  • 专利
获取原文

客服邮箱:kefu@zhangqiaokeyan.com

京公网安备:11010802029741号 ICP备案号:京ICP备15016152号-6 六维联合信息科技 (北京) 有限公司©版权所有
  • 客服微信

  • 服务号