unofficial mirror of guile-user@gnu.org 
 help / color / mirror / Atom feed
* Parsing eval errors
@ 2009-06-06 16:53 Chris Dennis
  2009-06-11 21:57 ` Neil Jerram
  0 siblings, 1 reply; 4+ messages in thread
From: Chris Dennis @ 2009-06-06 16:53 UTC (permalink / raw)
  To: Guile Users

Hello Guilers

Is there some code anywhere for parsing the error information caught 
from local-eval?

The following code is the best I have come up with so far, but the 
messages it produces aren't pretty:

   (define (error-handler key . args)
     (display (object->string key))
     (for-each (lambda (arg)
                 (display (_ ", arg="))
                 (display (object->string arg)))
               args)
     (newline))

   (catch #t (local-eval s-expr (the-environment))
             error-handler)

regards

Chris
-- 
Chris Dennis                                  cgdennis@btinternet.com
Fordingbridge, Hampshire, UK




^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-06-14 20:47 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-06-06 16:53 Parsing eval errors Chris Dennis
2009-06-11 21:57 ` Neil Jerram
2009-06-14 14:40   ` Chris Dennis
2009-06-14 20:47     ` Neil Jerram

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).