New full Unicode for ES6 idea

Wes Garland wes at
Mon Feb 20 07:06:00 PST 2012

On 20 February 2012 09:56, Andrew Oakley <andrew at> wrote:

> While this is being discussed, for any new string handling I think we
> should make any invalid strings (according to the rules in Unicode)
> cause some kind of exception on creation.

Can you clarify which definition in the Unicode standard you are proposing
for "invalid string"?

> Most content actually only tries to access characters of a string like
> for (var i = 0; i < str.length(); i++) {
>       str[i];
> }

Does anybody have any data on this?  I'm genuinely curious about how much
code "on the web" does any kind of character access on strings; the only
common use-case that comes to mind (other than wanting uint16[]) is users
who are doing UTF-16 on top of UCS-2.


Wesley W. Garland
Director, Product Development
PageMail, Inc.
+1 613 542 2787 x 102
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the es-discuss mailing list