Permalink
Browse files

unicode hex digits for json

  • Loading branch information...
1 parent add34cc commit b1b7b871980a3a4d3006cb73cfe4e3c445698d92 @chjj chjj committed Oct 17, 2011
Showing with 12 additions and 0 deletions.
  1. +12 −0 lib/json.js
View
@@ -295,6 +295,18 @@ Parser.prototype._parse = function(data) {
case '7':
case '8':
case '9':
+ case 'a':
+ case 'A':
+ case 'b':
+ case 'B':
+ case 'c':
+ case 'C':
+ case 'd':
+ case 'D':
+ case 'e':
+ case 'E':
+ case 'f':
+ case 'F':
this.unicode += ch;
if (this.unicode.length === 4) {
this.unicode = parseInt(this.unicode, 16);

0 comments on commit b1b7b87

Please sign in to comment.