Abstract
Exception handling mechanisms provided by programming languages are intended to ease the difficulty of developing robust software systems. Using these mechanisms, a software developer can describe the exceptional conditions a module might raise, and the response of the module to exceptional conditions that may occur as it is executing. Creating a robust system from such a localized view requires a developer to reason about the flow of exceptions across modules. The use of unchecked exceptions, and in object-oriented languages, subsumption, makes it difficult for a software developer to perform this reasoning manually. In this paper, we describe a tool called Jex that analyzes the flow of exceptions in Java code to produce views of the exception structure. We demonstrate how Jex can help a developer identify program points where exceptions are caught accidentally, where there is an opportunity to add finer-grained recovery code, and where error-handling policies are not being followed.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
References
Martín Abadi and Luca Cardelli. A Theory of Objects. Springer, 1996.
Jong-Deok Choi, David Grove, Michael Hind, and Vivek Sarkar. Efficient and precise modeling of exceptions for the analysis of Java programs. In ACM SIGPLANSIGSOFT Workshop on Program Analysis for Software Tools and Engineering (PASTE’99), September 1999. To appear.
Manuel Fahndrich, Jeffrey Foster, Jason Cu, and Alexander Aiken. Tracking down exceptions in standard ML programs. Technical Report CSD-98-996, University of California, Berkeley, February 1998.
John B. Goodenough. Exception handling: Issues and proposed notation. Communications of the ACM, 18(12):683–696, December 1975.
James Gosling, Bill Joy, and Guy Steele. The Java Language Specification. Addison-Wesley Longman, Inc., 1996.
Robert Harper, Robin Milner, and Mads Tofte. The Definition of Standard ML: Version 3. Technical Report ECS-LFCS-89-81, Laboratory for the Foundations of Computer Science, University of Edinburgh, May 1989.
Nevin Heintze. Set-Based Program Analysis. PhD thesis, Carnegie-Mellon University, Pittsburgh, PA, USA, October 1992.
Mik A. Kersten and Gail C. Murphy. Atlas: A case study in building a web-based learning environment using aspect-oriented programming. In Proceedings of the Conference on Object-Oriented Programming, Systems, Languages, and Applications, 1999. To appear.
Barbara H. Liskov and Alan Snyder. Exception handling in CLU. IEEE Transactions on Software Engineering, 5(6):546–558, November 1979.
Robert Miller and Anand Tripathi. Issues with exception handling in object-oriented systems. In Proceedings of the 11th European Conference on Object-Oriented Programming, volume 1241 of Lecture Notes in Computer Science, pages 85–103. Springer-Verlag, June 1997.
Saurabh Sinha and Mary Jean Harrold. Analysis of programs with exception-handling constructs. In Proceedings of the International Conference on Software Maintenance, pages 348–357, November 1998.
Bjarne Stroustrup. The C++ Programming Language. Addison-Wesley, 2nd edition, 1991.
Sun Microsystems, Inc. The Java Parser Generator. http://www.suntest.com/JavaCC/.
Kwangkeun Yi. Compile-time detection of uncaught exceptions in standard ML programs. In Proceedings of the First International Static Analysis Symposium, volume 864 of Lecture Notes in Computer Science, pages 238–254. Springer-Verlag, 1994.
Kwangkeun Yi. An abstract interpretation for estimating uncaught exceptions in standard ML programs. Science of Computer Programming, 31:147–173, 1998.
Kwangkeun Yi and Byeong-Mo Chang. Exception analysis for Java. In ECOOP’99 Workshop on Formal Techniques for Java Programs, June 1999. To appear.
Kwangkeun Yi and Sukyoung Ryu. Towards a cost-effective estimation of uncaught exceptions in SML programs. In Proceedings of the 4th International Static Analysis Symposium, volume 1302 of Lecture Notes in Computer Science, pages 98–113, September 1997.
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 1999 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Robillard, M.P., Murphy, G.C. (1999). Analyzing Exception Flow in Java™ Programs. In: Nierstrasz, O., Lemoine, M. (eds) Software Engineering — ESEC/FSE ’99. ESEC SIGSOFT FSE 1999 1999. Lecture Notes in Computer Science, vol 1687. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-48166-4_20
Download citation
DOI: https://doi.org/10.1007/3-540-48166-4_20
Published:
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-66538-0
Online ISBN: 978-3-540-48166-9
eBook Packages: Springer Book Archive