Closed Bug 47057 Opened 26 years ago Closed 22 years ago

document.JSError object

Categories

(Core :: DOM: Core & HTML, enhancement, P4)

enhancement

Tracking

()

RESOLVED WONTFIX
Future

People

(Reporter: numizmatyka, Unassigned)

Details

(Keywords: dom0)

There should be a document.JSError object : document.JSError.error() - returns true if JS error ocuuried document.JSErorr.line() - returns the line number with error etc.
An embedding issue. Assigning to DOM Level 0 for further triage or acceptance -
Assignee: rogerl → jst
Component: Javascript Engine → DOM Level 0
QA Contact: pschwartau → desale
This would be a non-standard extension to the document API and thus this will not happen for ns6, marking Future for now. An other possible solution to this could maybe be to add a way to access the javascript log from javascript and then the error info could be accessed that way...
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
OS: Windows 98 → All
Priority: P3 → P4
Hardware: PC → All
Target Milestone: --- → Future
Keywords: dom0
Mass-reassigning bugs to dom_bugs@netscape.com
Assignee: jst → dom_bugs
Status: ASSIGNED → NEW
Do we really want this? Isn't this what error handlers are for?
I'd say we definitely do not want this. What if multiple errors happen (which isn't too rare a situation if you have a syntax error and then call a function on the same script)? More to the point, ECMAScript Error objects already provide a boatload more information. try...catch is a friend of mine, as is the Error.prototype.stack that Brendan implemented for us. Recommend WONTFIX.
Where did this idea come from? It's a bad idea, in any case, and we shouldn't do any such thing. Pigeon-holes such as window.event (which was perpetrated on the world due to VBScript lameness, I was told) we should likewise never emulate. I'm tempted to mark INVALID, but it's not a big deal. /be
Status: NEW → RESOLVED
Closed: 22 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.