W3C home > Mailing lists > Public > public-html-bugzilla@w3.org > May 2011

[Bug 11857] getData() with no or too many arguments should throw

From: <bugzilla@jessica.w3.org>
Date: Sun, 08 May 2011 23:56:41 +0000
To: public-html-bugzilla@w3.org
Message-Id: <E1QJDq5-0000hI-3w@jessica.w3.org>
http://www.w3.org/Bugs/Public/show_bug.cgi?id=11857

--- Comment #7 from Cameron McCormack <cam@mcc.id.au> 2011-05-08 23:56:40 UTC ---
(In reply to comment #6)
> A related question - JS only - is how methods behave if
> they are called with an unexpected this object. There is no IDL attribute to
> indicate whether i.e. "window.alert.call(document, 'Do you see this alert?')"
> should throw? But now I'm off-topic..

You're right, Web IDL doesn't make this throw.  I thought I had wording in
there to make it throw, but I can't see any.  I think there should be a step in
http://dev.w3.org/2006/webapi/WebIDL/#es-operations that checks that the this
object is of the right type and throws a TypeError if it is not.  Filed bug
12635 for that.

-- 
Configure bugmail: http://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
Received on Sunday, 8 May 2011 23:56:42 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 16:31:09 UTC