skip to main content
10.1145/2889443.2889457acmotherconferencesArticle/Chapter ViewAbstractPublication PagesmodularityConference Proceedingsconference-collections
research-article

Matriona: class nesting with parameterization in Squeak/Smalltalk

Published:14 March 2016Publication History

ABSTRACT

We present Matriona, a module system for Squeak, a Smalltalk dialect. It supports class nesting and parameterization and is based on a hierarchical name lookup mechanism. Matriona solves a range of modularity issues in Squeak. Instead of a flat class organization, it provides a hierarchical namespace, that avoids name clashes and allows for shorter local names. Furthermore, it provides a way to share behavior among classes and modules using mixins and class hierarchy inheritance (a form of inheritance that subclasses an entire class family), respectively. Finally, it allows modules to be externally configurable, which is a form of dependency management decoupling a module from the actual implementation of its dependencies. Matriona is implemented on top of Squeak by introducing a new keyword for run-time name lookups through a reflective mechanism, without modifying the underlying virtual machine. We evaluate Matriona with a series of small applications and will demonstrate how its features can benefit modularity when porting a simple application written in plain Squeak to Matriona.

References

  1. O. Agesen, S. N. Freund, and J. C. Mitchell. Adding Type Parameterization to the Java Language. OOPSLA ’97, pages 49–65. ACM, 1997. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. E. Allen, J. Bannet, and R. Cartwright. A First-class Approach to Genericity. OOPSLA ’03, pages 96–114. ACM, 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. D. Ancona, G. Lagorio, and E. Zucca. Jam - A Smooth Extension of Java with Mixins. In ECOOP ’00, volume 1850 of LNCS, pages 154–178. Springer, 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. I. Aracic, V. Gasiunas, M. Mezini, and K. Ostermann. An Overview of CaesarJ. In Transactions on Aspect-Oriented Software Development I, volume 3880 of LNCS, pages 135– 173. Springer, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. K. Barrett, B. Cassels, P. Haahr, D. A. Moon, K. Playford, and P. T. Withington. A Monotonic Superclass Linearization for Dylan. OOPSLA ’96, pages 69–82. ACM, 1996. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. D. Batory, R. Cardone, and Y. Smaragdakis. Object-oriented Framework and Product Lines. SPLC1, pages 227–247. Kluwer Academic Publishers, 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. K. Beck and W. Cunningham. A Laboratory for Teaching Object Oriented Thinking. OOPSLA ’89, pages 1–6. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. J. Bloch. Effective Java (The Java Series). Prentice Hall PTR, Upper Saddle River, NJ, USA, 2nd edition, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. V. Bono, A. Patel, and V. Shmatikov. A Core Calculus of Classes and Mixins. In ECOOP ’99, volume 1628 of LNCS, pages 43–66. Springer, 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. G. Bracha. Inheriting Class. http://gbracha.blogspot.jp/ 2013/01/inheriting-class.html. Accessed: 2015-08-09.Google ScholarGoogle Scholar
  11. G. Bracha. The Programming Language Jigsaw: Mixins, Modularity and Multiple Inheritance. PhD thesis, The University of Utah, 1992. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. G. Bracha. On the Interaction of Method Lookup and Scope with Inheritance and Nesting. DYLA ’07, 2007.Google ScholarGoogle Scholar
  13. G. Bracha and W. Cook. Mixin-based Inheritance. OOPSLA/ECOOP ’90, pages 303–311. ACM, 1990. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. G. Bracha, P. von der Ahé, V. Bykov, Y. Kashai, W. Maddox, and E. Miranda. Modules as Objects in Newspeak. In ECOOP ’10, volume 6183 of LNCS, pages 405–428. Springer, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. Cincom Systems Inc. Cincom Smalltalk – Application Developer’s Guide. 2009.Google ScholarGoogle Scholar
  16. M. Dixon-Kennedy. Encyclopedia of Russian and Slavic Myth and Legend. ABC-CLIO, 1998.Google ScholarGoogle Scholar
  17. E. Ernst, K. Ostermann, and W. R. Cook. A Virtual Class Calculus. POPL ’06, pages 270–282. ACM, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. M. Flatt, S. Krishnamurthi, and M. Felleisen. Classes and Mixins. POPL ’98, pages 171–183. ACM, 1998. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. E. Gamma, R. Helm, R. Johnson, and J. Vlissides. Design Patterns: Elements of Reusable Object-oriented Software. Addison-Wesley Longman Publishing Co., Inc., Boston, MA, USA, 1995. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. A. Goldberg and D. Robson. Smalltalk-80: The Language and Its Implementation. Addison-Wesley Longman Publishing Co., Inc., Boston, MA, USA, 1983. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. M. J. Guzdial and K. M. Rose. Squeak: Open Personal Computing and Multimedia. Prentice Hall PTR, Upper Saddle River, NJ, USA, 1st edition, 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. R. Hirschfeld, P. Costanza, and O. Nierstrasz. Context-Oriented Programming. Journal of Object Technology, March-April 2008, ETH Zurich, 7(3):125–151, 2008.Google ScholarGoogle ScholarCross RefCross Ref
  23. D. H. Ingalls. Design Principles Behind Smalltalk. BYTE Magazine, 6(8):286–298, Aug. 1981.Google ScholarGoogle Scholar
  24. T. Kamina and T. Tamai. McJava – A Design and Implementation of Java with Mixin-Types. In Programming Languages and Systems, volume 3302 of LNCS, pages 398–414. Springer, 2004.Google ScholarGoogle Scholar
  25. O. L. Madsen. Semantic Analysis of Virtual Classes and Nested Classes. OOPSLA ’99, pages 114–131. ACM, 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. O. L. Madsen, B. Mø-Pedersen, and K. Nygaard. Objectoriented Programming in the BETA Programming Language. ACM Press/ Addison-Wesley Publishing Co., 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  27. O. L. Madsen and B. Moller-Pedersen. Virtual Classes: A Powerful Mechanism in Object-oriented Programming. OOPSLA ’89, pages 397–406. ACM, 1989. Google ScholarGoogle ScholarDigital LibraryDigital Library
  28. J. H. Maloney and R. B. Smith. Directness and Liveness in the Morphic User Interface Construction Environment. UIST ’95, pages 21–28. ACM, 1995. Google ScholarGoogle ScholarDigital LibraryDigital Library
  29. B. Meyer. Object-Oriented Software Construction. Prentice-Hall, Inc., Upper Saddle River, NJ, USA, 1st edition, 1988. Google ScholarGoogle ScholarDigital LibraryDigital Library
  30. O. Nierstrasz and T. Gîrba. Lessons in Software Evolution Learned by Listening to Smalltalk. In SOFSEM 2010: Theory and Practice of Computer Science, volume 5901 of LNCS, pages 77–95. Springer, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  31. J. Niño. The Cost of Erasure in Java Generics Type System. Journal of Computing Sciences in Colleges, 22(5):2–11, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  32. N. Nystrom, S. Chong, and A. C. Myers. Scalable Extensibility via Nested Inheritance. OOPSLA ’04, pages 99–115. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  33. M. Odersky and al. An Overview of the Scala Programming Language. Technical Report IC/2004/64, EPFL Lausanne, Switzerland, 2004.Google ScholarGoogle Scholar
  34. P. Pirkelbauer, S. Parent, M. Marcus, and B. Stroustrup. Runtime Concepts for the C++ Standard Template Library. SAC ’08, pages 171–177. ACM, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  35. N. Schärli, S. Ducasse, O. Nierstrasz, and A. Black. Traits: Composable Units of Behaviour. In ECOOP ’03, volume 2743 of LNCS, pages 248–274. Springer, 2003.Google ScholarGoogle Scholar
  36. Y. Smaragdakis and D. Batory. Mixin-Based Programming in C++. In Generative and Component-Based Software Engineering, volume 2177 of LNCS, pages 164–178. Springer, 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library
  37. Y. Smaragdakis and D. S. Batory. Implementing Layered Designs with Mixin Layers. ECOOP ’98, pages 550–570. Springer, 1998. Google ScholarGoogle ScholarDigital LibraryDigital Library
  38. B. Stroustrup. The C++ Programming Language. Addison-Wesley Longman Publishing Co., Inc., Boston, MA, USA, 3rd edition, 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  39. M. Taeumel, B. Steinert, and R. Hirschfeld. The VIVIDE Programming Environment: Connecting Run-time Information with Programmers’ System Knowledge. Onward! 2012, pages 117–126. ACM, 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  40. D. Thomas, C. Fowler, and A. Hunt. Programming Ruby 1.9: The Pragmatic Programmers’ Guide. Pragmatic Bookshelf, 3rd edition, 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  41. K. Thorup. Genericity in Java with Virtual Types. In ECOOP ’97, volume 1241 of LNCS, pages 444–471. Springer, 1997.Google ScholarGoogle Scholar
  42. T. L. Veldhuizen. C++ Templates as Partial Evaluation. PEPM ’98, pages 13–18. ACM, 1999.Google ScholarGoogle Scholar

Index Terms

  1. Matriona: class nesting with parameterization in Squeak/Smalltalk

    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
    • Published in

      cover image ACM Other conferences
      MODULARITY 2016: Proceedings of the 15th International Conference on Modularity
      March 2016
      145 pages
      ISBN:9781450339957
      DOI:10.1145/2889443

      Copyright © 2016 ACM

      Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than the author(s) must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected].

      Publisher

      Association for Computing Machinery

      New York, NY, United States

      Publication History

      • Published: 14 March 2016

      Permissions

      Request permissions about this article.

      Request Permissions

      Check for updates

      Qualifiers

      • research-article

      Acceptance Rates

      Overall Acceptance Rate41of139submissions,29%

    PDF Format

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader