summaryrefslogtreecommitdiff
path: root/ReleaseNotes.md
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@lukeshu.com>2023-02-14 22:36:25 -0700
committerLuke Shumaker <lukeshu@lukeshu.com>2023-02-18 22:45:54 -0700
commitdfc67cecbd95344d296c31b537fa3ae8aec8c292 (patch)
tree1e2e820cbd288d1ebef7b0e9dea14a07e2f33fc5 /ReleaseNotes.md
parent38989a9c4f69abfe04c3eb4ec3382be88802141c (diff)
encode, reencode: Fix handling of invalid UTF-8
Diffstat (limited to 'ReleaseNotes.md')
-rw-r--r--ReleaseNotes.md24
1 files changed, 24 insertions, 0 deletions
diff --git a/ReleaseNotes.md b/ReleaseNotes.md
index d9a671a..b1647da 100644
--- a/ReleaseNotes.md
+++ b/ReleaseNotes.md
@@ -19,10 +19,34 @@
- Unicode:
+ + Feature: Encoder, ReEncoder: Add an `InvalidUTF8`
+ ReEncoderConfig option and `BackslashEscapeRawByte`
+ BackslashEscapeMode to allow emitted strings to contain
+ invalid UTF-8.
+
+ + Change: EscapeDefault, EscapeDefaultNonHTMLSafe: No longer
+ force long Unicode `\uXXXX` sequences for the U+FFFD Unicode
+ replacement character.
+
+ + Change: Encoder: Unless overridden by the BackslashEscaper,
+ now by default uses `\uXXXX` sequences when emitting the
+ U+FFFD Unicode replacement character in place of invalid
+ UTF-8.
+
+ Bugfix: Encoder, ReEncoder: Fix an issue with decoding UTF-8
that when a codepoint straddles a write boundary it is
interpreted as a sequence of U+FFFD runes.
+ + Bugfix: compat/json.Valid: Do not consider JSON containing
+ invalid UTF-8 to be valid (this is different than
+ `encoding/json` at the time of this writing; but I consider
+ that to be a bug in `encoding/json`; [go#58517][]).
+
+ + Bugfix: compat/json.Compact, compat/json.Indent: Don't munge
+ invalid UTF-8 in strings; as `encoding/json` doesn't.
+
+ [go#58517]: https://github.com/golang/go/issues/58517
+
# v0.3.6 (2023-02-16)
Theme: Architectural improvements