Nothing Special   »   [go: up one dir, main page]

skip to main content
article

Exception analysis for non-strict languages

Published: 17 September 2002 Publication History

Abstract

In this paper we present the first exception analysis for a non-strict language. We augment a simply-typed functional language with exceptions, and show that we can define a type-based inference system to detect uncaught exceptions. We have implemented this exception analysis in the GHC compiler for Haskell, which has been recently extended with exceptions. We give empirical evidence that the analysis is practical.

References

[1]
K. Arnold, J. Gosling, and D. Holmes. The Java Programming Language. Addison-Wesley, third edition, 2000.]]
[2]
D. Dussart, F. Henglein, and C. Mossin. Polymorphic recursion and subtype qualifications: Polymorphic binding-time analysis in polynomial time. In A. Mycroft, editor, Proc. Second Int. Symp. Static Analysis, volume 983 of Lecture Notes in Computer Science, pages 118--135. Springer, 1995.]]
[3]
M. Fähndrich and A. Aiken. Program analysis using mixed term and set constraints. In P. Van Hentenryck, editor, Static Analysis: Proc. Fourth Int. Symp., volume 1302 of LNCS, pages 114--126. Springer, 1997.]]
[4]
M. Fähndrich and A. Aiken. Refined type inference for ML. In First International Workshop on Types in Compilation (TIC'97), 1997.]]
[5]
M. Fähndrich and J. Rehof. Type-based flow analysis: From polymorphic subtyping to CFL reachability. In Proc. 28th ACM Symp. Principles of Programming Languages, pages 54--66. ACM Press, 2001.]]
[6]
J. S. Foster, M. Fähndrich, and A. Aiken. A theory of type qualifiers. In Proc. 1999 ACM Conf. Programming Language Design and Implementation, pages 192--203. ACM Press, 1999.]]
[7]
K. Glynn, P. J. Stuckey, and M. Sulzmann. Effective strictness analysis with Horn constraints. In P. Cousot, editor, Static Analysis: Proc. Eighth Int. Symp. Static Analysis, volume 2126 of Lecture Notes in Computer Science, pages 73--92. Springer, 2001.]]
[8]
K. Glynn, P. J. Stuckey, M. Sulzmann, and H. Sondergaard. Boolean constraints for binding-time analysis. In O. Danvy and A. Filinsky, editors, Programs as Data Objects: Proceedings of the Second Symposium, volume 2053 of LNCS, pages 39--63. Springer, 2001.]]
[9]
J. Guzmán and A. Suárez. An extended type system for exceptions. In ACM SIGPLAN Workshop on ML and Its Applications, 1994.]]
[10]
P. Jouvelot and D. Gifford. Algebraic reconstruction of types and effects. In Proc. 18th ACM Symp. Principles of Programming Languages, pages 303--310. ACM Press, 1991.]]
[11]
X. Leroy. The Objective Caml system, 1996. http://pauillac.inria.fr/ocaml/.]]
[12]
R. Milner, M. Tofte, and R.W. Harper. The Definition of Standard ML. MIT Press, Cambridge, Massachusetts, 1990.]]
[13]
F. Pessaux and X. Leroy. Type-based analysis of uncaught exceptions. In Proc. 26th ACM Symp. Principles of Programming Languages, pages 276--290. ACM Press, 1999.]]
[14]
S. L. Peyton Jones, A. Reid, T. Hoare, S. Marlow, and F. Henderson. A semantics for imprecise exceptions. In Proc. 1999 ACM SIGPLAN Conf. Programming Language Design and Implementation, pages 25--36. ACM Press, 1999.]]
[15]
S. Peyton Jones et al. Report on the programming language Haskell~98. Technical report, February 1999. http:/haskell.org.]]
[16]
K. Yi. An abstract interpretation for estimating uncaught exceptions in Standard ML programs. Science of Computer Programming, 31(1):147--173, 1998.]]

Cited By

View all
  • (2015)Type-based Exception Analysis for Non-strict Higher-order Functional Languages with Imprecise Exception SemanticsProceedings of the 2015 Workshop on Partial Evaluation and Program Manipulation10.1145/2678015.2682542(127-138)Online publication date: 13-Jan-2015
  • (2014)An efficient thread partition policy for secure functional languageJournal of Computer Virology and Hacking Techniques10.1007/s11416-014-0234-711:3(165-171)Online publication date: 30-Dec-2014
  • (2019)Combining the robustness of checked exceptions with the flexibility of unchecked exceptions using anchored exception declarationsACM SIGPLAN Notices10.1145/1103845.109484740:10(455-471)Online publication date: 27-Feb-2019
  • Show More Cited By

Recommendations

Comments

Please enable JavaScript to view thecomments powered by Disqus.

Information & Contributors

Information

Published In

cover image ACM SIGPLAN Notices
ACM SIGPLAN Notices  Volume 37, Issue 9
September 2002
283 pages
ISSN:0362-1340
EISSN:1558-1160
DOI:10.1145/583852
Issue’s Table of Contents
  • cover image ACM Conferences
    ICFP '02: Proceedings of the seventh ACM SIGPLAN international conference on Functional programming
    October 2002
    294 pages
    ISBN:1581134878
    DOI:10.1145/581478
Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

Publisher

Association for Computing Machinery

New York, NY, United States

Publication History

Published: 17 September 2002
Published in SIGPLAN Volume 37, Issue 9

Check for updates

Author Tags

  1. Boolean constraints
  2. effect systems
  3. exceptions
  4. non-strict functional programming languages
  5. type inference

Qualifiers

  • Article

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)1
  • Downloads (Last 6 weeks)0
Reflects downloads up to 12 Nov 2024

Other Metrics

Citations

Cited By

View all
  • (2015)Type-based Exception Analysis for Non-strict Higher-order Functional Languages with Imprecise Exception SemanticsProceedings of the 2015 Workshop on Partial Evaluation and Program Manipulation10.1145/2678015.2682542(127-138)Online publication date: 13-Jan-2015
  • (2014)An efficient thread partition policy for secure functional languageJournal of Computer Virology and Hacking Techniques10.1007/s11416-014-0234-711:3(165-171)Online publication date: 30-Dec-2014
  • (2019)Combining the robustness of checked exceptions with the flexibility of unchecked exceptions using anchored exception declarationsACM SIGPLAN Notices10.1145/1103845.109484740:10(455-471)Online publication date: 27-Feb-2019
  • (2015)Type-based Exception Analysis for Non-strict Higher-order Functional Languages with Imprecise Exception SemanticsProceedings of the 2015 Workshop on Partial Evaluation and Program Manipulation10.1145/2678015.2682542(127-138)Online publication date: 13-Jan-2015
  • (2009)Translation and optimization for a core calculus with exceptionsProceedings of the 2009 ACM SIGPLAN workshop on Partial evaluation and program manipulation10.1145/1480945.1480952(41-50)Online publication date: 19-Jan-2009
  • (2006)Closure operators for ROBDDsProceedings of the 7th international conference on Verification, Model Checking, and Abstract Interpretation10.1007/11609773_1(1-16)Online publication date: 8-Jan-2006
  • (2005)Combining the robustness of checked exceptions with the flexibility of unchecked exceptions using anchored exception declarationsProceedings of the 20th annual ACM SIGPLAN conference on Object-oriented programming, systems, languages, and applications10.1145/1094811.1094847(455-471)Online publication date: 17-Oct-2005

View Options

Get Access

Login options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

Media

Figures

Other

Tables

Share

Share

Share this Publication link

Share on social media