LispWorks User Guide and Reference Manual > 34 The LISPWORKS Package




Quits LispWorks.




quit &key status confirm ignore-errors-p return



An integer.


A generalized boolean.


A generalised boolean.


A generalized boolean.


quit does not return, or returns t .


The function quit exits LispWorks unless the user cancels the operation.

There are two stages which may allow the user the chance to cancel.

  1. First the action items of the action list "Confirm when quitting image" are run. If any action item returns nil , then LispWorks does not exit.
  2. Otherwise, if confirm is true (the default value is nil ) then a question like
    "Do you really want to exit LispWorks?"
    is presented to the user. If the answer No is supplied, then LispWorks does not exit. Otherwise, the action items of the action list "When quitting image" are run, and then LispWorks exits, and the value status is returned to the Operating System as the exit value of the LispWorks process. The default value of status is 0.

If ignore-errors-p is true, then any error signalled during the running of the action list items or the confirm prompt is ignored and quit proceeds to exit the image. If ignore-errors-p is nil and an error is signalled during the running of the action list items, then a restart is available allowing the user to choose to continue to exit the image. The default values of ignore-errors-p is nil .

If return is true and LispWorks is going to exit, then quit returns t . This can be used if you want some other Lisp process to kill the current one later, rather than it self-destructing immediately. This can be useful to allow more precise control over process termination. If return is nil then quit does not return. The default value of return is nil .

Note: To make a Cocoa application quit cleanly from inside the Quit menu command you need to call capi:destroy on the application interface instead of calling quit . See capi:default-cocoa-application-interface in the CAPI Reference Manual for more information.

See also


LispWorks User Guide and Reference Manual - 22 Dec 2009