Abstract
Much recent work on proof-carrying code aims to build certifying compilers for single-inheritance object-oriented languages, such as Java or C#. Some modern object-oriented languages support compiling a derived class without complete information about its base class. This strategy—though necessary for supporting features such as mixins, traits, and first-class classes—is not well-supported by existing typed intermediate languages. We present a low-level IL with a type system based on the Calculus of Inductive Constructions. It is an appropriate target for efficient, type-preserving compilation of various forms of inheritance, even when the base class is unknown at compile time. Languages (such as Java) that do not require such flexibility are not penalized at run time.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
References
Appel, A.W.: Foundational proof-carrying code. In: Proc. IEEE Symp. on Logic in Computer Science (LICS), June 2001, pp. 247–258 (2001)
Barendregt, H.: Typed lambda calculi. In: Abramsky, S., Gabbay, D., Maibaum, T. (eds.) Handbook of Logic in Computer Science, Oxford, vol. 2 (1992)
Bracha, G., Cook, W.: Mixin-based inheritance. In: Proc. Conf. on Object-Oriented Programming Systems, Languages, and Applications, October 1990, pp. 303–311 (1990)
Bruce, K.B., Fiech, A., Petersen, L.: Subtyping is not a good ‘Match’ for object-oriented languages. In: Aksit, M., Matsuoka, S. (eds.) ECOOP 1997. LNCS, vol. 1241, pp. 104–127. Springer, Heidelberg (1997)
Bruce, K.B., Cardelli, L., Pierce, B.C.: Comparing object encodings. Information and Computation 155(1–2), 108–133 (1999)
Cardelli, L., Leroy, X.: Abstract types and the dot notation. In: Proc. IFIP Working Conf. on Programming Concepts and Methods, Israel, April 1990, pp. 466–491 (1990)
Cardelli, L., Mitchell, J.C.: Operations on records. In: Gunter, C.A., Mitchell, J.C. (eds.) Theoretical Aspects of Object-Oriented Programming. Foundations of Computing Series. MIT Press, Cambridge (1994)
Chang, B.-Y.E., Chlipala, A., Necula, G.C., Schneck, R.R.: Type-based verification of assembly language for compiler debugging. In: Proc. ACMWorkshop on Types in Language Design and Implementation (TLDI), pp. 91–102 (2005)
Chen, J., Tarditi, D.: A simple typed intermediate language for object-oriented languages. In: Proc. Symp. on Principles of Programming Languages. ACM, New York (2005)
Ciaffaglione, A., Liquori, L., Miculan, M.: Imperative object-based calculi in coinductive type theories. In: Y. Vardi, M., Voronkov, A. (eds.) LPAR 2003. LNCS, vol. 2850, pp. 59–77. Springer, Heidelberg (2003)
Colby, C., Lee, P., Necula, G.C., Blau, F., Cline, K., Plesko, M.: A certifying compiler for Java. In: Proc. Conf. on Programming Language Design and Implementation, Vancouver. ACM, New York (2000)
Coq Development Team. The Coq Proof Assistant Reference Manual. INRIA, version 8.0 edn. (June 2004)
Coquand, T., Huet, G.: The calculus of constructions. Information and Computation 76, 95–120 (1988)
Coquand, T., Paulin-Mohring, C.: Inductively defined types. In: Martin-Löf, P., Mints, G. (eds.) COLOG 1988. LNCS, vol. 417. Springer, Heidelberg (1990)
Crary, K.: Typed compilation of inclusive subtyping. In: Proc. Int’l Conf. Functional Programming (September 2000)
Crary, K.: Simple, efficient object encoding using intersection types. Technical Report CMU-CS-99-100, Carnegie Mellon University, Pittsburgh (January 1999)
Fisher, K., Reppy, J.: A typed calculus for traits. In: Proc. Int’l Workshop on Foundations of Object-Oriented Languages (January 2004)
Fisher, K., Reppy, J.: Foundations for moby classes. Technical report, Bell Labs (December 1998)
Fisher, K., Reppy, J.: The design of a class mechanism for Moby. In: Proc. Conf. on Programming Language Design and Implementation. ACM, New York (1999)
Fisher, K., Reppy, J., Riecke, J.G.: A calculus for compiling and linking classes. In: Proc. European Symp. on Programming, pp. 135–149 (2000)
Flanagan, C., Sabry, A., Duba, B.F., Felleisen, M.: The essence of compiling with continuations. In: Proc. Conf. on Programming Language Design and Implementation, Albuquerque, June 1993, pp. 237–247 (1993)
Glew, N.: An efficient class and object encoding. In: Proc. Conf. on Object-Oriented Programming Systems, Languages, and Applications. ACM, New York (2000)
Howard, W.A.: The formulae-as-types notion of constructions. In: To, H.B. (ed.) Curry: Essays on Computational Logic, Lambda Calculus, and Formalism. Academic Press, London (1980)
League, C., Monnier, S.: Typed compilation against non-manifest base classes. Extended version, available from authors’ web sites (December 2005)
League, C., Shao, Z., Trifonov, V.: Type- preserving compilation of Featherweight Java. ACM Trans. on Programming Languages and Systems 24(2), 112–152 (2002)
League, C., Shao, Z., Trifonov, V.: Precision in practice: A type-preserving Java compiler. In: Hedin, G. (ed.) CC 2003. LNCS, vol. 2622, pp. 106–120. Springer, Heidelberg (2003)
Moon, D.A.: Object-oriented programming with Flavors. In: Proc. Conf. on Object- Oriented Programming Systems, Languages, and Applications, November 1986, pp. 1–8 (1986)
Morrisett, G., Walker, D., Crary, K., Glew, N.: From System F to typed assembly language. ACM Trans. on Programming Languages and Systems 21(3) (May 1999)
Necula, G.C.: Proof-carrying code. In: Proc. Symp. on Principles of Programming Languages, Paris, pp. 106–119. ACM, New York (1997)
Pfenning, F., Elliot, C.: Higher-order abstract syntax. In: Proc. Conf. on Programming Language Design and Implementation, pp. 199–208 (1988)
Rémy, D., Vouillon, J.: Objective ML: An effective object-oriented extension to ML. Theory and Practice of Object Systems 4 (1998)
Schärli, N., Ducasse, S., Nierstrasz, O., Black, A.P.: Traits: Composable units of behaviour. In: Cardelli, L. (ed.) ECOOP 2003. LNCS, vol. 2743. Springer, Heidelberg (2003)
Shao, Z., Trifonov, V., Saha, B., Papaspyrou, N.: A type system for certified binarios. ACM Trans. on Programming Languages and Systems 27(1), 1–45 (2005)
Stone, C.A.: Extensible objects without labels. ACM Trans. on Programming Languages and Systems 26(5), 805–835 (2004)
Vanderwaart, J.C.: Typed intermediate representations for compiling object-oriented languages. Williams College Senior Honors Thesis (1999)
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2006 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
League, C., Monnier, S. (2006). Typed Compilation Against Non-manifest Base Classes. In: Barthe, G., Grégoire, B., Huisman, M., Lanet, JL. (eds) Construction and Analysis of Safe, Secure, and Interoperable Smart Devices. CASSIS 2005. Lecture Notes in Computer Science, vol 3956. Springer, Berlin, Heidelberg. https://doi.org/10.1007/11741060_5
Download citation
DOI: https://doi.org/10.1007/11741060_5
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-33689-1
Online ISBN: 978-3-540-33691-4
eBook Packages: Computer ScienceComputer Science (R0)