D. Maley et al., THE FORMAL SPECIFICATION OF ABSTRACT-DATA-TYPES AND THEIR IMPLEMENTATION IN FORTRAN-90 - IMPLEMENTATION ISSUES CONCERNING THE USE OF POINTERS, Computer physics communications, 98(1-2), 1996, pp. 167-180
In this paper we continue our investigation into the development of co
mputational-science software based on the identification and formal sp
ecification of Abstract Data Types (ADTs) and their implementation in
Fortran 90. In particular, we consider the consequences of using point
ers when implementing a formally specified ADT in Fortran 90. Our aim
is to highlight the resulting conflict between the goal of information
hiding, which is central to the ADT methodology, and the space effici
ency of the implementation. We show that the issue of storage recovery
cannot be avoided by the ADT user, and present a range of implementat
ions of a simple ADT to illustrate various approaches towards satisfac
tory storage management. Finally, we propose a set of guidelines for i
mplementing ADTs using pointers in Fortran 90. These guidelines offer
a way gracefully to provide disposal operations in Fortran 90. Such an
approach is desirable since Fortran 90 does not provide automatic gar
bage collection which is offered by many object-oriented languages inc
luding Eiffel, Java, Smalltalk, and Simula.