An empirical view of inheritance
For some years software engineering researchers have been advocating object-oriented (OO) methods as a powerful approach to overcome many of the difficulties associated with software development. A central concept within OO is the use of the inheritance mechanism, primarily with a view to enhancing opportunities for reuse. This paper reviews the evidence we have concerning the use and the impact of inheritance within OO software. A striking result is how little the mechanism is used in practice. The paper then goes onto describe an experiment conducted at Bournemouth University to investigate the impact of class inheritance upon the maintenance of C++ software. The experiment was a replication of an experiment previously conducted at the University of Strathclyde. Two versions of a bibliographic database program were used. One used inheritance and the other a flat structure. It was found that subjects took significantly longer to make the same change on the program with inheritance, however, their changes were more compact. Interestingly, the Strathclyde group found that the time to make changes for the inheritance version was reduced. We conclude that there is an urgent need for further empirical work to study the impact of the inheritance mechanism using more subjects and in an industrial setting.
inheritance empirical analysis experimentation object-orientation