Subj : SpiderMonkey: Errors & Exceptions - My Solution To : netscape.public.mozilla.jseng From : Brian Barnes Date : Tue Jul 05 2005 12:03 am FYI, for those that might have have this same problem with newer copies of the engine. When I encounter an error state within one of my C functions, I call JS_ReportError(). I have an error reporter set, and I clear it before I call into a script. If JS_CallFunctionValue() or JS_EvulateScript() return false, I see if the error reporter was called. If it was, then I use that data for the error, otherwise I check JS_GetPendingException() and convert that to an ErrorReport and use that. So far, this catches everything, in the same format, with the line numbers. I'm not throwing catchable exceptions, but, frankly, it's a script engine for a game I don't except a lot of try-catches, errors should be fatal errors that need to be corrected before shipping. So, I'm out of the woods on that one. Once again, FYI for those that care. [>] Brian .