### 4.4 Debugging messages

We here described which information is displayed by the debugger when it shows a goal. The basic format is as follows:

  `S N M Port: Goal ?`

`S` is a spy-point indicator: if there is a spy-point on the current goal the `+` symbol is displayed else a space is displayed. `N` is the invocation number. This unique number can be used to correlate the trace messages for the various ports, since it is unique for every invocation. `M` is an index number which represents the number of direct ancestors of the goal (i.e. the current depth of the goal). `Port` specifies the particular port (`call`, `exit`, `fail`, `redo`, `exception`). `Goal` is the current goal (it is then possible to inspect its current instantiation) which is displayed using `write_term/3` with `quoted(true)` and `max_depth(D)` options (section 7.14.6). Initially `D` (the print depth) is set to 10 but can be redefined using the `<` debugger command (section 4.5). The `?` symbol is displayed when the debugger is waiting a command from the user. (i.e. `Port` is a leashed port). If the port is unleashed, this symbol is not displayed and the debugger continues the execution displaying the next goal.

Copyright (C) 1999-2009 Daniel Diaz Verbatim copying and distribution of this entire article is permitted in any medium, provided this notice is preserved. More about the copyright