Abstract
There have traditionally been two approaches to modelling environments, one by use of finite products in Cartesian closed categories, the other by use of the base categories of indexed categories with structure. Recently, there have been more general definitions along both of these lines: the first generalising from Cartesian to symmetric premonoidal categories, the second generalising from indexed categories with specified structure to κ-categories. The added generality is not of the purely mathematical kind; in fact it is necessary to extend semantics from the logical calculi studied in, say, Type Theory to more realistic programming language fragments. In this paper, we establish an equivalence between these two recent notions. We then use that equivalence to study semantics for continuations. We give three category theoretic semantics for modelling continuations and show the relationships between them. The first is given by a continuations monad. The second is based on a symmetric premonoidal category with a self-adjoint structure. The third is based on a κ-category with indexed self-adjoint structure. We extend our result about environments to show that the second and third semantics are essentially equivalent, and that they include the first.
This work is supported by EPSRC grant GR/J84205: Frameworks for programming language semantics and logic.
Preview
Unable to display preview. Download preview PDF.
References
R.F. Blute, J.R.B. Cockett and R.A.G. Seely, Categories for computation in context and unified logic (submitted)
Gerard Boudol, The π-calculus in direct style, Proc. POPL '97.
Bruce Duba, Robert Harper, and David MacQueen. Typing first-class continuations in ML. In Proc. ACM Symp. Principles of Programming Languages, pages 163–173, January 1991.
Matthias Felleisen and Daniel P. Friedman. The Seasoned Schemer. MIT Press, 1996.
Andrzej Filinski, Declarative continuations: an investigation of duality in programming language semantics, Proc. CTCS, Lect. Notes in Computer Science 389 (1989) 224–249.
Michael Fourman and Hayo Thielecke. A proposed categorical semantics for ML modules. In David Pitt et al., editor, Category Theory in Computer Science, number 953 in LNCS. Springer Verlag, 1995.
Masahito Hasegawa, Decomposing typed lambda calculus into a couple of categorical programming languages, Proc. CTCS, Lect. Notes in Computer Science 953 (1995).
Bart Jacobs. Categorical Type Theory. PhD thesis, University of Nijmegen, 1991.
Richard Kiebutz, Borislav Agapiev, and James Hook. Three monads for continuations. In Proceedings of the ACM Workshop on Continuations, pages 39–48, 1992.
E. Moggi, Notions of computation and monads, Information and Computation 93 (1991) 55–92.
C. H. L. Ong. A semantic view of classical proofs: type-theoretic, categorical, denotational characterizations. In Proc. 11th IEEE Annual Symposium on Logic in Computer Science, pages 230–241. IEEE Computer Society Press, 1996.
Robert Harper, Bruce Duba, and David MacQueen. Typing first-class continuations in ML. Journal of Functional Programming, 3(4), October 1993.
P. Z. Ingerman. Thunks: a way of compiling procedure statements with some comments on procedure declarations. Comm. A.C.M., 4(1):55–58, January 1961.
Michel Parigot. λμ-calculus: an algorithmic interpretation of classical natural deduction. In Proceedings International Conference on Logic Programming and Automated Deduction, number 624 in LNCS, pages I90–201, 1992.
A.J. Power, Premonoidal categories as categories with algebraic structure (submitted).
A.J. Power and E.P. Robinson, Premonoidal categories and notions of computation, Proc. LDPL '96, Math Structures in Computer Science (to appear).
E.P. Robinson and G. Rosolini, Categories of partial maps, Information and Computation 79 (1988) 95–130.
Hayo Thielecke. Continuation passing style and self-adjointness. In Proceedings 2nd ACM SIGPLAN Workshop on Continuations, number NS-96-13 in BRIGS Notes Series, December 1996.
Hayo Thielecke, Continuations semantics and self-adjointness, Proc. 13th MFPS, Electronic Notes in Theoretical Computer Science 6 (to appear).
Hayo Thielecke, Categorical structure of continuation passing style, Edinburgh Ph.D. thesis (submitted).
Author information
Authors and Affiliations
Editor information
Rights and permissions
Copyright information
© 1997 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Power, J., Thielecke, H. (1997). Environments, continuation semantics and indexed categories. In: Abadi, M., Ito, T. (eds) Theoretical Aspects of Computer Software. TACS 1997. Lecture Notes in Computer Science, vol 1281. Springer, Berlin, Heidelberg. https://doi.org/10.1007/BFb0014560
Download citation
DOI: https://doi.org/10.1007/BFb0014560
Published:
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-63388-4
Online ISBN: 978-3-540-69530-1
eBook Packages: Springer Book Archive