Abstract
Parigot's λμ-calculus, a system for computational reasoning about classical proofs, serves as a foundation for control operations embodied by operators like Scheme's callcc. We demonstrate that the call-by-value theory of the λμ-calculus contains a latent theory of delimited control, and that a known variant of λμ which unshackles the syntax yields a calculus of composable continuations from the existing constructs and rules for classical control. To relate to the various formulations of control effects, and to continuation-passing style, we use a form of compositional program transformations which preserves the underlying structure of equational theories, contexts, and substitution. Finally, we generalize the call-by-name and call-by-value theories of the λμ-calculus by giving a single parametric theory that encompasses both, allowing us to generate a call-by-need instance that defines a calculus of classical and delimited control with lazy evaluation and sharing.
- Z. M. Ariola and M. Felleisen. The call-by-need lambda calculus. Journal of Functional Programmin, 7(3):265--301, 1997. Google Scholar
Digital Library
- Z. M. Ariola and H. Herbelin. Control reduction theories: the benefit of structural substitution. Journal of Functional Programming, 18(3): 373--419, 2008. Google Scholar
Digital Library
- Z. M. Ariola, H. Herbelin, and A. Sabry. A proof-theoretic foundation of abortive continuations. Higher-Order and Symbolic Computation, 20(4):403--429, 2007. Google Scholar
Digital Library
- Z. M. Ariola, H. Herbelin, and A. Sabry. A type-theoretic foundation of delimited continuations. Higher-Order and Symbolic Computation, 22(3):233--273, 2009. Google Scholar
Digital Library
- Z. M. Ariola, P. Downen, H. Herbelin, K. Nakata, and A. Saurin. Classical call-by-need sequent calculi: The unity of semantic artifacts. In FLOPS, pages 32--46, 2012. Google Scholar
Digital Library
- P.-L. Curien and H. Herbelin. The duality of computation. In ICFP, pages 233--243, 2000. Google Scholar
Digital Library
- O. Danvy and A. Filinski. A functional abstraction of typed contexts. Technical Report 89/12, DIKU, University of Copenhagen, Copenhagen, Denmark, 1989.Google Scholar
- O. Danvy and A. Filinski. Abstracting control. In LISP and Functional Programming, pages 151--160, 1990. Google Scholar
Digital Library
- R. David and W. Py. Lambda-mu-calculus and Böhm's theorem. Journal of Symbolic Logic, 66(1):407--413, 2001.Google Scholar
Cross Ref
- P. de Groote. On the relation between the λμ-calculus and the syntactic theory of sequential control. In LPAR, pages 31--43, 1994. Google Scholar
Digital Library
- P. Downen and Z. M. Ariola. Delimited control and computational effects. Journal of Functional Programming, 24(1):1--55, 2014.Google Scholar
Cross Ref
- R. K. Dybvig, S. P. Jones, and A. Sabry. A monadic framework for delimited continuations. Journal of Functional Programming, 17(06): 687--730, 2007. Google Scholar
Digital Library
- K. etsu Fujita. Explicitly typed λμ-calculus for polymorphism and call-by-value. In TLCA, pages 162--176, 1999. Google Scholar
Digital Library
- M. Felleisen and R. Hieb. The revised report on the syntactic theories of sequential control and state. Theoretical Computer Science, 103(2): 235--271, 1992. Google Scholar
Digital Library
- A. Filinski. Representing monads. In POPL, pages 446--457, 1994. Google Scholar
Digital Library
- T. Griffin. A formulae-as-types notion of control. In POPL, pages 47--58, 1990. Google Scholar
Digital Library
- H. Herbelin and S. Ghilezan. An approach to call-by-name delimited continuations. In POPL, pages 383--394, 2008. Google Scholar
Digital Library
- H. Herbelin and S. Zimmermann. An operational account of call-byvalue minimal and classical λ-calculus in "natural deduction" form. In TLCA, pages 142--156, 2009. Google Scholar
Digital Library
- Y. Kameyama and M. Hasegawa. A sound and complete axiomatization of delimited continuations. In ICFP, pages 177--188, 2003. Google Scholar
Digital Library
- M. Materzok. Axiomatizing subtyped delimited continuations. In CSL, pages 521--539, 2013.Google Scholar
- M. Materzok and D. Biernacki. Subtyping delimited continuations. In ICFP, pages 81--93, 2011. Google Scholar
Digital Library
- M. Materzok and D. Biernacki. A dynamic interpretation of the CPS hierarchy. In APLAS, pages 296--311, 2012.Google Scholar
Cross Ref
- E. Moggi. Computational λ-calculus and monads. In Logic in Computer Science, 1989. Google Scholar
Digital Library
- C.-H. L. Ong and C. A. Stewart. A curry-howard foundation for functional computation with control. In POPL, pages 215--227, 1997. Google Scholar
Digital Library
- M. Parigot. Lambda-my-calculus: An algorithmic interpretation of classical natural deduction. In LPAR, pages 190--201, 1992. Google Scholar
Digital Library
- G. D. Plotkin. Call-by-name, call-by-value and the lambda-calculus. Theoretical Computer Science, 1(2):125--159, 1975.Google Scholar
- S. Ronchi Della Rocca and L. Paolini. The Parametric Lambda Calculus: A Metamodel for Computation. Texts in Theoretical Computer Science. An EATCS Series. Springer-Verlag, 2004. Google Scholar
Digital Library
- A. Sabry. Note on axiomatizing the semantics of control operators. Technical Report CIS-TR-96-03, Department of Computer and Information Science, University of Oregon, 1996.Google Scholar
- A. Sabry and M. Felleisen. Reasoning about programs in continuation-passing style. Lisp and Symbolic Computation, 6(3-4):289--360, 1993. Google Scholar
Digital Library
- A. Sabry and P. Wadler. A reflection on call-by-value. ACM Transactions on Programming Languages and Systems, 19(6):916--941, 1997. Google Scholar
Digital Library
- A. Saurin. Separation with streams in the λμ-calculus. In LICS, pages 356--365, 2005. Google Scholar
Digital Library
- A. Saurin. Typing streams in the λμ-calculus. ACM Transactions on Computational Logic, 11(4), 2010. Google Scholar
Digital Library
- C. Shan. Shift to control. In Workshop on Scheme and Functional Programming, page 99, 2004.Google Scholar
Index Terms
Compositional semantics for composable continuations: from abortive to delimited control
Recommendations
Compositional semantics for composable continuations: from abortive to delimited control
ICFP '14: Proceedings of the 19th ACM SIGPLAN international conference on Functional programmingParigot's λμ-calculus, a system for computational reasoning about classical proofs, serves as a foundation for control operations embodied by operators like Scheme's callcc. We demonstrate that the call-by-value theory of the λμ-calculus contains a ...
An approach to call-by-name delimited continuations
POPL '08We show that a variant of Parigot's λμ-calculus, originally due to de Groote and proved to satisfy Boehm's theorem by Saurin, is canonically interpretable as a call-by-name calculus of delimited control. This observation is expressed using Ariola et al'...
An approach to call-by-name delimited continuations
POPL '08: Proceedings of the 35th annual ACM SIGPLAN-SIGACT symposium on Principles of programming languagesWe show that a variant of Parigot's λμ-calculus, originally due to de Groote and proved to satisfy Boehm's theorem by Saurin, is canonically interpretable as a call-by-name calculus of delimited control. This observation is expressed using Ariola et al'...







Comments