JSON2.jl icon indicating copy to clipboard operation
JSON2.jl copied to clipboard

UTF-16 parsing problem

Open samoconnor opened this issue 5 years ago • 0 comments

Applying the correctness tests in LazyJSON.jl/test/runtests.jl to JSON2 reveals some issues with UTF-16 parsing. e.g.

github.com/nst/JSONTestSuite.JSON2.jl: Test Failed at /Users/sam/.julia/dev/LazyJSON/test/runtests.jl:442
  Expression: jparse("[\"\\uD834\\uDd1e\"]") == Any["𝄞"]
   Evaluated: Any["頴訊"] == Any["𝄞"]
github.com/nst/JSONTestSuite.JSON2.jl: Test Failed at /Users/sam/.julia/dev/LazyJSON/test/runtests.jl:447
  Expression: jparse("[\"\\u0061\\u30af\\u30EA\\u30b9\"]") == Any["aクリス"]
   Evaluated: Any["a䁛䂖㽹"] == Any["aクリス"]
github.com/nst/JSONTestSuite.JSON2.jl: Test Failed at /Users/sam/.julia/dev/LazyJSON/test/runtests.jl:448
  Expression: jparse("[\"new\\u000Aline\"]") == Any["new\nline"]
   Evaluated: Any["newöline"] == Any["new\nline"]
github.com/nst/JSONTestSuite.JSON2.jl: Test Failed at /Users/sam/.julia/dev/LazyJSON/test/runtests.jl:451
  Expression: jparse("[\"\\u005C\"]") == Any["\\"]
   Evaluated: Any["ň"] == Any["\\"]

samoconnor avatar Nov 05 '18 03:11 samoconnor