A three-valued declarative debugging scheme

Lee Naish


Declarative debugging has many advantages over conventional approaches to debugging for logic and functional programs. This paper extends a previously defined scheme for declarative debugging in which computations were considered either correct or erroneous. We argue that a third value, "inadmissible", should be supported and show how this can be done. Two classes of bugs are defined: one equivalent to the bugs defined by the two valued scheme, the other associated with inadmissibility. It is shown how different instances of the scheme can be used to diagnose type errors, mode errors, violated assertions and abnormal termination as well as the more familiar classes of bugs detected by declarative debuggers. Consequences for the semantics of logic programs and how type schemes can be reconstructed using three valued logic are briefly addressed.

Keywords: logic programming, declarative debugging, types, modes, assertions, abnormal termination, three valued logic, semantics


Lee