diff --git a/om/json/README.md b/om/json/README.md index 17a8bed..e5f1a19 100644 --- a/om/json/README.md +++ b/om/json/README.md @@ -92,8 +92,8 @@ syntax state: punctuation/field sequencing is the caller's responsibility. canonicalization scheme. Output can exceed the input size and fail explicitly. String output matches Go `json.Marshal(string)`: standard short control escapes, lowercase `\u` -hex, HTML escapes for `<`, `>` and `&`, and escapes for U+2028/U+2029. Invalid UTF-8 becomes -`\ufffd`; a valid U+FFFD scalar remains literal UTF-8, matching Go. Internal helpers all have the +hex, HTML escapes for `<`, `>` and `&`, and escapes for U+2028/U+2029. Invalid UTF-8 becomes the replacement character as raw UTF-8 bytes; a valid +U+FFFD scalar is written the same way, matching Go. Internal helpers all have the `json` prefix; callers should use the APIs above. ## Focused tests diff --git a/om/json/json.om b/om/json/json.om index 9812919..1038cec 100644 --- a/om/json/json.om +++ b/om/json/json.om @@ -650,7 +650,7 @@ p = jsonuesc o p v end else if and eq v 65533 eq get r 1 1 -p = jsonuesc o p v +p = jsonrune o p v else p = jsonrune o p v end