Hostname: page-component-8448b6f56d-sxzjt Total loading time: 0 Render date: 2024-04-19T00:58:18.661Z Has data issue: false hasContentIssue false

A duality between exceptions and states

Published online by Cambridge University Press:  08 May 2012

JEAN-GUILLAUME DUMAS
Affiliation:
LJK, Université de Grenoble, France Email: Jean-Guillaume.Dumas@imag.fr; Dominique.Duval@imag.fr; Laurent.Fousse@imag.fr
DOMINIQUE DUVAL
Affiliation:
LJK, Université de Grenoble, France Email: Jean-Guillaume.Dumas@imag.fr; Dominique.Duval@imag.fr; Laurent.Fousse@imag.fr
LAURENT FOUSSE
Affiliation:
LJK, Université de Grenoble, France Email: Jean-Guillaume.Dumas@imag.fr; Dominique.Duval@imag.fr; Laurent.Fousse@imag.fr
JEAN-CLAUDE REYNAUD
Affiliation:
Malhivert, Claix, France Email: Jean-Claude.Reynaud@imag.fr

Abstract

In this short note we study the semantics of two basic computational effects, exceptions and states, from a new point of view. In the handling of exceptions we dissociate the control from the elementary operation that recovers from the exception. In this way it becomes apparent that there is a duality, in the categorical sense, between exceptions and states.

Type
Paper
Copyright
Copyright © Cambridge University Press 2012

Access options

Get access to the full version of this content by using one of the access options below. (Log in options will check for institutional or personal access. Content may require purchase if you do not have access.)

References

Dumas, J.-G., Duval, D., Fousse, L. and Reynaud, J.-C. (2010) States and exceptions considered as dual effects. Available at arXiv:1001.1662 v4.Google Scholar
Levy, P. B. (2006) Monads and adjunctions for global exceptions. MFPS 2006. Electronic Notes in Theoretical Computer Science 158 261287.CrossRefGoogle Scholar
Moggi, E. (1991) Notions of Computation and Monads. Information and Computation 93 (1)5592.CrossRefGoogle Scholar
Plotkin, G. D. and Power, J. (2002) Notions of Computation Determine Monads. FoSSaCS 2002. Springer-Verlag Lecture Notes in Computer Science 2303 342356.Google Scholar
Plotkin, G. D. and Pretnar, M. (2009) Handlers of Algebraic Effects. ESOP 2009. Springer-Verlag Lecture Notes in Computer Science 5502 8094.CrossRefGoogle Scholar
Schröder, L. and Mossakowski, T. (2004) Generic Exception Handling and the Java Monad. AMAST 2004. Springer-Verlag Lecture Notes in Computer Science 3116 443459.Google Scholar