incubator-couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Davis <paul.joseph.da...@gmail.com>
Subject Re: CouchDB View Unicode Document
Date Thu, 28 Apr 2011 19:56:59 GMT
On Thu, Apr 28, 2011 at 3:30 PM, Noah Diewald <noah.diewald@gmail.com> wrote:
> From what I understand, JavaScript shouldn't need to escape characters
> in the basic multilingual plane so it is strange that strings with
> characters that fall within that range are escaped. I think there is
> something wrong with that. I mean, why not escape every character if
> you need to decode the JSON just to read the strings?
>

Can someone paste some actual input/output pairs so I have a clue
what's going on.

Theoretically \uFFFF isn't a valid escape sequence last I checked
(don't get me started on 4627 idiocy).

The JSON encoder will by default escape data that is non-printable
ascii. The few special cased characters mentioned in the JSON spec are
backslash escaped (\t \n \" etc) while All other bits are escaped as
\uHHHH sequences.

Mime
View raw message