11.3.27 break/0   development



causes the current execution to be interrupted; enters next break level.


The first time break/0 is called, it displays the message

% Break level 1
% 1
| ?- 

The system is then ready to accept input as though it were at top level. If another call to break/0 is encountered, then it moves up to level 2, and so on. The break level is displayed on a separate line before each top-level prompt.

To close a break level and resume the execution that was suspended, type ^D. break/0 then succeeds, and execution of the interrupted program is resumed.

Changes can be made to a running program while in a break level. Any change made to a procedure will take effect the next time that procedure is called. See ref-mdb-rcd for details of what happens if a procedure that is currently being executed is redefined. When a break level is entered, the debugger is turned off (although leashing and spypoints are retained). When a break level is exited, the debugging state is restored to what it was before the break level was entered.

Often used via the debugging option b.


Catches otherwise uncaught exceptions and issues an error message.

See Also

abort/0, halt/[0,1], Nested.

Send feedback on this subject.