[Openmcl-devel] save-application

Gary Byers gb at clozure.com
Mon Jun 22 04:14:17 PDT 2009


I think that :error-handler is an anachronism that probably should
be removed.

The simplest way to get exit-on-error behavior is to start the
application with the "--batch" command-line argument; that basically
says "there's no one sitting at a keyboard to respond to a break
loop, so just try to quit if a break loop would be entered", among
other things.  With that option if effect, an unhandled error will
print a message to *ERROR-OUTPUT*, try to print a backtrace to 
*DEBUG-IO*, and exit with a non-zero status.


On Fri, 19 Jun 2009, Jared C. Davis wrote:

> Hi,
>
> I'm wondering about the :error-handler option on
> CCL::save-application.  I'm using CCL 1.3-r12155M on Linux X86-64.  I
> saved my program with
>
> (CCL::save-application "foo"
>    :toplevel-function #'main
>    :error-handler :quit)
>
> When I then cause my program to generate an error, e.g., by literally
> calling (error "something is wrong."), instead of quitting I see the
> following message:
>
>     > Error: something is wrong.
>     > While executing: function-that-calls-error, in process toplevel(2).
>
>    ;;;
>    ;;; #<PROCESS toplevel(2) [ACTIVE] #x300040F77C6D> requires access
> to Shared Terminal Input
>    ;;; Type (:y 2) to yield con
>
> The message literally stops right there.  I can Control+C out into a
> break loop, and from there I can quit.
>
> Anyway, I had expected it to quit instead.
>
> Is there an easy way to get the program to simply quit if there is any
> call of (error ...) encountered?
>
> Thanks!
> Jared
>
>
> -- 
> Jared C. Davis <jared at cs.utexas.edu>
> 11410 Windermere Meadows
> Austin, TX 78759
> http://www.cs.utexas.edu/users/jared/
> _______________________________________________
> Openmcl-devel mailing list
> Openmcl-devel at clozure.com
> http://clozure.com/mailman/listinfo/openmcl-devel
>
>



More information about the Openmcl-devel mailing list