]> git.eshelyaron.com Git - emacs.git/commit
Make json-serialize always return a unibyte string (bug#70007)
authorMattias EngdegÄrd <mattiase@acm.org>
Sun, 8 Sep 2024 18:02:34 +0000 (20:02 +0200)
committerEshel Yaron <me@eshelyaron.com>
Sat, 14 Sep 2024 20:15:07 +0000 (22:15 +0200)
commit16d738e2c53dd0e3b4573bb978237119f79eab9d
tree99d3b05b2a496c0c3825fc582688d14d19dbe542
parent4fb87730b008348f14f3e4a1901abdefbfafc6e0
Make json-serialize always return a unibyte string (bug#70007)

The JSON format is defined as a byte sequence and will always be used as
such, so returning a multibyte string makes little sense.

* src/json.c (json_out_to_string): Remove.
(Fjson_serialize): Return unibyte string.
* test/src/json-tests.el (json-serialize/roundtrip)
(json-serialize/roundtrip-scalars, json-serialize/string):
Update tests.
* doc/lispref/text.texi (Parsing JSON): Document.
* etc/NEWS: Announce.

(cherry picked from commit e55e2e1c6baebbd105f930fa553ec65c74a3000d)
doc/lispref/text.texi
src/json.c
test/src/json-tests.el