W3C home > Mailing lists > Public > www-dom@w3.org > July to September 2012

[Bug 19110] New: DOM "throw" algorithm doesn't seem to use WebIDL "throw" algorithm correctly

From: <bugzilla@jessica.w3.org>
Date: Fri, 28 Sep 2012 11:33:04 +0000
To: www-dom@w3.org
Message-ID: <bug-19110-4009@http.www.w3.org/Bugs/Public/>
https://www.w3.org/Bugs/Public/show_bug.cgi?id=19110

           Summary: DOM "throw" algorithm doesn't seem to use WebIDL
                    "throw" algorithm correctly
           Product: WebAppsWG
           Version: unspecified
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DOM
        AssignedTo: annevk@annevk.nl
        ReportedBy: ayg@aryeh.name
         QAContact: public-webapps-bugzilla@w3.org
                CC: mike@w3.org, www-dom@w3.org


http://dom.spec.whatwg.org/#concept-throw

says to create a new DOMException, "set" its name and message to something, and
then "throw" it in the WebIDL sense.  But WebIDL's throw algorithm

http://dev.w3.org/2006/webapi/WebIDL/#es-throwing-exceptions

takes the name and message as optional arguments, not an existing exception
object.  Nothing says what it means to "set" the name and message (own
properties? inherited?).  I think the DOM algorithm needs to be rewritten to
match the WebIDL one, because currently the combination doesn't make sense to
me.  Maybe you want something like

  Throw a DOMException, with name equal to name and message equal to an
implementation-defined value.

But you need to set the code attribute somehow.

-- 
Configure bugmail: https://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
Received on Friday, 28 September 2012 11:33:11 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 28 September 2012 11:33:13 GMT