Skip to main content

A System F with Call-by-Name Exceptions

  • Conference paper
Automata, Languages and Programming (ICALP 2008)

Part of the book series: Lecture Notes in Computer Science ((LNTCS,volume 5126))

Included in the following conference series:

Abstract

We present an extension of System F with call-by-name exceptions. The type system is enriched with two syntactic constructs: a union type \(A {\rlap{{*}}\cup} \{\varepsilon\}\) for programs of type A whose execution may raise the exception ε at top level, and a corruption type A (ε) for programs that may raise the exception ε in any evaluation context (not necessarily at top level). We present the syntax and reduction rules of the system, as well as its typing and subtyping rules. We then study its properties, such as confluence. Finally, we construct a realizability model using orthogonality techniques, from which we deduce that well-typed programs are weakly normalizing and that the ones who have the type of natural numbers really compute a natural number, without raising exceptions.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 84.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 109.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. David, R., Mounier, G.: An intuitionistic λ-calculus with exceptions. Journal of Functional Programming 15(01), 33–52 (2004)

    Article  MathSciNet  Google Scholar 

  2. The Coq development team. The Coq Proof Assistant Reference Manual v8.1 (2006)

    Google Scholar 

  3. Girard, J.Y.: Locus Solum: From the rules of logic to the logic of rules. Mathematical Structures in Computer Science 11(03), 301–506 (2001)

    Article  MATH  MathSciNet  Google Scholar 

  4. Guzman, J., Suarez, A.: An extended type system for exceptions. In: Proceedings of the ACM SIGPLAN Workshop on ML and its Applications, pp. 127–135 (1994)

    Google Scholar 

  5. Mitchell, J.C.: Polymorphic type inference and containment. Information and Computation 76(2-3), 211–249 (1988)

    Article  MATH  MathSciNet  Google Scholar 

  6. Moggi, E.: Notions of computation and monads. INF. COMPUT. 93(1), 55–92 (1991)

    Article  MATH  MathSciNet  Google Scholar 

  7. Pessaux, F., Leroy, X.: Type-based analysis of uncaught exceptions. In: Proceedings of the 26th ACM SIGPLAN-SIGACT symposium on Principles of programming languages, pp. 276–290 (1999)

    Google Scholar 

  8. Peyton Jones, S., Reid, A., Henderson, F., Hoare, T., Marlow, S.: A semantics for imprecise exceptions. ACM SIGPLAN Notices 34(5), 25–36 (1999)

    Article  Google Scholar 

  9. Spivey, M.: A functional theory of exceptions. Science of Computer Programming 14(1), 25–42 (1990)

    Article  MATH  Google Scholar 

  10. Thielecke, H.: Comparing Control Constructs by Double-Barrelled CPS. Higher-Order and Symbolic Computation 15(2), 141–160 (2002)

    Article  MATH  Google Scholar 

  11. Vouillon, J., Melliès, P.A.: Semantic types: a fresh look at the ideal model for types. In: Proceedings of the 31st ACM SIGPLAN-SIGACT symposium on Principles of programming languages, pp. 52–63 (2004)

    Google Scholar 

  12. Wadler, P.: How to Replace Failure by a List of Successes A method for exception handling, backtracking, and pattern matching. Functional Programming Languages and Computer Architecture (1985)

    Google Scholar 

  13. Wadler, P.: Comprehending monads. In: Proceedings of the 1990 ACM conference on LISP and functional programming, pp. 61–78 (1990)

    Google Scholar 

  14. Wadler, P., Thiemann, P.: The marriage of effects and monads. ACM Transactions on Computational Logic (TOCL) 4(1), 1–32 (2003)

    Article  MathSciNet  Google Scholar 

  15. Wells, J.B.: The undecidability of Mitchells subtyping relation. Technical Report 95-019, Boston University, Boston, Massachusetts (1995)

    Google Scholar 

  16. Wells, J.B.: Typability and type checking in System F are equivalent and undecidable. Annals of Pure and Applied Logic 98(1-3), 111–156 (1999)

    Article  MATH  MathSciNet  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Luca Aceto Ivan Damgård Leslie Ann Goldberg Magnús M. Halldórsson Anna Ingólfsdóttir Igor Walukiewicz

Rights and permissions

Reprints and permissions

Copyright information

© 2008 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Lebresne, S. (2008). A System F with Call-by-Name Exceptions. In: Aceto, L., Damgård, I., Goldberg, L.A., Halldórsson, M.M., Ingólfsdóttir, A., Walukiewicz, I. (eds) Automata, Languages and Programming. ICALP 2008. Lecture Notes in Computer Science, vol 5126. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-540-70583-3_27

Download citation

  • DOI: https://doi.org/10.1007/978-3-540-70583-3_27

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-70582-6

  • Online ISBN: 978-3-540-70583-3

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics