When Code Smells Twice as Much: Metric-Based Detection of Variability-Aware Code Smells

被引:0
|
作者
Fenske, Wolfram [1 ]
Schulze, Sandro [2 ]
Meyer, Daniel [1 ]
Saake, Gunter [1 ]
机构
[1] Univ Magdeburg, D-39106 Magdeburg, Germany
[2] TU Braunschweig, Braunschweig, Germany
来源
2015 IEEE 15TH INTERNATIONAL WORKING CONFERENCE ON SOURCE CODE ANALYSIS AND MANIPULATION (SCAM) | 2015年
关键词
IMPACT;
D O I
暂无
中图分类号
TP [自动化技术、计算机技术];
学科分类号
0812 ;
摘要
Code smells are established, widely used characterizations of shortcomings in design and implementation of software systems. As such, they have been subject to intensive research regarding their detection and impact on understandability and changeability of source code. However, current methods do not support highly configurable software systems, that is, systems that can be customized to fit a wide range of requirements or platforms. Such systems commonly owe their configurability to conditional compilation based on C preprocessor annotations (a. k. a. #ifdefs). Since annotations directly interact with the host language (e.g., C), they may have adverse effects on understandability and changeability of source code, referred to as variability-aware code smells. In this paper, we propose a metric-based method that integrates source code and C preprocessor annotations to detect such smells. We evaluate our method for one specific smell on five open-source systems of medium size, thus, demonstrating its general applicability. Moreover, we manually reviewed 100 instances of the smell and provide a qualitative analysis of its potential impact as well as common causes for the occurrence.
引用
收藏
页码:171 / 180
页数:10
相关论文
共 7 条
  • [1] On the Assessment of Interactive Detection of Code Smells in Practice: A Controlled Experiment
    Albuquerque, Danyllo
    Guimaraes, Everton
    Perkusich, Mirko
    Rique, Thiago
    Cunha, Felipe
    Almeida, Hyggo
    Perkusich, Angelo
    IEEE ACCESS, 2023, 11 : 84589 - 84606
  • [2] Code smells detection via modern code review: a study of the OpenStack and Qt communities
    Han, Xiaofeng
    Tahir, Amjed
    Liang, Peng
    Counsell, Steve
    Blincoe, Kelly
    Li, Bing
    Luo, Yajing
    EMPIRICAL SOFTWARE ENGINEERING, 2022, 27 (06)
  • [3] Understanding metric-based detectable smells in Python']Python software: A comparative study
    Chen Zhifei
    Chen Lin
    Ma Wanwangying
    Zhou Xiaoyu
    Zhou Yuming
    Xu Baowen
    INFORMATION AND SOFTWARE TECHNOLOGY, 2018, 94 : 14 - 29
  • [4] Lightweight Detection of Android-Specific Code Smells: The aDoctor Project
    Palomba, Fabio
    Di Nucci, Dario
    Panichella, Annibale
    Zaidman, Andy
    De Lucia, Andrea
    2017 IEEE 24TH INTERNATIONAL CONFERENCE ON SOFTWARE ANALYSIS, EVOLUTION, AND REENGINEERING (SANER), 2017, : 487 - 491
  • [5] Automatic detection of Long Method and God Class code smells through neural source code embeddings
    Kovacevic, Aleksandar
    Slivka, Jelena
    Vidakovic, Dragan
    Grujic, Katarina-Glorija
    Luburic, Nikola
    Prokic, Simona
    Sladic, Goran
    EXPERT SYSTEMS WITH APPLICATIONS, 2022, 204
  • [6] Comparing Heuristic and Machine Learning Approaches for Metric-Based Code Smell Detection
    Pecorelli, Fabiano
    Palomba, Fabio
    Di Nucci, Dario
    De Lucia, Andrea
    2019 IEEE/ACM 27TH INTERNATIONAL CONFERENCE ON PROGRAM COMPREHENSION (ICPC 2019), 2019, : 93 - 104
  • [7] When and Why Your Code Starts to Smell Bad (and Whether the Smells Go Away)
    Tufano, Michele
    Palomba, Fabio
    Bavota, Gabriele
    Oliveto, Rocco
    Di Penta, Massimiliano
    De Lucia, Andrea
    Poshyvanyk, Denys
    IEEE TRANSACTIONS ON SOFTWARE ENGINEERING, 2017, 43 (11) : 1063 - 1088