Two controlled experiments concerning the usefulness of assertions as a means for programming

被引:5
作者
Müller, MM [1 ]
Typke, R [1 ]
Hagner, O [1 ]
机构
[1] Univ Karlsruhe, Fak Informat, Karlsruhe, Germany
来源
INTERNATIONAL CONFERENCE ON SOFTWARE MAINTENANCE, PROCEEDINGS | 2002年
关键词
D O I
10.1109/ICSM.2002.1167755
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
Assertions, or more generally "Programming by contract", have gained widespread acceptance in the computer science community as a means for correct program development. However the literature lacks an empirical evaluation of the benefits a programmer gains by using assertions in his software development. This paper reports two controlled experiments that close this gap. Both experiments compare "Programming by contract" to the traditional-programming style without assertions. The evaluation of the first experiment suggests that assertions decrease the programming effort for the extension of existing software, measured as time needed to finish tile task, while the programming effort slightly increases during the development of new code. The second experiment shows that the programming effort tended to be larger with assertions than without. In addition, it shows that the reliability of the written programs slightly increases with the usage of assertions compared to the programs written without assertions.
引用
收藏
页码:84 / 92
页数:9
相关论文
共 11 条
[1]  
CHRISTENSEN LB, 1994, EXPT METHODOLOGY
[2]  
Cohen J., 1998, Statistical Power Analysis for the Behavioral Sciences, V2nd
[3]  
GOLDSCHMIDT D, 1998, THESIS RENSSELAER PO
[4]  
HUMPHREY W, 1997, DISCIPLINE SOFTWARE
[5]  
McKim JC, 1996, J OBJECT-ORIENT PROG, V9, P70
[6]  
Meyer B., 1988, Object-Oriented Software Construction
[7]  
MULLER M, 2002, 20022 U KARLSR COMP
[8]  
ROSENBLUM D, APP
[9]  
Rosenblum D. S., 1992, International Conference on Software Engineering, P92, DOI 10.1145/143062.143098
[10]  
STORK J, 1999, THESIS U KARLSRUHE