This paper discusses the reuse of Ada code on two intermediate-sized applications--interactive debuggers and object managers. For the first application, code was reused across a family of similar debuggers that run on various target machines. For the second application, object manager code was reused within a single programming environment. In both cases, generics were the reuse mechanism.
The paper begins with an introduction, followed by an overview of the two applications. Next, the authors describe the software structure of each application as a series of layered components; they discuss the extent to which these layers incorporate reusable code. Then a programming environment that facilitated the development of the reusable code is described.
The final section of the paper provides several observations based on the authors’ experiences in developing the applications. They conclude that Ada generics are an effective mechanism for generating reusable modules, and note that no execution overhead problems were encountered with them. They also note the advantages of development environments that allow generic bodies to be recompiled without requiring recompilation of the units containing the instantiations. However, the Ada requirement to import individual subprograms rather than full abstractions often resulted in a large number of generic parameters, making the code somewhat cumbersome.
This paper describes interesting real-world experiences in the use of Ada generics. However, it would be even better if the authors limited themselves to either providing a description of the developed applications or discussing the lessons they learned. (I would prefer the latter, so that readers could apply the lessons on their own projects.) In attempting to do both, the authors do neither as well as they could have. For example, the descriptions of the application structures are too terse for easy comprehension, but too detailed for the reader who is interested in lessons learned. Similarly, the observations on the development experiences would be easier to understand if more text, perhaps with some examples, were devoted to them. Finally, the material in section 5 on the programming environment reads like an advertisement and should not have been included in the paper.
Even with its faults, this paper should prove of interest to Ada practitioners. It is well worth reading.