Recording concerns in source code using annotations

被引:20
|
作者
Sulir, Matus [1 ]
Nosal', Milan [1 ]
Poruban, Jaroslav [1 ]
机构
[1] Tech Univ Kosice, Fac Elect Engn & Informat, Dept Comp & Informat, Letna 9, Kosice 04200, Slovakia
关键词
Program comprehension; Concerns; Source code annotations; Empirical studies; SOFTWARE; MODEL;
D O I
10.1016/j.cl.2016.07.003
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
A concern can be characterized as a developer's intent behind a piece of code, often not explicitly captured in it. We discuss a technique of recording concerns using source code annotations (concern annotations). Using two studies and two controlled experiments, we seek to answer the following 3 research questions: (1) Do programmers' mental models overlap? (2) How do developers use shared concern annotations when they are available? (3) Does using annotations created by others improve program comprehension and maintenance correctness, time and confidence? The first study shows that developers' mental models, recorded using concern annotations, overlap and thus can be shared. The second study shows that shared concern annotations can be used during program comprehension for the following purposes: hypotheses confirmation, feature location, obtaining new knowledge, finding relationships and maintenance notes. The first controlled experiment with students showed that the presence of annotations significantly reduced program comprehension and maintenance time by 34%. The second controlled experiment was a differentiated replication of the first one, focused on industrial developers. It showed a 33% significant improvement in correctness. We conclude that concern annotations are a viable way to share developers' thoughts. (C) 2016 Elsevier Ltd. All rights reserved.
引用
收藏
页码:44 / 65
页数:22
相关论文
共 50 条
  • [1] Language Composition Using Source Code Annotations
    Nosal', Milan
    Sulir, Matus
    Juhar, Jan
    COMPUTER SCIENCE AND INFORMATION SYSTEMS, 2016, 13 (03) : 707 - 729
  • [2] Source Code Annotations as Formal Languages
    Nosal, Milan
    Sulir, Matus
    Juhar, Jan
    PROCEEDINGS OF THE 2015 FEDERATED CONFERENCE ON COMPUTER SCIENCE AND INFORMATION SYSTEMS, 2015, 5 : 953 - 964
  • [3] Representing concerns in source code
    Robillard, Martin P.
    Murphy, Gail C.
    ACM TRANSACTIONS ON SOFTWARE ENGINEERING AND METHODOLOGY, 2007, 16 (01)
  • [4] Co-evolving annotations and source code through smart annotations
    Software Languages Lab ., Vrije Universiteit Brussel, Pleinlaan 2, B-1050 Brussels, Belgium
    Proc. Eur. Conf. Software Maint. Reeng., (117-126):
  • [5] Co-evolving Annotations and Source Code through Smart Annotations
    Kellens, Andy
    Noguera, Carlos
    De Schutter, Kris
    De Roover, Coen
    D'Hondt, Theo
    14TH EUROPEAN CONFERENCE ON SOFTWARE MAINTENANCE AND REENGINEERING (CSMR 2010), 2010, : 117 - 126
  • [6] Software Documentation through Source Code Annotations
    Nosal, Milan
    Porubaen, Jaroslav
    INFORMATICS 2013: PROCEEDINGS OF THE TWELFTH INTERNATIONAL CONFERENCE ON INFORMATICS, 2013, : 180 - 185
  • [7] Using Annotations for Sensemaking About Code
    Horvath, Amber
    Myers, Brad A.
    Macvean, Andrew
    Rahman, Imtiaz
    PROCEEDINGS OF THE 35TH ANNUAL ACM SYMPOSIUM ON USER INTERFACE SOFTWARE AND TECHNOLOGY, UIST 2022, 2022,
  • [8] A representation for describing and analyzing concerns in source code
    Robillard, MP
    ICSE 2002: PROCEEDINGS OF THE 24TH INTERNATIONAL CONFERENCE ON SOFTWARE ENGINEERING, 2002, : 721 - 722
  • [9] Separation of Concerns and Concern Granularity in Source Code
    Juhar, Jan
    Vokorokos, Liberios
    2015 IEEE 13TH INTERNATIONAL SCIENTIFIC CONFERENCE ON INFORMATICS, 2015, : 139 - 144
  • [10] Sharing Developers' Mental Models through Source Code Annotations
    Sulir, Matus
    Nosal, Milan
    PROCEEDINGS OF THE 2015 FEDERATED CONFERENCE ON COMPUTER SCIENCE AND INFORMATION SYSTEMS, 2015, 5 : 997 - 1006