Subj : Re: JS Shell: throw {} To : netscape.public.mozilla.jseng From : Martin Honnen Date : Sun Dec 26 2004 12:39 pm Christian Biesinger wrote: > I was playing around a bit with js shell... I noticed this: > js> throw {} > can't convert undefined to an integer > > Is this the expected result? I was expecting something along the lines > of "uncaught exception: object", maybe even "uncaught exception: {}" > > > A second issue: > js> throw { toString: function() { return "foo" } } > can't convert undefined to an integer Seems like a bug to me, I get the same results with the xpcshell.exe coming with some Mozilla 1.8 nightly downloaded this month. If I put that code into a script section in a HTML page that nightly even crashes on me. I will download the latest nightly and see if that crashes too. -- Martin Honnen http://JavaScript.FAQTs.com/ .