Class specialization is undoubtedly one of the most original and powerful
features of object orientation. It underlies many research topics---such
as
inheritance, classification or subtyping---and it structures object
models at
all stages of software development. Unfortunately, the semantics of
specialization is not defined with the same accuracy in the various
fields.
In programming languages, specialization is constrained by type theory
and by
a type safe policy, whereas its common sense semantics dates back to
the
Aristotelian tradition. The well known covariant vs. contravariant
controversy originates here.
In this paper, we investigate how modeling and programming languages
deal with
this mismatch. We claim that type errors are part of the real world,
so they
should be taken into account at all stages of software development.
Analysis
and design methods, as well as programming languages should adopt a
covariant
policy.