[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Handler-Bind question...
- To: schmill@earhart.NOT.SET (Matt Schmill), firstname.lastname@example.org
- Subject: Re: Handler-Bind question...
- From: email@example.com (Kalman Reti)
- Date: Thu, 29 Sep 1994 15:02:50 -0500
At 17:19 9/29/94 +0000, Matt Schmill wrote:
>Hello all... I'm building an error handling macro that I want to use for a GUI
>on top of a portable application. The macro will basically be :
>(defmacro with-error-handling (&body body)
> (handler-bind ((error (condition) ...)
> (warning (condition) ...))
>the problem is that I can't differentiate clearly between the two cases;
>If there is an error, I want to jump out of the body. a throw/catch form will
> allow this. But if there's a warn, I want to finish evaluation of BODY
> _without the warning being displayed_ in the listener. I want my GUI to
> these cases without the listener displaying anything.
>handler-case has the opposite problem. I can't seem to find a way to resume the
> body if the WARNING is trapped.
>Does anyone out there have a clever solution ? If so, I'd love to hear it..
>(redefining the warn function is out of the question)
See CLTL2 page 913's description of the muffle-warning function. It is intended
for use in condition handlers to do precisely this.
>thanks in advance