This is for the purpose of receiving elpa.git build failure emails.
* dash.el: Add Maintainer header with self. Replace deprecated
Homepage header with URL.
* dev/dash-defs.el (dash--find-example-regexp): New variable.
(defexamples): Add it to each function's find-function-type-alist
property in Emacs 31+, to locate the generated ert-deftest as per
the example in Info node "(elisp) Finding Definitions".
Emacs 31 obsoletes the variables in preference to the face symbols.
* dash.el (dash--keywords): Replace obsolete font-lock variables
with corresponding face symbols. Use (MATCHER . FACESPEC) in place
of (MATCHER . SUBEXP-HIGHLIGHTER) with SUBEXP zero.
* dash.el (-concat, -copy): Include more/latest details from
upstream docstrings.
(-partial): Give it a stable docstring based on that of
apply-partially to avoid churn/annoyances for Dash developers.
* README.md:
* dash.texi: Regenerate docs.
* dash.el (dash--take): New function wrapping 'take'.
(-take, -drop-last): Use it for a speedup or less garbage on some
inputs.
(-sort): Prefer Emacs 30 'sort' calling convention when available.
* dash.el: Conditionally define Emacs 30 static-if polyfill. Use it
for choosing between gv-define-setter and defsetf. This reduces the
chances of, e.g., (x) and (val) being expanded as macros (#402).
(dash--assoc-fn, -andfn, dash-fontify-mode): Move run-time checks to
compile time. This simplifies the code a bit and reduces the need
for heavy-handed warning suppression.
Fixes#402.
Functions that guarantee a fresh return value should not be pure,
since their return value is likely to be mutated destructively:
https://bugs.gnu.org/64127
* NEWS.md (2.20.0): List affected functions.
* dash.el (-non-nil, -cons*, -snoc, -slice, -take, -take-last)
(-drop-last, -split-at, -interpose, -interleave, -repeat, -iota)
(-clone): No longer mark as pure.
* dev/examples.el (-powerset): Avoid mutating constant.
Fixes#405.
* NEWS.md (2.20.0): Announce deprecation of dyadic -zip calling
convention.
* readme-template.md (Change log): Retract promise to
break -zip (issue #400).
* dash.el (--reject-first): Pacify Emacs 24 macro #'-quoting
warning.
(-remove-at, -zip-fill): Optimize. Extend docstring.
(-remove-at-indices): Handle empty list input. Optimize. Clarify
docstring.
(--zip-with, -zip-lists): Simplify. Extend docstring.
(-zip-with): Fix docstring.
(-zip-lists-fill, -unzip-lists, dash--length=)
(dash--zip-lists-or-pair): New functions.
(-zip): Replace anonymous compiler-macro with
dash--zip-lists-or-pair for the benefit of Emacs 24.3. Use
dash--length= in place of length. Clarify docstring.
(-zip-pair): Make variadic again for backward compatibility with
when it used to be an alias of -zip, and declare a dyadic
advertised-calling-convention instead. Delegate to -zip-lists as
needed. Clarify docstring.
(-unzip): Clarify docstring (issue #400).
(dash--match-kv-normalize-match-form, -let): Simplify.
(-prodfn): Optimize.
Fixes#400.
* dash.el: Update copyright notice for 2022. Quote function symbols
as such.
(-zip-pair): No longer alias -zip.
(-zip): Rewrite in terms of -zip-pair or -zip-lists, including as a
compiler macro. Emit warning when called with two arguments.
(-unzip): Add FIXME commentary.
(-let): Prefer -zip-pair over -zip with two arguments.
(dash-fontify-mode-lighter, dash-fontify-mode)
(global-dash-fontify-mode, dash-enable-fontlock): Remove strictly
not needed :group keywords.
Re: issue #400.
Otherwise upstream changes to the docstring of append will cause
needless churn, as well as annoyances for contributors on different
Emacs versions.
* dash.el (-concat): Give it append's current upstream docstring.
* README.md:
* dash.texi: Regenerate docs.
* dash.el (-repeat): Use >= in place of natnump, for speed.
* dev/examples.el (-repeat, -cycle): Move from "Other list
operations" to "Unfolding".
* README.md:
* dash.texi: Regenerate docs.
* NEWS.md (2.19.2): Rename...
(2.20.0): ...to this. Announce changes.
* README.md:
* dash.texi: Regenerate docs.
* dash.el (-compare-fn): Clarify docstring.
(dash--member-fn, dash--hash-test-fn, dash--size+): New convenience
functions.
(dash--short-list-length): New variable.
(-distinct, -union, -intersection, -difference): Check for empty
list early. Prefer dash--member-fn over -contains? for speed.
Exclude duplicates from return value. Use a hash table for long
lists, but avoid its overhead for short lists.
(-contains?): Delegate to member if -compare-fn is either equal or
nil, not just nil. Reimplement in terms of dash--member-fn.
(-same-items?): Support multisets of different length. Use hash
tables for long lists.
* dev/examples.el (-same-items?): Move from "Predicates" to "Set
operations". Extend tests.
(-contains?, -union, -difference, -intersection, -distinct): Extend
tests.
(dash--member-fn, dash--hash-test-fn, dash--size+): New tests.
* dash.el (-first): Contrast -first with -first-item, not car, in
docstring.
(-elem-index, --find-index, --find-last-index): Avoid constructing a
list of results just to throw most of them away. Suggested by
Philippe Vaucher (#394).
(--find-indices): Use --keep for speed.
(-elem-indices, -find-indices): Use --find-indices for speed.
(-find-index, -find-last-index): Use anaphoric counterpart for
speed.
* dev/examples.el (-elem-index, -elem-indices, -find-index)
(-find-last-index, -find-indices): Extend tests.
* README.md:
* dash.texi: Regenerate docs.
Fixes#394.
* Makefile (els): Add dev/examples.el so that it's byte-compiled.
(check): Prefer dev/examples.elc over dev/examples.el.
($(docs)): Remove redundant dependency.
(dev/dash-defs.elc, dev/examples.elc): Manually list dependencies.
* dash.el: Add pure and side-effect-free to defun-declarations-alist
as no-ops when needed, to avoid warnings in Emacsen that lack them.
(--reductions): Pacify uninitialized lexvar warnings in recent
Emacsen (issue #377).
(--splice, -splice): Reimplement the function in terms of the macro
for efficiency and to avoid unused lexvar warnings. Expand
docstrings.
(--map-first, --map-last, --splice-list, --update-at, --split-when)
(--annotate, --find-indices, --find-index, --find-last-index)
(--sort, --max-by, --min-by, --fix, --unfold, --tree-mapreduce-from)
(--tree-mapreduce, --tree-map, --tree-reduce-from, --tree-reduce)
(--tree-map-nodes, --tree-seq): Pacify unused lexvar warnings.
(-value-to-list, -tree-mapreduce-from, -tree-mapreduce, -tree-map)
(-tree-reduce-from, -tree-reduce, -tree-map-nodes, -tree-seq):
Simplify slightly.
* dev/dash-defs.el: Load ert for the benefit of generated tests.
(dash--example-to-test): Remove eval needed in old Emacsen; call it
on a case-by-case basis instead.
(defexamples): Ensure ert-deftest bodies are nonempty.
(dash--describe, dash--lisp-to-md): Move defvar declarations to
top-level or else old Emacsen will complain.
* dev/examples.el: Work around https://bugs.gnu.org/14883 by
enabling byte-compile-delete-errors as needed.
(dash-expand:&hash-or-plist): Wrap in eval-when-compile.
(-splice): Extend tests.
(-map-when, -flatten-n, -list, -some-->, -when-let, -let, -let*)
(-lambda, -setq): Pacify or work around byte-compiler warnings or
errors.
* README.md:
* dash.texi: Regenerate docs.