<feed xmlns='http://www.w3.org/2005/Atom'>
<title>emacs/src/json.c, branch feature/igc</title>
<subtitle>Emacs is the extensible, customizable, self-documenting real-time display editor. 
</subtitle>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/'/>
<entry>
<title>Merge branch 'master' into feature/igc</title>
<updated>2026-01-02T20:01:55+00:00</updated>
<author>
<name>Helmut Eller</name>
</author>
<published>2026-01-02T20:01:55+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=e049ec683d3e504e2ae36b37500405b37a162786'/>
<id>e049ec683d3e504e2ae36b37500405b37a162786</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>; Add 2026 to copyright years.</title>
<updated>2026-01-01T12:54:34+00:00</updated>
<author>
<name>Sean Whitton</name>
</author>
<published>2026-01-01T12:54:34+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=c31f6adc31d48076c63ad82b83b2970e1b0d7b9b'/>
<id>c31f6adc31d48076c63ad82b83b2970e1b0d7b9b</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge branch 'master' into feature/igc</title>
<updated>2025-08-24T10:15:10+00:00</updated>
<author>
<name>Gerd Möllmann</name>
</author>
<published>2025-08-24T10:15:10+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=7d7ecea0eb3aaaee30aad76689d3b42ee25b5082'/>
<id>7d7ecea0eb3aaaee30aad76689d3b42ee25b5082</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Speed up JSON parsing by not maintaining line and column (bug#79192)</title>
<updated>2025-08-21T14:42:45+00:00</updated>
<author>
<name>Mattias Engdegård</name>
</author>
<published>2025-08-06T13:29:58+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=c04553f655a05810f02dd77dac4f544018158e94'/>
<id>c04553f655a05810f02dd77dac4f544018158e94</id>
<content type='text'>
We use the current parsing position instead.  The line and column in the
error weren't used (nor very accurate to begin with) and the user can
easily compute them when needed.  The line number calculation is kept
just in case but deprecated, for removal in Emacs 32.

* src/json.c (struct json_parser, json_parser_init): Update parser state.
(json_signal_error): New position computation.
(json_skip_whitespace_internal): Remove.
(is_json_whitespace): New.
(json_skip_whitespace, json_skip_whitespace_if_possible)
(json_parse_unicode, json_parse_string, json_parse_number)
(json_parse_value): Simplify and rewrite for efficiency.
(count_chars, count_newlines)
(string_byte_to_pos, string_byte_to_line)
(buffer_byte_to_pos, buffer_byte_to_line): New.
(Fjson_parse_string, Fjson_parse_buffer): Adapt to new parser state.
* test/src/json-tests.el (json-tests--parse-string-error-pos)
(json-tests--parse-buffer-error-pos, json-parse-error-position): New.
* etc/NEWS: Note deprecation of line and column.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We use the current parsing position instead.  The line and column in the
error weren't used (nor very accurate to begin with) and the user can
easily compute them when needed.  The line number calculation is kept
just in case but deprecated, for removal in Emacs 32.

* src/json.c (struct json_parser, json_parser_init): Update parser state.
(json_signal_error): New position computation.
(json_skip_whitespace_internal): Remove.
(is_json_whitespace): New.
(json_skip_whitespace, json_skip_whitespace_if_possible)
(json_parse_unicode, json_parse_string, json_parse_number)
(json_parse_value): Simplify and rewrite for efficiency.
(count_chars, count_newlines)
(string_byte_to_pos, string_byte_to_line)
(buffer_byte_to_pos, buffer_byte_to_line): New.
(Fjson_parse_string, Fjson_parse_buffer): Adapt to new parser state.
* test/src/json-tests.el (json-tests--parse-string-error-pos)
(json-tests--parse-buffer-error-pos, json-parse-error-position): New.
* etc/NEWS: Note deprecation of line and column.
</pre>
</div>
</content>
</entry>
<entry>
<title>Require an explicit label for igc_xalloc_lisp_objs_exact</title>
<updated>2025-06-18T19:59:30+00:00</updated>
<author>
<name>Helmut Eller</name>
</author>
<published>2025-06-18T08:25:30+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=ac73794b43d440d34689293f4152ea38a42bb07a'/>
<id>ac73794b43d440d34689293f4152ea38a42bb07a</id>
<content type='text'>
This makes igc-roots-stats a bit more useful.

* src/igc.h (igc_xalloc_lisp_objs_exact): Add label argument.
* src/igc.c (igc_xalloc_lisp_objs_exact): Pass the label along.
* src/xfaces.c (init_xfaces): Specify a label.
* src/json.c (json_make_object_workspace_for_slow_path): Specify a label.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This makes igc-roots-stats a bit more useful.

* src/igc.h (igc_xalloc_lisp_objs_exact): Add label argument.
* src/igc.c (igc_xalloc_lisp_objs_exact): Pass the label along.
* src/xfaces.c (init_xfaces): Specify a label.
* src/json.c (json_make_object_workspace_for_slow_path): Specify a label.
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge branch 'master' into feature/igc</title>
<updated>2025-05-01T12:59:07+00:00</updated>
<author>
<name>Pip Cet</name>
</author>
<published>2025-05-01T12:59:07+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=fc555a37722b802adc338617f33c0417fa87d6ec'/>
<id>fc555a37722b802adc338617f33c0417fa87d6ec</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Pacify GCC 15 -Wunterminated-string-initialization</title>
<updated>2025-04-20T02:31:26+00:00</updated>
<author>
<name>Paul Eggert</name>
</author>
<published>2025-04-20T02:22:37+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=e2fb12a40ca2b90dfedbfe916ed8a87345ca89f1'/>
<id>e2fb12a40ca2b90dfedbfe916ed8a87345ca89f1</id>
<content type='text'>
* src/fns.c (hexbuf_digest):
* src/json.c (json_out_string):
Add ATTRIBUTE_NONSTRING to character arrays that are not strings.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* src/fns.c (hexbuf_digest):
* src/json.c (json_out_string):
Add ATTRIBUTE_NONSTRING to character arrays that are not strings.
</pre>
</div>
</content>
</entry>
<entry>
<title>Avoid name clashes with static GnuTLS</title>
<updated>2025-04-20T02:31:26+00:00</updated>
<author>
<name>Paul Eggert</name>
</author>
<published>2025-04-20T01:44:52+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=c8eed90eb4d0583dc3463edfad176b9d3f98d11f'/>
<id>c8eed90eb4d0583dc3463edfad176b9d3f98d11f</id>
<content type='text'>
Work around a bug in GnuTLS 3.7.11 and earlier: when built
statically, its mistakenly exports symbols hash_lookup and
hash_string, which collide with Emacs symbols of the same name,
preventing temacs from linking statically.  Problem reported by
Greg A. Woods (Bug#77476).

Because GnuTLS never uses hash_lookup or hash_string this issue
ordinarily doesn’t seem to prevent temacs from linking to GnuTLS
on GNU/Linux, as it’s linked dynamically and the dynamic linker
never needs to resolve references to either symbol.  However, I
suppose a clash or bug could occur even with dynamic linking if
Emacs later loads a module that uses either symbol.

Although GnuTLS should be fixed, Emacs should link statically to
current and older GnuTLS versions in the meantime, and it should
avoid potential problems with dynamic linking.  Renaming the two
clashing names is an easy way to do this.  For consistency with
the new name for hash_lookup, also rename hash_lookup_with_hash
and hash_lookup_get_hash.

* src/fns.c (hash_find_with_hash): Rename from hash_lookup_with_hash.
(hash_find): Rename from hash_lookup.
(hash_find_get_hash): Rename from hash_lookup_get_hash.
(hash_char_array): Rename from hash_string.
All uses changed.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Work around a bug in GnuTLS 3.7.11 and earlier: when built
statically, its mistakenly exports symbols hash_lookup and
hash_string, which collide with Emacs symbols of the same name,
preventing temacs from linking statically.  Problem reported by
Greg A. Woods (Bug#77476).

Because GnuTLS never uses hash_lookup or hash_string this issue
ordinarily doesn’t seem to prevent temacs from linking to GnuTLS
on GNU/Linux, as it’s linked dynamically and the dynamic linker
never needs to resolve references to either symbol.  However, I
suppose a clash or bug could occur even with dynamic linking if
Emacs later loads a module that uses either symbol.

Although GnuTLS should be fixed, Emacs should link statically to
current and older GnuTLS versions in the meantime, and it should
avoid potential problems with dynamic linking.  Renaming the two
clashing names is an easy way to do this.  For consistency with
the new name for hash_lookup, also rename hash_lookup_with_hash
and hash_lookup_get_hash.

* src/fns.c (hash_find_with_hash): Rename from hash_lookup_with_hash.
(hash_find): Rename from hash_lookup.
(hash_find_get_hash): Rename from hash_lookup_get_hash.
(hash_char_array): Rename from hash_string.
All uses changed.
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge branch 'master' into feature/igc</title>
<updated>2025-04-05T02:31:10+00:00</updated>
<author>
<name>Gerd Möllmann</name>
</author>
<published>2025-04-05T02:31:10+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=8ece02f9f0afbf92b8efbc5c3f148827cd0d6454'/>
<id>8ece02f9f0afbf92b8efbc5c3f148827cd0d6454</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Respect narrowed buffers when parsing JSON (bug#77325)</title>
<updated>2025-03-30T11:52:07+00:00</updated>
<author>
<name>Pip Cet</name>
</author>
<published>2025-03-28T02:33:19+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=67e34f0ed8f6d3bbc78187a18f71010c70e10426'/>
<id>67e34f0ed8f6d3bbc78187a18f71010c70e10426</id>
<content type='text'>
* src/json.c (Fjson_insert): Simplify 'memcpy' argument.
(Fjson_parse_buffer): Only read to ZV, not all the way to Z.
* test/src/json-tests.el (with-all-gap-positions-in-temp-buffer):
New macro.
(json-parse-buffer/restricted): New test.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* src/json.c (Fjson_insert): Simplify 'memcpy' argument.
(Fjson_parse_buffer): Only read to ZV, not all the way to Z.
* test/src/json-tests.el (with-all-gap-positions-in-temp-buffer):
New macro.
(json-parse-buffer/restricted): New test.
</pre>
</div>
</content>
</entry>
</feed>
