Re: type secure error handling



Mark Tarver wrote:

(18+) (simple-trap (/ 4 0) 7)

division by zero

Uh oh. simple-trap insists on eagerly evaluating its arguments before
doing any trapping. The Lisp code from simple-trap is

(DEFUN simple-trap (V41 V42)
(trap V41 #'(LAMBDA (Error) #'(LAMBDA (Default) Default)) V42))

Is there any nice way of defining trap which will avoid this result?

Add something like delay/force? (See R5RS.)


Pascal

--
My website: http://p-cos.net
Common Lisp Document Repository: http://cdr.eurolisp.org
Closer to MOP & ContextL: http://common-lisp.net/project/closer/
.



Relevant Pages

  • Re: Inertial-dampening systems
    ... What happens to the inside of the egg? ... >> And I'm getting around ten millivolts in the frog if a 16 tesla field ... Because the time it takes for the current in that magnet to get up to its ... I wasn't talking about an effective surface currect due to electrons ...
    (sci.physics)
  • Re: Damn you, FEDEX! or Nikon D40 lost in Springfield, MO blackhole.
    ... the 2 mp Mavica he had been using with a Nikon D40. ... After shopping around, he got me to order one for him. ... The shipper had it insured, but from what I have read it could take weeks to sort this crap out. ... You may get your insurance from FedEx and a couple weeks later they find it and deliver it. ...
    (alt.photography)
  • Re: python 3 constant
    ... is require Python to change to accommodate your need. ... Can you see the slight difference? ... Best regards, ...
    (comp.lang.python)
  • Re: The Sci-Fi Rejection Letter That Time Forgot
    ... nations have stockpiled arsenals of these incredible bombs and the time the story is set. ...
    (rec.arts.sf.written)
  • Re: Wachstumssaison Flieder
    ... Handbreit über dem Boden. ... "Fliederkrimi" am Samstag halten heute meine Nerven nicht aus. ... Dorothee ...
    (de.rec.garten)