A functional theory of exceptions

Abstract

AbstractExceptions are a feature often provided by programming languages to deal with computations which may fail. This paper argues that lazy functional programming not only makes a built-in exception mechanism unnecessary, but provides a powerful tool for developing and transforming programs that use exceptions. The basic idea is the simple one of augmenting each type with a distinguished error value; this idea is made practical for writing programs and reasoning about them through the use of higher-order functions. An advantage is that simple equational arguments can be used to reason about the programs.Throughout the paper, the problem of simplifying algebraic expressions using rewriting rules is used as a source of motivation and examples

Similar works

This paper was published in Elsevier - Publisher Connector .

Having an issue?

Is data on this page outdated, violates copyrights or anything else? Report the problem now and we will take corresponding actions after reviewing your request.