* lisp/net/tramp.el (tramp-call-process): `result' can also be nil.
* test/lisp/net/tramp-tests.el (tramp--test-timeout-handler):
Improve trace format.
* doc/emacs/dired.texi (Operating on Files): Document behavior change.
* lisp/dired-aux.el (dired-dwim-target-directories): New function.
(dired-dwim-target-directory, dired-dwim-target-defaults): Use it
to get the most recently used window instead of the next window (bug#35385).
* lisp/dired.el (dired-dwim-target): Doc fix.
* test/lisp/dired-tests.el: Remove unnecessary require and pacify
byte-compiler.
* time-stamp-tests.el: rename all the time-stamp-string formatting tests
to have the word "format" in their name, to make room in the namespace
for other, future tests.
* lisp/emacs-lisp/rx.el (rx--translate-symbol):
* test/lisp/emacs-lisp/rx-tests.el (rx-any, rx-atoms):
Use [^z-a] instead of ".\\|\n" for anychar.
The new expression is faster (about 2×) and does not allocate regexp
stack space. For example, (0+ anychar) now matches strings of any
size (bug#37659).
* lisp/emacs-lisp/rx.el (rx--translate-symbol, rx--builtin-symbols, rx):
* test/lisp/emacs-lisp/rx-tests.el (rx-atoms):
* doc/lispref/searching.texi (Rx Constructs):
* etc/NEWS:
Add `anychar', an alias for `anything'. Since `anychar' is more
descriptive (and slightly shorter), treat it as the preferred name.
* lisp/emacs-lisp/ert.el (ert--explain-equal-rec):
* test/lisp/emacs-lisp/ert-tests.el (ert-test-explain-equal):
When explaining a difference between a unibyte and a multibyte string,
first convert both to multibyte. Otherwise, we might end up comparing
unibyte char C to multibyte char C, 127<C<256, and not detect the
difference (bug#30219).
* time-stamp.el (time-stamp): Reformat the explanation of the
variables that affect time-stamp, for easier reading. In particular,
wrap the documentation to 75 characters, so that it displays neatly as
a before-save-hook customization option.
* time-stamp-tests.el (with-time-stamp-test-env): Use imperative voice,
per checkdoc.
(map--into-hash): New function, extracted from `map-into <hash-table>`.
Speed it up a bit by using gethash instead of map-elt when we know
we're accessing a hash table.
* test/lisp/emacs-lisp/map-tests.el (test-map-into): Add corresponding test.
* time-stamp.el (time-stamp-string-preprocess): Revert change to "%04y"
format made 2 weeks ago by commit 0e56883878 (the previous commit to
this file). Although undocumented, "%04y" was discovered to be in use
in the wild (2016) and had not issued a warning that it would change.
Add a warning that it will change.
* time-stamp-tests.el (time-stamp-test-year-2digit): add test of "%04y"
* time-stamp-tests.el (time-stamp-test-year): break into two tests,
time-stamp-test-year-2digit and time-stamp-test-year-4digit. Expand
time-stamp-test-year-2digit to look more like tests for other 2-digit
conversions.
* lisp/emacs-lisp/package.el (package-menu-filter-by-name): New
function to filter packages by name.
(package-menu-clear-filter): New function to clear applied filters.
(package-menu-filter-by-keyword): Rename function from
package-menu-filter.
(package-menu--generate): Don't change 'q' binding anymore.
(package-menu-mode-map): Bind '/ n' to package-menu-filter-by-name, '/
k' to package-menu-filter-by-keyword and '/ /' to
package-menu-clear-filter.
(package-menu-mode-menu): Update menu entries for the three functions.
* test/lisp/emacs-lisp/package-tests.el (package-test-list-filter-by-name)
(package-test-list-clear-filter): New tests.
* doc/emacs/package.texi: Document usage of
package-menu-filter-by-name, package-menu-clear-filter and update
reference to package-menu-filter-by-keyword.
* etc/NEWS: Announce changes.
* lisp/calendar/iso8601.el (iso8601--year-match)
(iso8601--full-date-match, iso8601--without-day-match)
(iso8601--week-date-match, iso8601--ordinal-date-match)
(iso8601-parse-date):
Don’t bother to separate the year’s sign from the year,
as that distinction is not needed: ISO 8601 uses
astronomical year numbering with a year zero, which
is what the Emacs time functions use, so there’s no
need to treat nonpositive years specially.
(iso8601--adjust-year): Remove; no longer needed
since callers can just use string-to-number.
* test/lisp/calendar/iso8601-tests.el (test-iso8601-date-years):
Adjust test case to match fixed behavior.
* lisp/progmodes/compile.el (compilation-error-regexp-alist-alist):
Match GNU make error messages.
* test/lisp/progmodes/compile-tests.el (compile-tests--test-regexps-data):
Test GNU make error message matching.
(compile-test-error-regexps): Update count of infos found.
* lisp/progmodes/compile.el (compilation-error-regexp-alist-alist):
Fix a mistake introduced when the regexp was translated to rx.
* test/lisp/progmodes/compile-tests.el (compile-tests--test-regexps-data)
(compile-test-error-regexps): Add test case.
* etc/compilation.txt: Add example.
* test/lisp/progmodes/compile-tests.el (compile-test-error-regexps):
Don't rely on compilation-num-errors (etc) all being zero, which they
aren't if the test has been run before.
(compile-tests--test-regexps-data): Change defvar to defconst.
The last change to forward-button added support for help-echo values
that are functions. This patch fixes the arguments passed to such
functions and further adds support for help-echo values that are
forms (bug#37515).
* doc/lispref/display.texi (Button Properties): Fix description of
help-echo button property.
* lisp/button.el (button--help-echo): New function.
(forward-button): Use it.
(backward-button): Clarify help-echo reference in docstring.
* test/lisp/button-tests.el (button--help-echo-string)
(button--help-echo-form, button--help-echo-function): New tests.
* test/lisp/shadowfile-tests.el: Change some traces.
(shadow-test-remote-temporary-file-directory): Adapt also remote
home directory.
(shadow--tests-cleanup): Cleanup Tramp.
* time-stamp.el (time-stamp-string-preprocess): Update some undocumented
formatting characters of time-stamp format for closer (still incomplete)
alignment with format-time-string. They have displayed a warning since
Emacs 20 (released in 1997), so it is unlikely anyone is using them.
* time-stamp-tests.el: Update tests to match new expectations.
* time-stamp.el (time-stamp-format, time-stamp-pattern): Update
recommended (documented) formats. No code changes, just documentation.
All recommended formats are compatible at least as far back as Emacs
22.1 (released in 2007) and are now closer to compatibility with
format-time-string.
* time-stamp-tests.el: Update test comments to match.
It was an internal symbol in the old `rx' implementation, used in old
versions of the `flycheck' package.
* lisp/emacs-lisp/rx.el (rx-submatch-n): Alias of `rx-to-string'.
* test/lisp/emacs-lisp/rx-tests.el (rx-compat): Test it.
* lisp/calc/calcalg2.el (math-try-solve-for):
To solve Ax^n=0 where A is a nonzero constant and x the variable to
solve for, solve x^n=0 instead of solving A=0 (which obviously fails)
or something equally stupid.
* test/lisp/calc/calc-tests.el (calc-test-solve-linear-system): New.
* time-stamp-tests.el: Group tests by when the format was or will be
documented. Add tests for a few more undocumented, volatile formats.
Change AM hours test time to be a different hour from PM test time.
(Making these changes to the tests now will minimize test changes
needed later with anticipated code changes.)
* lisp/cus-edit.el (custom-comment-show): Add docstring. Save the
widget value in the :shown-value property, before redrawing.
(custom-variable-modified-p): New function, to complement the return
values of custom-variable-state.
(custom-variable-state-set): Use it.
(custom-face-value-create): Add children to the custom-face widget
before setting the state, to be able to check for user edits.
(custom-face-state-set): Check for user edits before calling
custom-face-state (bug#5358).
* test/lisp/custom-tests.el
(custom-test-show-comment-preserves-changes): New test.
* lisp/wid-edit.el (widget 'other): Use \n instead of the %n escape in the
:format property of this widget. If %n is used at the end of the
format string, unrelated widgets get indented. (Bug#12533)
* test/wid-edit-tests.el (widget-test-indentation-after-%n)
(widget-test-indentation-after-newline)
(widget-test-newline-and-indent-same-widget): New tests.
* test/lisp/net/tramp-tests.el (tramp--test-ksh-p): New defun.
(tramp-test41-utf8, tramp-test41-utf8-with-stat)
(tramp-test41-utf8-with-perl, tramp-test41-utf8-with-ls):
Skip, when remote shell is ksh.