Skip to main content

Proving Syntactic Properties of Exceptions in an Ordered Logical Framework

  • Conference paper
  • First Online:
Functional and Logic Programming (FLOPS 2001)

Part of the book series: Lecture Notes in Computer Science ((LNCS,volume 2024))

Included in the following conference series:

Abstract

We formally prove the stackability and linearity of exception handlers with ML-style semantics using a novel proof technique via an ordered logical framework (OLF). We first transform exceptions into continuation-passing-style (CPS) terms and formalize the exception properties as a judgement on the CPS terms. Then, rather than directly proving that the properties hold for terms, we prove our theorem for the representations of the CPS terms and transform in OLF. We rely upon the correctness of our representations to transfer the results back to the actual CPS terms and transform.

Our work can be seen as two-fold: we present a theoretical justification of using the stack mechanism to implement exceptions of ML-like semantics; and we demonstrate the value of an ordered logical framework as a conceptual tool in the theoretical study of programming languages.

This work is supported by Creative Research Initiatives of the Korean Ministry of Science and Technology.

Research On Program Analysis System (http://ropas.kaist.ac.kr), National Creative Research Initiative Center, KAIST, Korea.

Acknowledgements

We would like to acknowledge insightful discussions with Peter O’Hearn and Frank Pfenning.

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 39.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.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. Andrew W. Appel. Modern Compiler Implementation in ML/C/Java: Basic Techniques. Cambridge University Press, 1997.

    Google Scholar 

  2. Josh Berdine, Peter O’Hearn, Uday S. Reddy, and Hayo Thielecke. Linearly used continuations. In Informal Proceedings of The Third ACM SIGPLAN Workshop on Continuations (CW ’01), January 2001. To appear.

    Google Scholar 

  3. Iliano Cervesato and Frank Pfenning. A linear logical framework. Information and Computation, 1999. To appear in the special issue with invited papers from LICS’96, E. Clarke, editor.

    Google Scholar 

  4. Olivier Danvy. Formalizing implementation strategies for first-class continuations. In Programming Languages and Systems, The Proceedings of the 9th European Symposium On Programming, volume 1782 of Lecture Notes in Computer Science, pages 88–103, 2000.

    MATH  Google Scholar 

  5. ]Olivier Danvy, Belmina Dzac, and Frank Pfenning. On proving syntactic properties of cps programs. In Third International Workshop on Higher Order Operational Techniques in Semantics (HOOTS’99), Paris, France, September 1999.

    Google Scholar 

  6. Olivier Danvy and Andrzej Filinski. Representing control: a study of the CPS transformation. Mathematical Structures in Computer Science, 2(4):361–391, December 1992.

    Article  MathSciNet  Google Scholar 

  7. Olivier Danvy and Frank Pfenning. The occurrence of continuation parameters in CPS terms. Technical Report CMU-CS-95-121, Department of Computer Science, Carnegie Mellon University, February 1995.

    Google Scholar 

  8. Matthias Felleisen. The Calculi of λ-v-CS Conversion: A Syntactic Theory of Control and State in Imperative Higher-Order Programming Languages. PhD thesis, Department of Computer Science, Indiana University, Bloomington, Indiana, August 1987.

    Google Scholar 

  9. John Hatcliff and Olivier Danvy. Thunks and the λ-calculus. Journal of Functional Programming, 7(3):303–320, 1997.

    Article  MathSciNet  Google Scholar 

  10. Robert Harper, Furio Honsell, and Gordon Plotkin. A framework for defining logics. Journal of the Association for Computing Machinery, 40(1):143–184, January 1993.

    Article  MathSciNet  Google Scholar 

  11. Jungtaek Kim, Kwangkeun Yi, and Olivier Danvy. Assessing the overhead of ml exceptions by selective cps transformation. In The Proceedings of the ACM SIGPLAN Workshop on ML, pages 103–114, September 1998.

    Google Scholar 

  12. Frank Pfenning. The practice of logical frameworks. In Hélène Kirchner, editor, Proceedings of the Colloquium on Trees in Algebra and Programming, pages 119–134, Linköping, Sweden, April 1996. Springer-Verlag LNCS 1059. Invited talk.

    Google Scholar 

  13. Gordon D. Plotkin. Call-by-name, call-by-value and the λ-calculus. Theoretical Computer Science, 1:125–159, 1975.

    Article  MathSciNet  Google Scholar 

  14. Gordon D. Plotkin. A structural approach to operational semantics. Technical report, Aarhus University, September 1981.

    Google Scholar 

  15. Jeff Polakow and Frank Pfenning. Natural deduction for intuitionistic non-commutative linear logic. In J.-Y. Girard, editor, Proceedings of the Fourth International Conference on Typed Lambda Calculi and Applications (TLCA’99), pages 295–309, l’Aquila, Italy, April 1999. Springer-Verlag LNCS 1581.

    MATH  Google Scholar 

  16. Jeff Polakow and Frank Pfenning. Relating natural deduction and sequent calculus for intuitionistic non-commutative linear logic. In Andre Scedrov and Achim Jung, editors, Proceedings of the 15th Conference on Mathematical Foundations of Programming Semantics, pages 311–328, New Orleans, Louisiana, April 1999. Electronic Notes in Theoretical Computer Science, Volume 20.

    Google Scholar 

  17. Jeff Polakow and Frank Pfenning. Properties of terms in continuation passing style in an ordered logical framework. In Workshop on Logical Frameworks and Meta-Languages (LFM 2000), Santa Barbara, California, June 2000.

    Google Scholar 

  18. Guy L. Steele Jr. Rabbit: A compiler for Scheme. Technical Report AI-TR-474, Artificial Intelligence Laboratory, Massachusetts Institute of Technology, Cambridge, Massachusetts, May 1978.

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2001 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Polakow, J., Yi, K. (2001). Proving Syntactic Properties of Exceptions in an Ordered Logical Framework. In: Kuchen, H., Ueda, K. (eds) Functional and Logic Programming. FLOPS 2001. Lecture Notes in Computer Science, vol 2024. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-44716-4_4

Download citation

  • DOI: https://doi.org/10.1007/3-540-44716-4_4

  • Published:

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-41739-2

  • Online ISBN: 978-3-540-44716-0

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics