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

Re: How to correctly spec sequences requiring an iterable

From: Brendan Eich <brendan@mozilla.org>
Date: Fri, 15 Nov 2013 10:12:00 -0800
Message-Id: <D493B77D-B58B-48F0-9CAF-EAD3E0AFA512@mozilla.org>
Cc: Allen Wirfs-Brock <allen@wirfs-brock.com>, Boris Zbarsky <bzbarsky@MIT.EDU>, Jason Orendorff <jason.orendorff@gmail.com>, "public-script-coord@w3.org" <public-script-coord@w3.org>
To: Domenic Denicola <domenic@domenicdenicola.com>
Jason should weigh in, but I favor for-of working on strings. They are array-like albeit frozen.

On null or undefined, I see no need for the null disjunct. Precedent outside of null == undefined is lacking - particularly for a protocol (interface) test of this kind.


> On Nov 15, 2013, at 9:58 AM, Domenic Denicola <domenic@domenicdenicola.com> wrote:
> From: Allen Wirfs-Brock <allen@wirfs-brock.com>
>> As current spec'ed  GetIterator("primitiveString") does in fact work with primitive strings.  So, any conditional Iterable test also needs to consider a primitive string to be an Iterable. This isn't currently correctly handled in the ES6 spec.  It's a new bug that I will fix.
> Sorry, I wasn't quite clear---what do you consider correct, and what do you consider a bug? Is `for`-`of` supposed to work with strings? What about `Array.from`? What about `Promise.all`?
Received on Friday, 15 November 2013 18:12:34 UTC

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