skip to main content
10.1145/1480881.1480926acmconferencesArticle/Chapter ViewAbstractPublication PagespoplConference Proceedingsconference-collections
research-article

Modeling abstract types in modules with open existential types

Published:21 January 2009Publication History

ABSTRACT

We propose F-zip, a calculus of open existential types that is an extension of System F obtained by decomposing the introduction and elimination of existential types into more atomic constructs. Open existential types model modular type abstraction as done in module systems. The static semantics of F-zip adapts standard techniques to deal with linearity of typing contexts, its dynamic semantics is a small-step reduction semantics that performs extrusion of type abstraction as needed during reduction, and the two are related by subject reduction and progress lemmas. Applying the Curry-Howard isomorphism, F-zip can be also read back as a logic with the same expressive power as second-order logic but with more modular ways of assembling partial proofs. We also extend the core calculus to handle the double vision problem as well as type-level and term-level recursion. The resulting language turns out to be a new formalization of (a minor variant of) Dreyer's internal language for recursive and mixin modules.

References

  1. Luca Cardelli and Xavier Leroy. Abstract types and the dot notation. In M. Broy and C. B. Jones, editors, Proceedings IFIP TC2 working conference on programming concepts and methods, pages 479--504. North-Holland, 1990.Google ScholarGoogle Scholar
  2. Derek Dreyer. Recursive type generativity. Journal of Functional Programming, pages 433--471, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. Derek Dreyer. A type system for recursive modules. In Proceedings of ACM SIGPLAN International Conference on Functional Programming, pages 289--302, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. Derek Dreyer, Karl Crary, and Robert Harper. A type system for higher-order modules. In Proceedings of ACM SIGPLAN Symposium on Principles of Programming Languages, pages 236--249, 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. Matthew Flatt and Matthias Felleisen. Units: Cool modules for hot languages. In Proceedings of ACM SIGPLAN Conference on Programming Language Design and Implementation, pages 236--248, 1998. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. Robert Harper and Mark Lillibridge. A type-theoretic approach to higher-order modules with sharing. In Proceedings of ACM SIGPLAN Symposium on Principles of Programming Languages, pages 123--137, New York, NY, USA, 1994. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. Robert Harper, John C. Mitchell, and Eugenio Moggi. Higher-order modules and the phase distinction. In Proceedings of ACM SIGPLAN Symposium on Principles of Programming Languages, pages 341--354, San Francisco, CA, January 1990. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. Robert Harper and Benjamin C. Pierce. Design considerations for ML-style module systems. In Benjamin C. Pierce, editor, Advanced Topics in Types and Programming Languages, chapter 8, pages 293--345. The MIT Press, 2005.Google ScholarGoogle Scholar
  9. Daniel K. Lee, Karl Crary, and Robert Harper. Towards a mechanized metatheory of Standard ML. SIGPLAN Not., 42(1):173--184, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. A syntactic theory of type generativity and sharing. Journal of Functional Programming, 6(5):667--698, 1996.Google ScholarGoogle ScholarCross RefCross Ref
  11. Xavier Leroy, Damien Doligez, Jacques Garrigue, Didier Remy, and Jerome Vouillon. The Objective Caml system release 3.10. INRIA, May 2007.Google ScholarGoogle Scholar
  12. David MacQueen. Modules for Standard ML. In ACM Symposium on LISP and functional programming, pages 198--207, New York, NY, USA, 1984. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. Robin Milner, Mads Tofte, Robert Harper, and David MacQueen. The Definition of Standard ML (Revised). The MIT Press, May 1997. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. John C. Mitchell and Gordon D. Plotkin. Abstract types have existential type. ACM Trans. Program. Lang. Syst., 10(3):470--502, 1988. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. Benoit Montagu and Didier Remy. Towards a simpler account of modules and generativity: Abstract types have Open existential types. Available at http://gallium.inria.fr/remy/modules/, March 2008.Google ScholarGoogle Scholar
  16. Martin Odersky, Vincent Cremet, Christine Rockl, and Matthias Zenger. A nominal theory of objects with dependent types. In Proceedings of European Conference on Object-Oriented Programming, pages 201--224, 2003.Google ScholarGoogle ScholarCross RefCross Ref
  17. Gilles Peskine. Abstract types in collaborative programs. PhD thesis, Universite Paris VII -- Denis Diderot, June 2008.Google ScholarGoogle Scholar
  18. John C. Reynolds. Types, abstraction and parametric polymorphism. In Information Processing 83, pages 513--523. Elsevier Science, 1983.Google ScholarGoogle Scholar
  19. Sergei Romanenko, Claudio Russo, and Peter Sestoft. Moscow ML Owner's Manual, June 2000.Google ScholarGoogle Scholar
  20. Andreas Rossberg. Generativity and dynamic opacity for abstract types. In Proceedings of ACM SIGPLAN International Conference on Principles and Practice of Declarative Programming, pages 241--252, Uppsala, Sweden, September 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. Claudio V. Russo. Types for modules. Electronic Notes in Theoretical Computer Science, 60, January 2003.Google ScholarGoogle Scholar
  22. Christopher A. Stone and Robert Harper. Deciding type equivalence in a language with singleton kinds. In Proceedings of ACM SIGPLAN International Conference on Principles and Practice of Declarative Programming, pages 214--227, Boston, January 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. Andrew K. Wright and Matthias Felleisen. A syntactic approach to type soundness. Information and Computation, 115(1):38--94, 1994. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Modeling abstract types in modules with open existential types

        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!