Abstract
We show that many different overriding operators present in programming languages can be expressed, adopting a mixin-based framework, in terms of three basic operators. In particular we propose two orthogonal classifications: strong (the overridden definition is canceled) or weak (the overridden definition still remains significant, as in Smalltalk's super feature), and preferential (priority to one of the two arguments) or general. We formalize the relation between all these versions. Our analysis and results are not bound to a particular language, since they are formulated within an algebraic framework for mixin modules which can be instantiated over different core languages.
This work has been partially supported by Murst 40% — Modelli della computazione e dei linguaggi di programmazione and CNR — Formalismi per la specifica e la descrizione di sistemi ad oggetti.
Chapter PDF
References
D. Ancona and E. Zucca. An algebraic approach to mixins and modularity. In M. Hanus and M. Rodriguez Artalejo, editors, ALP '96 — 5th Intl. Conf. on Algebraic and Logic Programming, number 1139 in Lecture Notes in Computer Science, pages 179–193, Berlin, 1996. Springer Verlag.
D. Ancona and E. Zucca. A theory of mixin modules: basic and derived operators. Technical Report DISI-TR-96-24, DISI, University of Genova, 1996. Submitted for publication.
G. Bracha. The Programming Language JIGSAW: Mixins, Modularity and Multiple Inheritance. PhD thesis, Department of Comp. Sci., Univ. of Utah, 1992.
G. Bracha and W. Cook. Mixin-based inheritance. In Proc. of the Joint ACM Conf. on Object-Oriented Programming, Systems, Languages and Applications and the European Conference on Object-Oriented Programming, October 1990.
G. Bracha and G. Lindstrom. Modularity meets inheritance. In Proc. International Conference on Computer Languages, pages 282–290, San Francisco, April 1992. IEEE Computer Society.
W.R. Cook. A Denotational Semantics of Inheritance. PhD thesis, Dept. of Computer Science, Brown University, 1989.
D. Duggan and C. Sourelis. Mixin modules. In Intl. Conf. on Functional Programming, Philadelphia, May 1996. ACM Press.
J. A. Goguen and R. Burstall. Institutions: abstract model theory for specification and programming. Journ. ACM, 39(1):95–146, 1992.
A. Goldberg and D. Robson. Smalltalk-80: the Language and Its Implementation. Addison-Wesley, 1983.
M. Van Limberghen and T. Mens. Encapsulation and composition as orthogonal operators on mixins: a solution to multiple inheritance problems. Object Oriented Systems, 3:1–30, 1996.
O. L. Madsen, B. Møller-Pedersen, and K. Nygaard. Object-oriented programming in the Beta programming language. Addison-Wesley, 1993.
B. Meyer. Object-oriented Software Construction. Computer Science series. Prentice Hall, 1988.
R. Milner, M. Tofte, and R. Harper. The Definition of Standard ML. The MIT Press, Cambridge, Massachussetts, 1990.
Author information
Authors and Affiliations
Editor information
Rights and permissions
Copyright information
© 1997 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Ancona, D., Zucca, E. (1997). Overriding operators in a mixin-based framework. In: Glaser, H., Hartel, P., Kuchen, H. (eds) Programming Languages: Implementations, Logics, and Programs. PLILP 1997. Lecture Notes in Computer Science, vol 1292. Springer, Berlin, Heidelberg. https://doi.org/10.1007/BFb0033836
Download citation
DOI: https://doi.org/10.1007/BFb0033836
Published:
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-63398-3
Online ISBN: 978-3-540-69537-0
eBook Packages: Springer Book Archive