W3C home > Mailing lists > Public > public-script-coord@w3.org > April to June 2012

[Bug 17593] Figure out if something needs to be said about [[Construct]]

From: <bugzilla@jessica.w3.org>
Date: Mon, 25 Jun 2012 23:59:27 +0000
Message-Id: <E1SjJBn-0006Ed-D8@jessica.w3.org>
To: public-script-coord@w3.org
https://www.w3.org/Bugs/Public/show_bug.cgi?id=17593

Cameron McCormack <cam@mcc.id.au> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |INVALID

--- Comment #2 from Cameron McCormack <cam@mcc.id.au> 2012-06-25 23:59:28 UTC ---
Interface objects are function objects:

  http://dev.w3.org/2006/webapi/WebIDL/#interface-object

All function objects have the the default [[Construct]] behaviour that the ES
spec defines:

  http://dev.w3.org/2006/webapi/WebIDL/#dfn-function-object

This is regardless of whether there was a [Constructor] on the interface.

The default [[Construct]] behaviour is to create a new object and invoke
[[Call]]:

  http://es5.github.com/#x13.2.2

[[Call]] will throw a TypeError if the interface was not defined with a
[Constructor]:

  http://dev.w3.org/2006/webapi/WebIDL/#es-interface-call
  (scroll down to "The internal [[Call]] method ...")

-- 
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 Monday, 25 June 2012 23:59:31 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 8 May 2013 19:30:06 UTC