Heuristics for type error discovery and recovery

Jurriaan Hage, Bastiaan Heeren

Research output: Book/ReportOther report


The problem of type correctness of a functional program can be formulated as a constraint satisfaction problem. Detecting that the set of constraints is inconsistent is not enough: to improve programming efficiency, finding the constraints that are most likely to be responsible for the inconsistency is crucial. Being able to indicate how the source program should be changed to resolve the inconsistency is yet another step forward. First, a collection of constraints is represented as a type graph. Then we propose heuristics that work on the type graph data structure, each of which may suggest reasons for inconsistencies by selecting a constraint. Some of the more domain specific heuristics can even show how the program may be corrected, by considering local reformulation of the constraint satisfaction problem.
Original languageEnglish
PublisherDepartment of Information and Computing Sciences, Utrecht University
Number of pages15
Publication statusPublished - 2005

Publication series

NameTechnical Report Series


Dive into the research topics of 'Heuristics for type error discovery and recovery'. Together they form a unique fingerprint.

Cite this