Swierstra, Wouter (2009) *A functional specification of effects.* PhD thesis, University of Nottingham.

Preview |
| PDF 481Kb |

## Abstract

This dissertation is about effects and type theory.

Functional programming languages such as Haskell illustrate how to encapsulate side effects using monads. Haskell compilers provide a handful of primitive effectful functions. Programmers can construct larger computations using the monadic return and bind operations.

These primitive effectful functions, however, have no associated deﬁnition. At best, their semantics are speciﬁed separately on paper. This can make it difﬁcult to test, debug, verify, or even predict the behaviour of effectful computations.

This dissertation provides pure, functional speciﬁcations in Haskell of several different effects. Using these speciﬁcations, programmers can test and debug effectful programs. This is particularly useful in tandem with automatic testing tools such as QuickCheck.

The speciﬁcations in Haskell are not total. This makes them unsuitable for the formal veriﬁcation of effectful functions. This dissertation overcomes this limitation, by presenting total functional speciﬁcations in Agda, a programming language with dependent types.

There have been alternative approaches to incorporating effects in a dependently typed programming language. Most notably, recent work on Hoare Type Theory proposes to extend type theory with axioms that postulate the existence of primitive effectful functions. This dissertation shows how the functional speciﬁcations implement these axioms, unifying the two approaches.

The results presented in this dissertation may be used to write and verify effectful programs in the framework of type theory.

Item Type: | Thesis (PhD) |
---|

Supervisors: | Altenkirch, T. Ghani, N. |
---|

Uncontrolled Keywords: | functional programming, effects, haskell, type theory |
---|

Faculties/Schools: | UK Campuses > Faculty of Science > School of Computer Science |
---|

ID Code: | 779 |
---|

Deposited By: | Dr. Wouter Swierstra |
---|

Deposited On: | 06 Jan 2010 14:58 |
---|

Last Modified: | 06 Jan 2010 15:03 |
---|

Archive Staff Only: item control page