Structural Informatics Group (SIG) logo
Home | Projects | Demos | Downloads | Publications | Local Info | About Us | New site
Go to the first, previous, next, last section, table of contents.



type: function (subr) 
location: built-in
source file: xlbfun.c  and  xldbug.c
Common LISP compatible: similar
supported on: all machines


(break  [ <err-msg>  [ <arg> ] ]  )
        <err-msg>       -       a string expression for the error message
        <arg>           -       an optional expression 


The BREAK function allows the entry into the break loop with a continuable error. The continuable error generated by BREAK does not require any corrective action. The form of the message generated is:

break: <err-msg> - <arg>
if continued: return from BREAK

The default for <err-msg> is "**BREAK**". From within the break-loop, if a CONTINUE form is evaluated then a NIL is returned from BREAK. If desired, the CLEAN-UP and TOP-LEVEL functions may be evaluated to abort out of the break loop.


(break)                                 ; break: **BREAK**
(break "out")                           ; break: out
(break "it" "up")                       ; break: it - "up"

COMMON LISP COMPATIBILITY: Common LISP and XLISP have the same basic form and style for BREAK. However, the <err-msg> string in Common LISP is sent to FORMAT. FORMAT is a output function that takes in format strings that include control information. Although, XLISP does have the FORMAT function, it is not used for error messages. Porting from XLISP to Common LISP will work fine. When porting from Common LISP to XLISP, you will need to check for this embedded control information in the messages.

Go to the first, previous, next, last section, table of contents.