PRESET - A Debugging Environment for Prolog

This paper describes PRESET, a debugging environment for the programming language Prolog. PRESET is implemented in C-Prolog and has two major components: Predicate Diagnoser and Why/Whynot Explanation System. Predicate Diagnoser detects bugs which can be found in prior to execution, such as misspellings and illegal calls. Why/Whynot Explanation System is based on the top-down procedure diagnosis method. It can explain not only where bugs exist but also "why" they are wrong, which most of the existing debugging tools for Prolog do not indicate.