Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed code point decoding #4

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Conversation

sagotch
Copy link

@sagotch sagotch commented Nov 6, 2019

Hi.

I debugged and "fixed" (by copying/pasting code from Yojson) the unicode code point decoding.

Prior to this PR, this is the behavior of jsonaf:

match Jsonaf.of_string {| { "foo": "\u00E9" } |} with
| Ok (`Object ["foo", `String s]) -> s
| _ -> assert false ;;
- : string = "�"
match Jsonaf.of_string {| { "foo": "\u00E9" } |} with
| Ok (`Object ["foo", `String s]) -> s
| _ -> assert false ;;
- : string = "é"

\u00E9 is é (cf: http://www.fileformat.info/info/unicode/char/e9/index.htm)


Also, I upgrade the build to use recent versions of dune. I am not sure about what is done in opam file, but dune upgrade is responsible for this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant