<feed xmlns='http://www.w3.org/2005/Atom'>
<title>emacs/doc/lispref/lists.texi, branch scratch/comp-static-data</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>Improved copy-tree documentation and test (bug#63509)</title>
<updated>2023-05-19T13:50:42+00:00</updated>
<author>
<name>Mattias Engdegård</name>
</author>
<published>2023-05-19T10:32:28+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=bd6bba4780dcfdec97ab5e6469f7777c4b2a1b0d'/>
<id>bd6bba4780dcfdec97ab5e6469f7777c4b2a1b0d</id>
<content type='text'>
* etc/NEWS: Move entry since it's an incompatible change.
* lisp/emacs-lisp/shortdoc.el (vector): Make the example relevant.
* lisp/subr.el (copy-tree): Rename second argument,
since 'vector-like' is a term with a specific meaning in Emacs
but not the one intended here.
* doc/lispref/lists.texi (Building Lists): Rename second argument,
and make it clear that the input must be acyclic.
* doc/lispref/records.texi (Record Functions):
Be more precise: `copy-sequence` is used to copy records,
`copy-tree` copies trees made of records etc.
* test/lisp/subr-tests.el (subr--copy-tree): Extend and strengthen the
test considerably, using the print-circle trick to detect structure
sharing precisely.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* etc/NEWS: Move entry since it's an incompatible change.
* lisp/emacs-lisp/shortdoc.el (vector): Make the example relevant.
* lisp/subr.el (copy-tree): Rename second argument,
since 'vector-like' is a term with a specific meaning in Emacs
but not the one intended here.
* doc/lispref/lists.texi (Building Lists): Rename second argument,
and make it clear that the input must be acyclic.
* doc/lispref/records.texi (Record Functions):
Be more precise: `copy-sequence` is used to copy records,
`copy-tree` copies trees made of records etc.
* test/lisp/subr-tests.el (subr--copy-tree): Extend and strengthen the
test considerably, using the print-circle trick to detect structure
sharing precisely.
</pre>
</div>
</content>
</entry>
<entry>
<title>Make 'copy-tree' work with records</title>
<updated>2023-05-19T06:00:27+00:00</updated>
<author>
<name>Joseph Turner</name>
</author>
<published>2023-05-15T04:02:15+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=3a1285caba9cd25abaddbc541e3217e2559d79ab'/>
<id>3a1285caba9cd25abaddbc541e3217e2559d79ab</id>
<content type='text'>
* doc/lispref/lists.texi (Building Cons Cells and Lists): Document
new behavior of 'copy-tree'.
* doc/lispref/records.texi (Record Functions): Cross-reference to
lists.texi.
* etc/NEWS: Mention change.  (Bug#63509)
* lisp/emacs-lisp/shortdoc.el: Add 'copy-tree' example to vector
group.
* lisp/subr.el (copy-tree): Recurse into records as well as
vectors when optional second argument is non-nil. Rename second
argument from VECP to VECTOR-LIKE-P.
* test/lisp/subr-tests.el: Test new behavior.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* doc/lispref/lists.texi (Building Cons Cells and Lists): Document
new behavior of 'copy-tree'.
* doc/lispref/records.texi (Record Functions): Cross-reference to
lists.texi.
* etc/NEWS: Mention change.  (Bug#63509)
* lisp/emacs-lisp/shortdoc.el: Add 'copy-tree' example to vector
group.
* lisp/subr.el (copy-tree): Recurse into records as well as
vectors when optional second argument is non-nil. Rename second
argument from VECP to VECTOR-LIKE-P.
* test/lisp/subr-tests.el: Test new behavior.
</pre>
</div>
</content>
</entry>
<entry>
<title>Clarify `nconc` behaviour for dotted lists (bug#63103)</title>
<updated>2023-04-27T12:20:45+00:00</updated>
<author>
<name>Mattias Engdegård</name>
</author>
<published>2023-04-27T11:52:57+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=5ead8c5f69b0a69bac4641d5003ee422d6b67038'/>
<id>5ead8c5f69b0a69bac4641d5003ee422d6b67038</id>
<content type='text'>
* doc/lispref/lists.texi (Rearrangement): Explicitly say that dotted
lists are valid args to `nconc` and give an example.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* doc/lispref/lists.texi (Rearrangement): Explicitly say that dotted
lists are valid args to `nconc` and give an example.
</pre>
</div>
</content>
</entry>
<entry>
<title>Repair and speed up safe-copy-tree and make it internal (bug#61962)</title>
<updated>2023-03-12T17:12:18+00:00</updated>
<author>
<name>Mattias Engdegård</name>
</author>
<published>2023-03-12T16:00:25+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=75f04848a653e70f12f0e5a62b756c5bba0dd204'/>
<id>75f04848a653e70f12f0e5a62b756c5bba0dd204</id>
<content type='text'>
There is no particular requirement for safe-copy-tree so let's make it
internal for now.  The new implementation is faster and more correct.

* doc/lispref/lists.texi (Building Lists):
* etc/NEWS:  Remove doc and announcement.
* lisp/subr.el (safe-copy-tree--seen, safe-copy-tree--1)
(safe-copy-tree): Remove old version.
* lisp/emacs-lisp/bytecomp.el (bytecomp--copy-tree-seen)
(bytecomp--copy-tree-1, bytecomp--copy-tree): Add new version.
(byte-compile-initial-macro-environment): Use it.
* test/lisp/subr-tests.el (subr--safe-copy-tree):
* test/lisp/emacs-lisp/bytecomp-tests.el (bytecomp--copy-tree):
Move and improve tests.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
There is no particular requirement for safe-copy-tree so let's make it
internal for now.  The new implementation is faster and more correct.

* doc/lispref/lists.texi (Building Lists):
* etc/NEWS:  Remove doc and announcement.
* lisp/subr.el (safe-copy-tree--seen, safe-copy-tree--1)
(safe-copy-tree): Remove old version.
* lisp/emacs-lisp/bytecomp.el (bytecomp--copy-tree-seen)
(bytecomp--copy-tree-1, bytecomp--copy-tree): Add new version.
(byte-compile-initial-macro-environment): Use it.
* test/lisp/subr-tests.el (subr--safe-copy-tree):
* test/lisp/emacs-lisp/bytecomp-tests.el (bytecomp--copy-tree):
Move and improve tests.
</pre>
</div>
</content>
</entry>
<entry>
<title>safe-copy-tree.  Correct mistakes from earlier patch.</title>
<updated>2023-03-07T15:26:20+00:00</updated>
<author>
<name>Alan Mackenzie</name>
</author>
<published>2023-03-07T15:26:20+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=29f65920fb49588dd4fa29b33e7ed024afc6ffb6'/>
<id>29f65920fb49588dd4fa29b33e7ed024afc6ffb6</id>
<content type='text'>
* lisp/emacs-lisp/bytecomp.el (compile-defun): Remove unintended change.

* lisp/subr.el (safe-copy-tree--seen): Correct grammatical error in doc
string.
(safe-copy-tree): Delete hash table at end of function.

* doc/lispref/lists.texi (Building Lists): Add an "@end defun" line.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* lisp/emacs-lisp/bytecomp.el (compile-defun): Remove unintended change.

* lisp/subr.el (safe-copy-tree--seen): Correct grammatical error in doc
string.
(safe-copy-tree): Delete hash table at end of function.

* doc/lispref/lists.texi (Building Lists): Add an "@end defun" line.
</pre>
</div>
</content>
</entry>
<entry>
<title>eval-and-compile: Strip symbol positions for eval but not for compile.</title>
<updated>2023-03-07T08:00:25+00:00</updated>
<author>
<name>Alan Mackenzie</name>
</author>
<published>2023-03-07T08:00:25+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=fa83b236111ea024b75a8bb33b78a99f437a9a67'/>
<id>fa83b236111ea024b75a8bb33b78a99f437a9a67</id>
<content type='text'>
This fixes bug #61962.

* lisp/subr.el (safe-copy-tree): New function.

* lisp/emacs-lisp/bytecomp.el (byte-compile-initial-macro-environment): Amend
the entry for eval-and-compile to use safe-copy-tree and
byte-run-strip-symbol-positions for the eval part.

* doc/lispref/lists.texi (Building Lists): Document safe-copy-tree.

* etc/NEWS: Note the new function safe-copy-tree.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This fixes bug #61962.

* lisp/subr.el (safe-copy-tree): New function.

* lisp/emacs-lisp/bytecomp.el (byte-compile-initial-macro-environment): Amend
the entry for eval-and-compile to use safe-copy-tree and
byte-run-strip-symbol-positions for the eval part.

* doc/lispref/lists.texi (Building Lists): Document safe-copy-tree.

* etc/NEWS: Note the new function safe-copy-tree.
</pre>
</div>
</content>
</entry>
<entry>
<title>; Improve documentation of 'proper-list-p'</title>
<updated>2023-02-05T13:15:35+00:00</updated>
<author>
<name>Eli Zaretskii</name>
</author>
<published>2023-02-05T13:15:35+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=1dd751c3ac4e4276b461b83df7d9c4d002cf016e'/>
<id>1dd751c3ac4e4276b461b83df7d9c4d002cf016e</id>
<content type='text'>
* doc/lispref/lists.texi (Cons Cells): Add cross-reference
to 'proper-list-p' documentation.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* doc/lispref/lists.texi (Cons Cells): Add cross-reference
to 'proper-list-p' documentation.
</pre>
</div>
</content>
</entry>
<entry>
<title>Document 'plistp'</title>
<updated>2023-02-05T12:09:35+00:00</updated>
<author>
<name>Eli Zaretskii</name>
</author>
<published>2023-02-05T12:09:35+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=96181ed3f09b12c7e91ddabab5b02f0ee868fa50'/>
<id>96181ed3f09b12c7e91ddabab5b02f0ee868fa50</id>
<content type='text'>
* doc/lispref/lists.texi (Property Lists): Document 'plistp'.
(Bug#61293)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* doc/lispref/lists.texi (Property Lists): Document 'plistp'.
(Bug#61293)
</pre>
</div>
</content>
</entry>
<entry>
<title>; Add 2023 to copyright years.</title>
<updated>2023-01-01T10:31:12+00:00</updated>
<author>
<name>Eli Zaretskii</name>
</author>
<published>2023-01-01T10:31:12+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=cae528457cb862dc886a34240c9d4c73035b6659'/>
<id>cae528457cb862dc886a34240c9d4c73035b6659</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Audit some plist uses with new predicate argument</title>
<updated>2022-10-22T16:33:12+00:00</updated>
<author>
<name>Basil L. Contovounesios</name>
</author>
<published>2022-08-20T13:32:33+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=9da2efb670574b473ab864ae0456b4f1b38e680b'/>
<id>9da2efb670574b473ab864ae0456b4f1b38e680b</id>
<content type='text'>
* doc/lispref/lists.texi (Plist Access): Improve description of
default predicate.
* lisp/emacs-lisp/cl-extra.el (cl-getf, cl--set-getf): Assume
plist-member always returns a cons.
* lisp/emacs-lisp/gv.el (plist-get): Support new optional predicate
argument (bug#47425#91).
* lisp/emacs-lisp/map.el: Bump minor version.
(map--dispatch): Remove now that bug#58563 is fixed.  Break two
remaining uses out into corresponding cl-defmethods.
(map--plist-p): Add docstring.
(map--plist-has-predicate, map--plist-member-1, map--plist-member)
(map--plist-put-1, map--plist-put): New definitions for supporting
predicate argument backward compatibly.
(map-elt): Fix generalized variable getter under a
predicate (bug#58531).  Use predicate when given a plist.
(map-put): Avoid gratuitous warnings when called without the hidden
predicate argument.  Improve obsoletion message.
(map-put!): Use predicate when given a plist.
(map-contains-key): Ditto.  Declare forgotten
advertised-calling-convention (bug#58531#19).
(map--put): Group definition in file together with that of map-put!.
* lisp/files-x.el (connection-local-normalize-criteria): Simplify
using mapcan + plist-get.
* lisp/net/eudc.el (eudc--plist-member): New convenience function.
(eudc-plist-member, eudc-plist-get, eudc-lax-plist-get): Use it
instead of open-coding plist-member.
* src/fns.c (Fplist_get, plist_get, Fplist_put, plist_put): Pass the
plist element as the first argument to the predicate, for
consistency with assoc + alist-get.
(Fplist_member, plist_member): Move from widget to plist section.
Open-code the EQ case in plist_member, and call it from
Fplist_member in that case, rather than the other way around.

* test/lisp/apropos-tests.el (apropos-tests-format-plist): Avoid
polluting obarray.
* test/lisp/emacs-lisp/cl-extra-tests.el (cl-getf): Extend test with
generalized variables, degenerate plists, and improper lists.
* test/lisp/emacs-lisp/gv-tests.el: Byte-compile file; in the
meantime bug#24402 seems to have been fixed or worked around.
(gv-setter-edebug): Inhibit printing messages.
(gv-plist-get): Avoid modifying constant literals.  Also test with a
predicate argument.
* test/lisp/emacs-lisp/map-tests.el (with-maps-do): Simplify
docstring.
(test-map-elt-testfn): Rename...
(test-map-elt-testfn-alist): ...to this.  Also test with a predicate
argument.
(test-map-elt-testfn-plist, test-map-elt-gv, test-map-elt-signature)
(test-map-put!-plist, test-map-put!-signature)
(test-map-contains-key-signature, test-map-plist-member)
(test-map-plist-put): New tests.
(test-map-contains-key-testfn): Also test with a predicate argument.
(test-map-setf-alist-overwrite-key, test-map-setf-plist-insert-key)
(test-map-setf-plist-overwrite-key): Avoid modifying constant
literals.
(test-hash-table-setf-insert-key)
(test-hash-table-setf-overwrite-key): Fix indentation.
(test-setf-map-with-function): Make test more precise.
* test/lisp/net/eudc-tests.el: New file.
* test/lisp/subr-tests.el (test-plistp): Extend test with circular
list.
* test/src/fns-tests.el (test-cycle-equal, test-cycle-nconc): Move
from plist section to circular list section.
(plist-put/odd-number-of-elements): Avoid modifying constant
literals.
(plist-member/improper-list): Simplify.
(test-plist): Move to plist section.  Also test with a predicate
argument.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* doc/lispref/lists.texi (Plist Access): Improve description of
default predicate.
* lisp/emacs-lisp/cl-extra.el (cl-getf, cl--set-getf): Assume
plist-member always returns a cons.
* lisp/emacs-lisp/gv.el (plist-get): Support new optional predicate
argument (bug#47425#91).
* lisp/emacs-lisp/map.el: Bump minor version.
(map--dispatch): Remove now that bug#58563 is fixed.  Break two
remaining uses out into corresponding cl-defmethods.
(map--plist-p): Add docstring.
(map--plist-has-predicate, map--plist-member-1, map--plist-member)
(map--plist-put-1, map--plist-put): New definitions for supporting
predicate argument backward compatibly.
(map-elt): Fix generalized variable getter under a
predicate (bug#58531).  Use predicate when given a plist.
(map-put): Avoid gratuitous warnings when called without the hidden
predicate argument.  Improve obsoletion message.
(map-put!): Use predicate when given a plist.
(map-contains-key): Ditto.  Declare forgotten
advertised-calling-convention (bug#58531#19).
(map--put): Group definition in file together with that of map-put!.
* lisp/files-x.el (connection-local-normalize-criteria): Simplify
using mapcan + plist-get.
* lisp/net/eudc.el (eudc--plist-member): New convenience function.
(eudc-plist-member, eudc-plist-get, eudc-lax-plist-get): Use it
instead of open-coding plist-member.
* src/fns.c (Fplist_get, plist_get, Fplist_put, plist_put): Pass the
plist element as the first argument to the predicate, for
consistency with assoc + alist-get.
(Fplist_member, plist_member): Move from widget to plist section.
Open-code the EQ case in plist_member, and call it from
Fplist_member in that case, rather than the other way around.

* test/lisp/apropos-tests.el (apropos-tests-format-plist): Avoid
polluting obarray.
* test/lisp/emacs-lisp/cl-extra-tests.el (cl-getf): Extend test with
generalized variables, degenerate plists, and improper lists.
* test/lisp/emacs-lisp/gv-tests.el: Byte-compile file; in the
meantime bug#24402 seems to have been fixed or worked around.
(gv-setter-edebug): Inhibit printing messages.
(gv-plist-get): Avoid modifying constant literals.  Also test with a
predicate argument.
* test/lisp/emacs-lisp/map-tests.el (with-maps-do): Simplify
docstring.
(test-map-elt-testfn): Rename...
(test-map-elt-testfn-alist): ...to this.  Also test with a predicate
argument.
(test-map-elt-testfn-plist, test-map-elt-gv, test-map-elt-signature)
(test-map-put!-plist, test-map-put!-signature)
(test-map-contains-key-signature, test-map-plist-member)
(test-map-plist-put): New tests.
(test-map-contains-key-testfn): Also test with a predicate argument.
(test-map-setf-alist-overwrite-key, test-map-setf-plist-insert-key)
(test-map-setf-plist-overwrite-key): Avoid modifying constant
literals.
(test-hash-table-setf-insert-key)
(test-hash-table-setf-overwrite-key): Fix indentation.
(test-setf-map-with-function): Make test more precise.
* test/lisp/net/eudc-tests.el: New file.
* test/lisp/subr-tests.el (test-plistp): Extend test with circular
list.
* test/src/fns-tests.el (test-cycle-equal, test-cycle-nconc): Move
from plist section to circular list section.
(plist-put/odd-number-of-elements): Avoid modifying constant
literals.
(plist-member/improper-list): Simplify.
(test-plist): Move to plist section.  Also test with a predicate
argument.
</pre>
</div>
</content>
</entry>
</feed>
