A program transformation for debugging Haskell 98

Bernard J. Pope, Lee Naish · 2003

We present a source-to-source transformation of Haskell 98 programs for the purpose of debugging. The source code of a program is transformed into a new program which, when executed, computes the value of the original program and a high-level semantics for that computation. The semantics is given by a tree whose nodes represent function applications that were evaluated during execution. This tree is useful in situations where a high-level view of a computation is needed, such as declarative debugging. The main contribution of the paper is the treatment of higher-order functions, which have previously proven difficult to support in declarative debugging schemes.

Read the paper · More papers on PaperTik