Unicode support in new ES6 spec draft
ecmascript at norbertlindenberg.com
Tue Jul 17 13:11:04 PDT 2012
What's the use case for backwards iteration, in the sense of looking at all code points in a string in reverse order?
Looking at an individual code point before a given index is necessary, for example, when checking word boundaries, so I can see the need for codePointBefore.
On Jul 16, 2012, at 16:44 , Allen Wirfs-Brock wrote:
> On Jul 16, 2012, at 2:57 PM, Mark Davis ☕ wrote:
>> In order to support backwards iteration (which is sometimes used), we should have codePointBefore.
> or we can provide a backwards iterator that knows how to parse surrogate pairs:
> for (let c of str.backwards) ...
>> — Il meglio è l’inimico del bene —
> es-discuss mailing list
> es-discuss at mozilla.org
More information about the es-discuss