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

Re: WebIDL generated TypeErrors and promises

From: Boris Zbarsky <bzbarsky@MIT.EDU>
Date: Fri, 28 Jun 2013 11:07:29 -0400
Message-ID: <51CDA6B1.3080900@mit.edu>
To: public-script-coord@w3.org
On 6/28/13 11:01 AM, Marcos Caceres wrote:
> Ok, but this potentially breaks WebIDL… maybe kinda… I think most specs assume that WebIDL does its thing, then algorithmic prose runs.

That's how it works, yes.

> This would mean that specs that use promises need to be written as:
> [[
> When the foo(V) method is invoked:

Won't work, because that prose is not entered until after WebIDL does 
its thing.  In particular, WebIDL is what defines the [[Call]] of the JS 

If we want a different behavior here, it needs to be specified in WebIDL.

> 1. do type conversion on V as per WebIDL, and let error be any exception thrown. If an exception is thrown, run the promise's

Which promise's?  The exception is getting thrown before a promise ever 
gets created in this case.

Received on Friday, 28 June 2013 15:07:58 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 17:14:13 UTC