W3C home > Mailing lists > Public > public-webapps@w3.org > January to March 2014

Re: Push API - use parameterized Promise types

From: Boris Zbarsky <bzbarsky@MIT.EDU>
Date: Thu, 20 Mar 2014 14:11:10 -0400
Message-ID: <532B2F3E.9030804@mit.edu>
To: public-webapps@w3.org
On 3/20/14 11:39 AM, Domenic Denicola wrote:
> If you return something that doesn't match the declared return value, that's a spec bug, but it has no impact on anything.

True, though the spec bug may make the spec not implementable (e.g. in a 
UA that autogenerates code from the IDL for a statically typed language, 
the thing being returned may not be of the right type, etc).

That's a good thing, of course; better spec bugs that are caught as soon 
as you try to implement the spec than subtle ones.  ;)

Also, for callback interfaces and callbacks the behavior is reversed: 
there return values get coerced while arguments are just whatever they are.

-Boris
Received on Thursday, 20 March 2014 18:11:44 UTC

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