break/0 development

Synopsis

break

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

Description

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

     % Beginning break level 1
     
     | ?-
     

The system is then ready to accept input as though it were at top level. If another call to break/0 is encountered, it moves up to level 2, and so on. The break level is displayed in the editor mode line when you are running under the editor interface; otherwise it is displayed on a separate line before each top-level prompt, as follows:

     [1]
     | ?-
     

To close a break level and resume the execution that was suspended, type the end-of-file character applicable on your system (default ^D). break/0 then succeeds, and execution of the interrupted program is resumed. Alternatively, the suspended execution can be abandoned by interrupting with a ^C and using the q option.

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-lod-rpx, 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.

This predicate is not supported in runtime systems.

See Also

abort/0, halt/[0,1], QP_toplevel()