skip to main content
10.1145/1297027.1297037acmconferencesArticle/Chapter ViewAbstractPublication PagessplashConference Proceedingsconference-collections
Article

Variant path types for scalable extensibility

Published:21 October 2007Publication History

ABSTRACT

Much recent work in the design of object-oriented programming languages has been focusing on identifying suitable features to support so-called scalable extensibility, where the usual extension mechanism by inheritance works in different scales of software components-that is, classes, groups of classes, groups of groups and so on. Its typing issues has usually been addressed by means of dependent type systems, where nested types are seen as properties of objects. In this work, we seek instead for a different solution, which can bemore easily applied to Java-like languages, in which nested types are considered properties of classe.

We introduce the mechanism of variant path types, which provide a flexible means to express intra-group relationship (among classes) that has to be preserved through extension. In particular, improving and extending existing works on groups and exact types, we feature the new notions of exact and inexact qualifications, providing rich abstractions to express various kinds of set of objects, with a flexible subtyping scheme. We formalize a safe type system for variant path types on top of Feather weight Java. Our development results in a complete solution for scalable extensibility, similarly to previous attempts based on dependent type systems.

References

  1. David Aspinall and Martin Hofmann. Dependent types. In Benjamin C. Pierce, editor, Advanced Topics in Types and Programming Languages, chapter 2, pages 45--86. The MIT Press, 2005.Google ScholarGoogle Scholar
  2. Kim B. Bruce. A paradigmatic object-oriented programming language: Design, static typing and semantics. Journal of Functional Programming, 4(2):127--206, April 1994. Preliminary version in POPL 1993, under the title ``Safe type checking in a statically typed object-oriented programming language''.Google ScholarGoogle ScholarCross RefCross Ref
  3. Kim B. Bruce. Some challenging typing issues in object-oriented languages. In Proceedings of Workshop on Object-Oriented Development (WOOD'03), volume 82 of Electronic Notes in Theoretical Computer Science, 2003.Google ScholarGoogle ScholarCross RefCross Ref
  4. Kim B. Bruce and J. Nathan Foster. LOOJ: Weaving LOOM into Java. In Proceedings of European Conference on Object-Oriented Programming (ECOOP2004), volume 3086 of Lecture Notes on Computer Science, Oslo, Norway, June 2004. Springer Verlag.Google ScholarGoogle ScholarCross RefCross Ref
  5. Kim B. Bruce, Martin Odersky, and Philip Wadler. A statically safe alternative to virtual types. In Proceedings of 12th European Conference on Object-Oriented Programming (ECOOP'98), volume 1445 of Lecture Notes on Computer Science, pages 523--549, Brussels, Belgium, July 1998. Springer Verlag. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. Kim B. Bruce, Leaf Petersen, and Adrian Fiech. Subtyping is not a good ``match'' for object-oriented languages. In Proceedings of 11th European Conference on Object-Oriented Programming (ECOOP'97), volume 1241 of Lecture Notes on Computer Science, pages 104--127, Jyväskylä, Finland, June 1997. Springer Verlag.Google ScholarGoogle ScholarCross RefCross Ref
  7. Kim B. Bruce, Angela Schuett, and Robert van Gent. PolyTOIL: A type-safe polymorphic object-oriented language. In WOlthoff, editor, Proceedings of 9th European Conference on Object-Oriented Programming (ECOOP'95), volume 952 of Lecture Notes on Computer Science, pages 27--51, Aarhus, Denmark, August 1995. Springer Verlag. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. Kim B. Bruce and Joseph C. Vanderwaart. Semantics-driven language design: Statically type-safe virtual types in object-oriented languages. In Proceedings of 15th Conference on the Mathematical Foundations of Programming Semantics (MFPS XV), volume 20 of Electronic Notes in Theoretical Computer Science, New Orleans, LA, April 1999. Elsevier. Available through http://www.elsevier.nl/locate/entcs/volume20.html.Google ScholarGoogle Scholar
  9. Dave Clarke, Sophia Drossopoulou, James Noble, and Tobias Wrigstad. Tribe: A simple virtual class calculus. In Proceedings of International Conference on Aspect-Oriented Software Design (AOSD'07), pages 121--134, Vancouver, BC, March 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. Vincent Cremet, François Garillot, Sergueï Lenglet, and Martin Odersky. A core calculus for Scala type checking. In Proceedings of International Symposium on Mathematical Foundations of Computer Science, Springer LNCS, pages 1--23, September 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. Erik Ernst. Propagating class and method combination. In Proceedings of European Conference on Object-Oriented Programming (ECOOP'99), volume 1628 of Lecture Notes on Computer Science, pages 67--91, Lisboa, Portugal, June 1999. Springer Verlag. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. Erik Ernst. Family polymorphism. In Proceedings of European Conference on Object-Oriented Programming (ECOOP2001), volume 2072 of Lecture Notes on Computer Science, pages 303--326, Budapest, Hungary, June 2001. Springer Verlag. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. Erik Ernst. Higher-order hierarchies. In Proceedings of European Conference on Object-Oriented Programming (ECOOP2003), volume 2743 of Lecture Notes on Computer Science, pages 303--328, Darmstadt, Germany, July 2003. Springer Verlag.Google ScholarGoogle ScholarCross RefCross Ref
  14. Erik Ernst, Klaus Ostermann, and William R. Cook. A virtual class calculus. In Proceedings of ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages (POPL2006), pages 270--282, Charleston, SC, January 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. James Gosling, Bill Joy, Guy Steele, and Gilad Bracha. The Java Language Specification. Addison-Wesley, third edition, June 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. Atsushi Igarashi and Benjamin C. Pierce. On inner classes. Information and Computation, 177(1):56--89, August 2002. A special issue with papers from the 7th International Workshop on Foundations of Object-Oriented Languages (FOOL7). An earlier version appeared in Proceedings of the 14th European Conference on Object-Oriented Programming, Springer LNCS 1850, pages 129--153, June, 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. Atsushi Igarashi, Benjamin C. Pierce, and Philip Wadler. Featherweight Java: A minimal core calculus for Java and GJ. ACM Transactions on Programming Languages and Systems, 23(3):396--450, May 2001. A preliminary summary appeared in Proceedings of the ACM Conference on Object-Oriented Programming, Systems, Languages, and Applications (OOPSLA'99), ACM SIGPLAN Notices, volume 34, number 10, pages 132--146, October 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. Atsushi Igarashi and Mirko Viroli. Variant parametric types: A flexible subtyping scheme for generics. ACM Transactions on Programming Languages and Systems, 28(5):795--847, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. Atsushi Igarashi and Mirko Viroli. Variant path types for scalable extensibility. In Informal Proceedings of the International Workshop on Foundations and Development of Object-Oriented Languages (FOOL/WOOD 2007), Nice, France, January 2007. Available at http://foolwood07.cs.uchicago.edu/accepted.html. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. Paul Jolly, Sophia Drossopoulou, Christopher Anderson, and Klaus Ostermann. Simple dependent types: Concord. In Proceedings of 6th ECOOP Workshop on Formal Techniques for Java-like Programs (FTfJP2004), June 2004.Google ScholarGoogle Scholar
  21. Ole Lehrmann Madsen and Birger Møller-Pedersen. Virtual classes: A powerful mechanism in object-oriented programming. In Proceedings of ACM Conference on Object-Oriented Programming, Systems, Languages, and Applications (OOPSLA'89), pages 397--406, October 1989. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. Ole Lehrmann Madsen, Birger Møller-Pedersen, and Kristen Nygaard. Object-Oriented Programming in the BETA Programming Language. Addison Wesley, 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. Mira Mezini and Klaus Ostermann. Conquering aspects with Caesar. In Proceedings of International Conference on Aspect-Oriented Software Design (AOSD'03), pages 90--99. ACM, 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  24. John C. Mitchell and Gordon D. Plotkin. Abstract types have existential types. ACM Transactions on Programming Languages and Systems, 10(3):470--502, 1988. Preliminary version appeared in Proc. of the 12th ACM POPL, 1985. Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. Nathaniel Nystrom, Stephen Chong, and Andrew C. Myers. Scalable extensibility via nested inheritance. In Proceedings of ACM Conference on Object-Oriented Programming, Systems, Languages, and Applications (OOPSLA'04), pages 99--115, Vancouver, BC, October 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. Nathaniel Nystrom, Xin Qi, and Andrew C. Myers. J&: Nested intersection for scalable software composition. In Proceedings of ACM Conference on Object-Oriented Programming, Systems, Languages, and Applications (OOPSLA'06), pages 21--36, Portland, OR, October 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  27. Martin Odersky, Vincent Cremet, Christine Röckl, and Matthias Zenger. A nominal theory of objects with dependent types. In Luca Cardelli, editor, Proceedings of European Conference on Object-Oriented Programming (ECOOP'03), volume 2743 of Lecture Notes on Computer Science, pages 201--224, Darmstadt, Germany, July 2003. Springer Verlag.Google ScholarGoogle Scholar
  28. Martin Odersky and Matthias Zenger. Scalable component abstraction. In Proceedings of ACM Conference on Object-Oriented Programming, Systems, Languages, and Applications (OOPSLA'05), pages 41--57, San Diego, CA, October 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  29. Chieri Saito, Atsushi Igarashi, and Mirko Viroli. Lightweight family polymorphism. Journal of Functional Programming, 2007. To appear. A preliminary summary appeared in Proceedings of the 3rd Asian Symposium on Programming Languages and Systems, Springer LNCS vol. 3780, pages 161--177, November, 2005.Google ScholarGoogle Scholar
  30. Yannis Smaragdakis and Don S. Batory. Implementing layered designs with mixin layers. In Proceedings of 12th European Conference on Object-Oriented Programming (ECOOP'98), volume 1445 of Lecture Notes on Computer Science, pages 550--570, Brussels, Belgium, July 1998. Springer Verlag. Google ScholarGoogle ScholarDigital LibraryDigital Library
  31. Mads Torgersen. The expression problem revisited: Four new solutions using generics. In Proceedings of European Conference on Object-Oriented Programming (ECOOP2004), volume 3086 of Lecture Notes on Computer Science, pages 123--146, Oslo, Norway, June 2004.Google ScholarGoogle Scholar
  32. Mads Torgersen, Erik Ernst, Christian Plesner Hansen, Peter von der Ahé, Gilad Bracha, and Neal Gafter. Adding wildcards to the Java programming language. Journal of Object Technology, 3(11), December 2004. Special issue: OOPS track at SAC 2004, pp. 97--116.Google ScholarGoogle ScholarCross RefCross Ref
  33. Andrew K. Wright and Matthias Felleisen. A syntactic approach to type soundness. Information and Computation, 115(1):38--94, November 1994. Google ScholarGoogle ScholarDigital LibraryDigital Library
  34. Matthias Zenger and Martin Odersky. Independently extensible solutions to the expression problem. Technical Report IC/2004/33, École Polytechnique Fédérale de Lausanne, Lausanne, Switzerland, March 2004.Google ScholarGoogle Scholar

Index Terms

  1. Variant path types for scalable extensibility

                Recommendations

                Comments

                Login options

                Check if you have access through your login credentials or your institution to get full access on this article.

                Sign in

                PDF Format

                View or Download as a PDF file.

                PDF

                eReader

                View online with eReader.

                eReader
                About Cookies On This Site

                We use cookies to ensure that we give you the best experience on our website.

                Learn more

                Got it!