zbMATH — the first resource for mathematics

A behavioural approach to subtyping in object-oriented programming languages. (English) Zbl 0681.68010
Summary: It is argued that in object-oriented programming languages a distinction should be made between inheritance, considered as a mechanism by which classes can share code for variables and methods, and subtyping, which expresses specialization in functionality. In contrast to inheritance, subtyping should not be based on the internal structure of the objects and the code they execute, but on that part of their behaviour that can be observed by sending messages to them. A formalism is defined by which one can specify this behaviour, and on the basis of this formalism it is defined when a class implements a type and when one type is a subtype of another type. These definitions are illustrated by some concrete examples.

68N01 General topics in the theory of software
68N99 Theory of software
68P05 Data structures
CLOS; Smalltalk