commit 64d2e5a7ad507642437cb0bd5e4a75823bfabe0e (HEAD, refs/remotes/origin/master) Author: Lars Ingebrigtsen Date: Tue Aug 25 10:07:08 2020 +0200 Revert previous hideshow commit Hideshow has defaults that are overridden if we look for derived modes in hs-special-modes-alist. For instance, in lisp-interaction-mode we'll choose a lookup based on parent modes, and that overrides the default (bug#43032). This reverts a415179b56f022f50138f55d231070e3d1b00697. diff --git a/etc/NEWS b/etc/NEWS index 03516bf4d3..d03153cc3f 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -876,11 +876,6 @@ window after starting). This variable defaults to nil. *** New 'diff-mode' font locking face 'diff-error'. This face is used for error messages from diff. ---- -*** 'hs-minor-mode' now heeds 'hs-special-modes-alist' for derived modes. -The settings in 'hs-special-modes-alist' now also affect modes derived -from those mentioned in that alist. - +++ *** New global mode 'global-goto-address-mode' This will enable 'goto-address-mode' in all buffers. diff --git a/lisp/progmodes/hideshow.el b/lisp/progmodes/hideshow.el index c5b9cfc2e7..625e08e4d7 100644 --- a/lisp/progmodes/hideshow.el +++ b/lisp/progmodes/hideshow.el @@ -225,8 +225,6 @@ ;;--------------------------------------------------------------------------- ;; user-configurable variables -(require 'cl-lib) - (defgroup hideshow nil "Minor mode for hiding and showing program and comment blocks." :prefix "hs-" @@ -654,9 +652,7 @@ Otherwise, guess start, end and `comment-start' regexps; `forward-sexp' function; and adjust-block-beginning function." (if (and (bound-and-true-p comment-start) (bound-and-true-p comment-end)) - (let* ((lookup (cl-assoc-if (lambda (mode) - (derived-mode-p major-mode mode)) - hs-special-modes-alist)) + (let* ((lookup (assoc major-mode hs-special-modes-alist)) (start-elem (or (nth 1 lookup) "\\s("))) (if (listp start-elem) ;; handle (START-REGEXP MDATA-SELECT) commit d494f9e81a6d11dcf6c22333cd950989b2051dff Author: Paul Eggert Date: Mon Aug 24 16:18:48 2020 -0700 Update from Gnulib This incorporates: * lib/diffseq.h, m4/inttypes.m4: Copy from Gnulib. * m4/gnulib-comp.m4: Regenerate. diff --git a/lib/diffseq.h b/lib/diffseq.h index c89363ac9e..26e10bdd04 100644 --- a/lib/diffseq.h +++ b/lib/diffseq.h @@ -51,10 +51,14 @@ EXTRA_CONTEXT_FIELDS Declarations of fields for 'struct context'. NOTE_DELETE(ctxt, xoff) Record the removal of the object xvec[xoff]. NOTE_INSERT(ctxt, yoff) Record the insertion of the object yvec[yoff]. + NOTE_ORDERED (Optional) A boolean expression saying that + NOTE_DELETE and NOTE_INSERT calls must be + issued in offset order. EARLY_ABORT(ctxt) (Optional) A boolean expression that triggers an early abort of the computation. USE_HEURISTIC (Optional) Define if you want to support the heuristic for large vectors. + It is also possible to use this file with abstract arrays. In this case, xvec and yvec are not represented in memory. They only exist conceptually. In this case, the list of defines above is amended as follows: @@ -63,6 +67,7 @@ XVECREF_YVECREF_EQUAL(ctxt, xoff, yoff) A three-argument macro: References xvec[xoff] and yvec[yoff] and tests these elements for equality. + Before including this file, you also need to include: #include #include @@ -78,6 +83,10 @@ # define EARLY_ABORT(ctxt) false #endif +#ifndef NOTE_ORDERED +# define NOTE_ORDERED false +#endif + /* Use this to suppress gcc's "...may be used before initialized" warnings. Beware: The Code argument must not contain commas. */ #ifndef IF_LINT @@ -88,15 +97,6 @@ # endif #endif -/* As above, but when Code must contain one comma. */ -#ifndef IF_LINT2 -# if defined GCC_LINT || defined lint -# define IF_LINT2(Code1, Code2) Code1, Code2 -# else -# define IF_LINT2(Code1, Code2) /* empty */ -# endif -#endif - /* * Context of comparison operation. */ @@ -468,49 +468,89 @@ compareseq (OFFSET xoff, OFFSET xlim, OFFSET yoff, OFFSET ylim, #define XREF_YREF_EQUAL(x,y) XVECREF_YVECREF_EQUAL (ctxt, x, y) #endif - /* Slide down the bottom initial diagonal. */ - while (xoff < xlim && yoff < ylim && XREF_YREF_EQUAL (xoff, yoff)) + while (true) { - xoff++; - yoff++; - } + /* Slide down the bottom initial diagonal. */ + while (xoff < xlim && yoff < ylim && XREF_YREF_EQUAL (xoff, yoff)) + { + xoff++; + yoff++; + } - /* Slide up the top initial diagonal. */ - while (xoff < xlim && yoff < ylim && XREF_YREF_EQUAL (xlim - 1, ylim - 1)) - { - xlim--; - ylim--; - } + /* Slide up the top initial diagonal. */ + while (xoff < xlim && yoff < ylim && XREF_YREF_EQUAL (xlim - 1, ylim - 1)) + { + xlim--; + ylim--; + } - /* Handle simple cases. */ - if (xoff == xlim) - while (yoff < ylim) - { - NOTE_INSERT (ctxt, yoff); - if (EARLY_ABORT (ctxt)) - return true; - yoff++; - } - else if (yoff == ylim) - while (xoff < xlim) - { - NOTE_DELETE (ctxt, xoff); - if (EARLY_ABORT (ctxt)) - return true; - xoff++; - } - else - { - struct partition part IF_LINT2 (= { .xmid = 0, .ymid = 0 }); + /* Handle simple cases. */ + if (xoff == xlim) + { + while (yoff < ylim) + { + NOTE_INSERT (ctxt, yoff); + if (EARLY_ABORT (ctxt)) + return true; + yoff++; + } + break; + } + if (yoff == ylim) + { + while (xoff < xlim) + { + NOTE_DELETE (ctxt, xoff); + if (EARLY_ABORT (ctxt)) + return true; + xoff++; + } + break; + } + + struct partition part; /* Find a point of correspondence in the middle of the vectors. */ diag (xoff, xlim, yoff, ylim, find_minimal, &part, ctxt); /* Use the partitions to split this problem into subproblems. */ - if (compareseq (xoff, part.xmid, yoff, part.ymid, part.lo_minimal, ctxt)) - return true; - if (compareseq (part.xmid, xlim, part.ymid, ylim, part.hi_minimal, ctxt)) - return true; + OFFSET xoff1, xlim1, yoff1, ylim1, xoff2, xlim2, yoff2, ylim2; + bool find_minimal1, find_minimal2; + if (!NOTE_ORDERED + && ((xlim + ylim) - (part.xmid + part.ymid) + < (part.xmid + part.ymid) - (xoff + yoff))) + { + /* The second problem is smaller and the caller doesn't + care about order, so do the second problem first to + lessen recursion. */ + xoff1 = part.xmid; xlim1 = xlim; + yoff1 = part.ymid; ylim1 = ylim; + find_minimal1 = part.hi_minimal; + + xoff2 = xoff; xlim2 = part.xmid; + yoff2 = yoff; ylim2 = part.ymid; + find_minimal2 = part.lo_minimal; + } + else + { + xoff1 = xoff; xlim1 = part.xmid; + yoff1 = yoff; ylim1 = part.ymid; + find_minimal1 = part.lo_minimal; + + xoff2 = part.xmid; xlim2 = xlim; + yoff2 = part.ymid; ylim2 = ylim; + find_minimal2 = part.hi_minimal; + } + + /* Recurse to do one subproblem. */ + bool early = compareseq (xoff1, xlim1, yoff1, ylim1, find_minimal1, ctxt); + if (early) + return early; + + /* Iterate to do the other subproblem. */ + xoff = xoff2; xlim = xlim2; + yoff = yoff2; ylim = ylim2; + find_minimal = find_minimal2; } return false; diff --git a/m4/gnulib-comp.m4 b/m4/gnulib-comp.m4 index f3e2cc9285..d2fdbd82e7 100644 --- a/m4/gnulib-comp.m4 +++ b/m4/gnulib-comp.m4 @@ -1188,6 +1188,7 @@ AC_DEFUN([gl_FILE_LIST], [ m4/open-slash.m4 m4/open.m4 m4/pathmax.m4 + m4/pid_t.m4 m4/pipe2.m4 m4/pselect.m4 m4/pthread_sigmask.m4 diff --git a/m4/inttypes.m4 b/m4/inttypes.m4 index 28bac816b6..84b1654ea2 100644 --- a/m4/inttypes.m4 +++ b/m4/inttypes.m4 @@ -1,4 +1,4 @@ -# inttypes.m4 serial 31 +# inttypes.m4 serial 32 dnl Copyright (C) 2006-2020 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, @@ -44,7 +44,7 @@ AC_DEFUN([gl_INTTYPES_PRI_SCN], #ifdef _WIN64 LLP64 #endif - ]]), + ]]) ], [PRIPTR_PREFIX='"l"'], [PRIPTR_PREFIX='"ll"']) commit e0345b4e86154f42f47a9f7bbbf458a72bf5c06d Author: Paul Eggert Date: Mon Aug 24 13:12:51 2020 -0700 replace-buffer-contents cleanups * src/editfns.c (NOTE_DELETE, NOTE_INSERT): Avoid unnecessary parens. (Freplace_buffer_contents): Check args before returning results. Avoid integer overflow when computing too_expensive, and work even if MAX-COSTS is bignum. Call alloca and/or malloc just once, not three times. (set_bit, bit_is_set): Simplify micro-optimization by using eassume. diff --git a/src/editfns.c b/src/editfns.c index a5368c59da..7e1e24ef16 100644 --- a/src/editfns.c +++ b/src/editfns.c @@ -1900,8 +1900,8 @@ determines whether case is significant or ignored. */) sys_jmp_buf jmp; \ unsigned short quitcounter; -#define NOTE_DELETE(ctx, xoff) set_bit ((ctx)->deletions, (xoff)) -#define NOTE_INSERT(ctx, yoff) set_bit ((ctx)->insertions, (yoff)) +#define NOTE_DELETE(ctx, xoff) set_bit ((ctx)->deletions, xoff) +#define NOTE_INSERT(ctx, yoff) set_bit ((ctx)->insertions, yoff) #define EARLY_ABORT(ctx) compareseq_early_abort (ctx) struct context; @@ -1954,6 +1954,28 @@ nil. */) if (a == b) error ("Cannot replace a buffer with itself"); + ptrdiff_t too_expensive; + if (NILP (max_costs)) + too_expensive = 1000000; + else if (FIXNUMP (max_costs)) + too_expensive = clip_to_bounds (0, XFIXNUM (max_costs), PTRDIFF_MAX); + else + { + CHECK_INTEGER (max_costs); + too_expensive = NILP (Fnatnump (max_costs)) ? 0 : PTRDIFF_MAX; + } + + struct timespec time_limit = make_timespec (0, -1); + if (!NILP (max_secs)) + { + struct timespec + tlim = timespec_add (current_timespec (), + lisp_time_argument (max_secs)), + tmax = make_timespec (TYPE_MAXIMUM (time_t), TIMESPEC_HZ - 1); + if (timespec_cmp (tlim, tmax) < 0) + time_limit = tlim; + } + ptrdiff_t min_a = BEGV; ptrdiff_t min_b = BUF_BEGV (b); ptrdiff_t size_a = ZV - min_a; @@ -1983,36 +2005,24 @@ nil. */) ptrdiff_t count = SPECPDL_INDEX (); - /* FIXME: It is not documented how to initialize the contents of the - context structure. This code cargo-cults from the existing - caller in src/analyze.c of GNU Diffutils, which appears to - work. */ ptrdiff_t diags = size_a + size_b + 3; + ptrdiff_t del_bytes = size_a / CHAR_BIT + 1; + ptrdiff_t ins_bytes = size_b / CHAR_BIT + 1; ptrdiff_t *buffer; + ptrdiff_t bytes_needed; + if (INT_MULTIPLY_WRAPV (diags, 2 * sizeof *buffer, &bytes_needed) + || INT_ADD_WRAPV (del_bytes + ins_bytes, bytes_needed, &bytes_needed)) + memory_full (SIZE_MAX); USE_SAFE_ALLOCA; - SAFE_NALLOCA (buffer, 2, diags); + buffer = SAFE_ALLOCA (bytes_needed); + unsigned char *deletions_insertions = memset (buffer + 2 * diags, 0, + del_bytes + ins_bytes); - if (NILP (max_costs)) - XSETFASTINT (max_costs, 1000000); - else - CHECK_FIXNUM (max_costs); - - struct timespec time_limit = make_timespec (0, -1); - if (!NILP (max_secs)) - { - struct timespec - tlim = timespec_add (current_timespec (), - lisp_time_argument (max_secs)), - tmax = make_timespec (TYPE_MAXIMUM (time_t), TIMESPEC_HZ - 1); - if (timespec_cmp (tlim, tmax) < 0) - time_limit = tlim; - } - - /* Micro-optimization: Casting to size_t generates much better - code. */ - ptrdiff_t del_bytes = (size_t) size_a / CHAR_BIT + 1; - ptrdiff_t ins_bytes = (size_t) size_b / CHAR_BIT + 1; + /* FIXME: It is not documented how to initialize the contents of the + context structure. This code cargo-cults from the existing + caller in src/analyze.c of GNU Diffutils, which appears to + work. */ struct context ctx = { .buffer_a = a, .buffer_b = b, @@ -2020,16 +2030,14 @@ nil. */) .beg_b = min_b, .a_unibyte = BUF_ZV (a) == BUF_ZV_BYTE (a), .b_unibyte = BUF_ZV (b) == BUF_ZV_BYTE (b), - .deletions = SAFE_ALLOCA (del_bytes), - .insertions = SAFE_ALLOCA (ins_bytes), + .deletions = deletions_insertions, + .insertions = deletions_insertions + del_bytes, .fdiag = buffer + size_b + 1, .bdiag = buffer + diags + size_b + 1, .heuristic = true, - .too_expensive = XFIXNUM (max_costs), + .too_expensive = too_expensive, .time_limit = time_limit, }; - memclear (ctx.deletions, del_bytes); - memclear (ctx.insertions, ins_bytes); /* compareseq requires indices to be zero-based. We add BEGV back later. */ @@ -2074,8 +2082,8 @@ nil. */) /* Check whether there is a change (insertion or deletion) before the current position. */ - if ((i > 0 && bit_is_set (ctx.deletions, i - 1)) || - (j > 0 && bit_is_set (ctx.insertions, j - 1))) + if ((i > 0 && bit_is_set (ctx.deletions, i - 1)) + || (j > 0 && bit_is_set (ctx.insertions, j - 1))) { ptrdiff_t end_a = min_a + i; ptrdiff_t end_b = min_b + j; @@ -2117,21 +2125,15 @@ nil. */) static void set_bit (unsigned char *a, ptrdiff_t i) { - eassert (i >= 0); - /* Micro-optimization: Casting to size_t generates much better - code. */ - size_t j = i; - a[j / CHAR_BIT] |= (1 << (j % CHAR_BIT)); + eassume (0 <= i); + a[i / CHAR_BIT] |= (1 << (i % CHAR_BIT)); } static bool bit_is_set (const unsigned char *a, ptrdiff_t i) { - eassert (i >= 0); - /* Micro-optimization: Casting to size_t generates much better - code. */ - size_t j = i; - return a[j / CHAR_BIT] & (1 << (j % CHAR_BIT)); + eassume (0 <= i); + return a[i / CHAR_BIT] & (1 << (i % CHAR_BIT)); } /* Return true if the characters at position POS_A of buffer commit 08a6d14e4116c74284c12dd1319780afbcbbfd1d Author: Paul Eggert Date: Mon Aug 24 13:12:51 2020 -0700 Fix replace-region-contents performance bug * src/editfns.c (rbc_quitcounter): Remove; the quitcounter is now part of the context. (EXTRA_CONTEXT_FIELDS): Remove unused member early_abort_tests. Add jmp, quitcounter. (Freplace_buffer_contents): Use setjmp/longjmp to recover from a compareseq that runs too long. Omit unnecessary rarely_quit call. (buffer_chars_equal): Occasionally check for early abort and longjmp out if so (Bug#43016). diff --git a/src/editfns.c b/src/editfns.c index 949f3825a3..a5368c59da 100644 --- a/src/editfns.c +++ b/src/editfns.c @@ -1877,9 +1877,6 @@ determines whether case is significant or ignored. */) #undef EQUAL #define USE_HEURISTIC -/* Counter used to rarely_quit in replace-buffer-contents. */ -static unsigned short rbc_quitcounter; - #define XVECREF_YVECREF_EQUAL(ctx, xoff, yoff) \ buffer_chars_equal ((ctx), (xoff), (yoff)) @@ -1900,7 +1897,8 @@ static unsigned short rbc_quitcounter; unsigned char *deletions; \ unsigned char *insertions; \ struct timespec time_limit; \ - unsigned int early_abort_tests; + sys_jmp_buf jmp; \ + unsigned short quitcounter; #define NOTE_DELETE(ctx, xoff) set_bit ((ctx)->deletions, (xoff)) #define NOTE_INSERT(ctx, yoff) set_bit ((ctx)->insertions, (yoff)) @@ -2029,14 +2027,17 @@ nil. */) .heuristic = true, .too_expensive = XFIXNUM (max_costs), .time_limit = time_limit, - .early_abort_tests = 0 }; memclear (ctx.deletions, del_bytes); memclear (ctx.insertions, ins_bytes); /* compareseq requires indices to be zero-based. We add BEGV back later. */ - bool early_abort = compareseq (0, size_a, 0, size_b, false, &ctx); + bool early_abort; + if (! sys_setjmp (ctx.jmp)) + early_abort = compareseq (0, size_a, 0, size_b, false, &ctx); + else + early_abort = true; if (early_abort) { @@ -2046,8 +2047,6 @@ nil. */) return Qnil; } - rbc_quitcounter = 0; - Fundo_boundary (); bool modification_hooks_inhibited = false; record_unwind_protect_excursion (); @@ -2071,8 +2070,7 @@ nil. */) walk backwards, we don’t have to keep the positions in sync. */ while (i >= 0 || j >= 0) { - /* Allow the user to quit if this gets too slow. */ - rarely_quit (++rbc_quitcounter); + rarely_quit (++ctx.quitcounter); /* Check whether there is a change (insertion or deletion) before the current position. */ @@ -2087,8 +2085,6 @@ nil. */) while (j > 0 && bit_is_set (ctx.insertions, j - 1)) --j; - rarely_quit (rbc_quitcounter++); - ptrdiff_t beg_a = min_a + i; ptrdiff_t beg_b = min_b + j; eassert (beg_a <= end_a); @@ -2108,7 +2104,6 @@ nil. */) } SAFE_FREE_UNBIND_TO (count, Qnil); - rbc_quitcounter = 0; if (modification_hooks_inhibited) { @@ -2155,12 +2150,16 @@ static bool buffer_chars_equal (struct context *ctx, ptrdiff_t pos_a, ptrdiff_t pos_b) { + if (!++ctx->quitcounter) + { + maybe_quit (); + if (compareseq_early_abort (ctx)) + sys_longjmp (ctx->jmp, 1); + } + pos_a += ctx->beg_a; pos_b += ctx->beg_b; - /* Allow the user to escape out of a slow compareseq call. */ - rarely_quit (++rbc_quitcounter); - ptrdiff_t bpos_a = ctx->a_unibyte ? pos_a : buf_charpos_to_bytepos (ctx->buffer_a, pos_a); ptrdiff_t bpos_b = commit 519fc10f121c59d6844afaf0ef0a1e1d67a2a934 Author: Lars Ingebrigtsen Date: Mon Aug 24 22:04:28 2020 +0200 Clarify sorting order by file-backup-file-names * doc/lispref/backups.texi (Backup Names): Ditto. * lisp/files.el (file-backup-file-names): Clarify sorting order. diff --git a/doc/lispref/backups.texi b/doc/lispref/backups.texi index 55b8d7215d..e14f77f9fc 100644 --- a/doc/lispref/backups.texi +++ b/doc/lispref/backups.texi @@ -417,7 +417,8 @@ version that the caller should consider deleting now. @defun file-backup-file-names filename This function returns a list of all the backup file names for @var{filename}, or @code{nil} if there are none. The files are sorted -so that the most recent backup file comes first in the list. +by modification time, descending, so that the most recent files are +first. @end defun @defun file-newest-backup filename diff --git a/lisp/files.el b/lisp/files.el index 5102585d7d..873f362dd5 100644 --- a/lisp/files.el +++ b/lisp/files.el @@ -5659,7 +5659,8 @@ like `write-region' does." (defun file-backup-file-names (filename) "Return a list of backup files for FILENAME. -The list will be sorted by newness." +The list will be sorted by modification time so that the most +recent files are first." ;; `make-backup-file-name' will get us the right directory for ;; ordinary or numeric backups. It might create a directory for ;; backups as a side-effect, according to `backup-directory-alist'. commit 517285f7caed462c822c779efe14033645dccba0 Author: Lars Ingebrigtsen Date: Mon Aug 24 21:54:56 2020 +0200 Rewrite the epa key interface to use buttons instead of widgets * lisp/epa.el (epa-font-lock-keywords): Removed. (epa-key-list-mode-map): Bind tab/backtab to button navigation. (epa-key): Remove widget. (epa--button-key-text): Return the propertized text instead of return a widget text. (epa-key-list-mode): Don't use font locking; everything is output as it should be. (epa--insert-keys): Rewrite to just output the data instead of widgetising. (epa--select-keys): Insert buttons instead of widgets. diff --git a/lisp/epa.el b/lisp/epa.el index 5140d3f0a6..3c804361c3 100644 --- a/lisp/epa.el +++ b/lisp/epa.el @@ -25,10 +25,7 @@ (require 'epg) (require 'font-lock) -(require 'widget) -(eval-when-compile - (require 'subr-x) - (require 'wid-edit)) +(eval-when-compile (require 'subr-x)) (require 'derived) ;;; Options @@ -153,14 +150,6 @@ The command `epa-mail-encrypt' uses this." ;;; Variables -(defvar epa-font-lock-keywords - '(("^\\*" - (0 'epa-mark)) - ("^\t\\([^\t:]+:\\)[ \t]*\\(.*\\)$" - (1 'epa-field-name) - (2 'epa-field-body))) - "Default expressions to addon in epa-mode.") - (defconst epa-pubkey-algorithm-letter-alist '((1 . ?R) (2 . ?r) @@ -197,8 +186,9 @@ You should bind this variable with `let', but do not set it globally.") (defvar epa-key-list-mode-map (let ((keymap (make-sparse-keymap)) (menu-map (make-sparse-keymap))) - (set-keymap-parent keymap widget-keymap) (define-key keymap "\C-m" 'epa-show-key) + (define-key keymap [?\t] 'forward-button) + (define-key keymap [backtab] 'backward-button) (define-key keymap "m" 'epa-mark-key) (define-key keymap "u" 'epa-unmark-key) (define-key keymap "d" 'epa-decrypt-file) @@ -259,48 +249,28 @@ You should bind this variable with `let', but do not set it globally.") (defvar epa-exit-buffer-function #'quit-window) -;;; Key Widget - -(define-widget 'epa-key 'push-button - "Button for representing an epg-key object." - :format "%[%v%]" - :button-face-get 'epa--key-widget-button-face-get - :value-create 'epa--key-widget-value-create - :action 'epa--key-widget-action - :help-echo 'epa--key-widget-help-echo) - -(defun epa--key-widget-action (widget &optional _event) - (save-selected-window - (epa--show-key (widget-get widget :value)))) - -(defun epa--key-widget-value-create (widget) - (let* ((key (widget-get widget :value)) - (primary-sub-key (car (epg-key-sub-key-list key))) - (primary-user-id (car (epg-key-user-id-list key)))) - (insert (format "%c " - (if (epg-sub-key-validity primary-sub-key) - (car (rassq (epg-sub-key-validity primary-sub-key) - epg-key-validity-alist)) - ? )) - (epg-sub-key-id primary-sub-key) - " " - (if primary-user-id - (if (stringp (epg-user-id-string primary-user-id)) - (epg-user-id-string primary-user-id) - (epg-decode-dn (epg-user-id-string primary-user-id))) - "")))) - -(defun epa--key-widget-button-face-get (widget) - (let ((validity (epg-sub-key-validity (car (epg-key-sub-key-list - (widget-get widget :value)))))) - (if validity - (cdr (assq validity epa-validity-face-alist)) - 'default))) - -(defun epa--key-widget-help-echo (widget) - (format "Show %s" - (epg-sub-key-id (car (epg-key-sub-key-list - (widget-get widget :value)))))) +(defun epa--button-key-text (key) + (let ((primary-sub-key (car (epg-key-sub-key-list key))) + (primary-user-id (car (epg-key-user-id-list key))) + (validity (epg-sub-key-validity (car (epg-key-sub-key-list key))))) + (propertize + (concat + (format "%c " + (if (epg-sub-key-validity primary-sub-key) + (car (rassq (epg-sub-key-validity primary-sub-key) + epg-key-validity-alist)) + ? )) + (epg-sub-key-id primary-sub-key) + " " + (if primary-user-id + (if (stringp (epg-user-id-string primary-user-id)) + (epg-user-id-string primary-user-id) + (epg-decode-dn (epg-user-id-string primary-user-id))) + "")) + 'face + (if validity + (cdr (assq validity epa-validity-face-alist)) + 'default)))) ;;; Modes @@ -309,7 +279,6 @@ You should bind this variable with `let', but do not set it globally.") (buffer-disable-undo) (setq truncate-lines t buffer-read-only t) - (setq-local font-lock-defaults '(epa-font-lock-keywords t)) (make-local-variable 'epa-exit-buffer-function) (setq-local revert-buffer-function #'epa--key-list-revert-buffer)) @@ -318,7 +287,6 @@ You should bind this variable with `let', but do not set it globally.") (buffer-disable-undo) (setq truncate-lines t buffer-read-only t) - (setq-local font-lock-defaults '(epa-font-lock-keywords t)) (make-local-variable 'epa-exit-buffer-function)) (define-derived-mode epa-info-mode special-mode "EPA Info" @@ -362,28 +330,14 @@ If ARG is non-nil, mark the key." ;;;; Listing and Selecting (defun epa--insert-keys (keys) - (save-excursion - (save-restriction - (narrow-to-region (point) (point)) - (let (point) - (while keys - (setq point (point)) - (insert " ") - (add-text-properties point (point) - (list 'epa-key (car keys) - 'front-sticky nil - 'rear-nonsticky t - 'start-open t - 'end-open t)) - (widget-create 'epa-key :value (car keys)) - (insert "\n") - (setq keys (cdr keys)))) - (add-text-properties (point-min) (point-max) - (list 'epa-list-keys t - 'front-sticky nil - 'rear-nonsticky t - 'start-open t - 'end-open t))))) + (dolist (key keys) + (insert + (propertize + (concat " " (epa--button-key-text key)) + 'epa-key key + 'help-echo (format "Show %s" + (epg-sub-key-id (car (epg-key-sub-key-list key)))))) + (insert "\n"))) (defun epa--list-keys (name secret &optional doc) "NAME specifies which key to list. @@ -420,8 +374,7 @@ DOC is documentation text to insert at the start." (point-max))) (goto-char point)) - (epa--insert-keys (epg-list-keys context name secret)) - (widget-setup)) + (epa--insert-keys (epg-list-keys context name secret))) (make-local-variable 'epa-list-keys-arguments) (setq epa-list-keys-arguments (list name secret)) (goto-char (point-min)) @@ -488,20 +441,13 @@ q trust status questionable. - trust status unspecified. (substitute-command-keys "\ - `\\[epa-mark-key]' to mark a key on the line - `\\[epa-unmark-key]' to unmark a key on the line\n")) - (widget-create 'push-button - :notify (lambda (&rest _ignore) (abort-recursive-edit)) - :help-echo - "Click here or \\[abort-recursive-edit] to cancel" - "Cancel") - (widget-create 'push-button - :notify (lambda (&rest _ignore) (exit-recursive-edit)) - :help-echo - "Click here or \\[exit-recursive-edit] to finish" - "OK") + (insert-button "[Cancel]" + 'action (lambda (_button) (abort-recursive-edit))) + (insert " ") + (insert-button "[OK]" + 'action (lambda (_button) (exit-recursive-edit))) (insert "\n\n") (epa--insert-keys keys) - (widget-setup) - (set-keymap-parent (current-local-map) widget-keymap) (setq epa-exit-buffer-function #'abort-recursive-edit) (goto-char (point-min)) (let ((display-buffer-mark-dedicated 'soft)) commit 0980e1f537d48d6e1eb761b4a7a87878efffc12f Author: Lars Ingebrigtsen Date: Mon Aug 24 20:50:08 2020 +0200 Fix error when loading a new, non-existent foo.gpg file * lisp/epa-file.el (epa-file-insert-file-contents): Propagate the correct error upwards (bug introduced by fixing bug#3829, and messing up where the `when' form ended). Reported by "Herbert J. Skuhra" . diff --git a/lisp/epa-file.el b/lisp/epa-file.el index 3b0cc84e5f..bb027b9abf 100644 --- a/lisp/epa-file.el +++ b/lisp/epa-file.el @@ -175,9 +175,9 @@ encryption is used." (setq-local epa-file-error error) (add-hook 'find-file-not-found-functions 'epa-file--find-file-not-found-function - nil t) - (signal (if exists 'file-error 'file-missing) - (cons "Opening input file" (cdr error)))))))) + nil t))) + (signal (if exists 'file-error 'file-missing) + (cons "Opening input file" (cdr error)))))) (set-buffer buf) ;In case timer/filter changed/killed it (bug#16029)! (setq-local epa-file-encrypt-to (mapcar #'car (epg-context-result-for commit 9c04760f169904fc56745a29227f1d4219f16e0a Author: Lars Ingebrigtsen Date: Mon Aug 24 20:11:19 2020 +0200 Document file-backup-file-names * doc/lispref/backups.texi (Backup Names): Document file-backup-file-names. diff --git a/doc/lispref/backups.texi b/doc/lispref/backups.texi index 4ed1a10fcf..55b8d7215d 100644 --- a/doc/lispref/backups.texi +++ b/doc/lispref/backups.texi @@ -414,10 +414,15 @@ version that the caller should consider deleting now. @end smallexample @end defun -@c Emacs 19 feature +@defun file-backup-file-names filename +This function returns a list of all the backup file names for +@var{filename}, or @code{nil} if there are none. The files are sorted +so that the most recent backup file comes first in the list. +@end defun + @defun file-newest-backup filename -This function returns the name of the most recent backup file for -@var{filename}, or @code{nil} if that file has no backup files. +This function returns the first element of the list returned by +@code{file-backup-file-names}. Some file comparison commands use this function so that they can automatically compare a file with its most recent backup. diff --git a/etc/NEWS b/etc/NEWS index 734d649dfa..03516bf4d3 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -1113,7 +1113,7 @@ ledit.el, lmenu.el, lucid.el and old-whitespace.el. * Lisp Changes in Emacs 28.1 ---- ++++ *** New function 'file-backup-file-names'. This function returns the list of file names of all the backup files of its file argument. commit 8be068661b6a4d416c15b223ffa95ef712b95f7b Author: Eli Zaretskii Date: Mon Aug 24 21:06:37 2020 +0300 ; * etc/NEWS: Fix wording of recently-added entries. diff --git a/etc/NEWS b/etc/NEWS index 6d8379bd7d..734d649dfa 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -237,7 +237,7 @@ time zones will use a form like "+0100" instead of "CET". *** '=' ('dired-diff') will now put all backup files into the 'M-n' history. When using '=' on a file with backup files, the default file to use -when diffing the newest backup file. You can now use 'M-n' to quickly +for diffing is the newest backup file. You can now use 'M-n' to quickly select a different backup file instead. +++ @@ -1115,7 +1115,8 @@ ledit.el, lmenu.el, lucid.el and old-whitespace.el. --- *** New function 'file-backup-file-names'. -This function returns all backup file names for the file in question. +This function returns the list of file names of all the backup files +of its file argument. +++ ** The 'count-lines' function now takes an optional parameter to commit 0f014a79a3e93e21ef2ab8c826c333e744948aa2 Author: Lars Ingebrigtsen Date: Mon Aug 24 19:15:27 2020 +0200 Extend the default value in dired-diff to all the backup files * lisp/dired-aux.el (dired-diff): When diffing files with backup files, put all the backup files into the defaults so that they can be reached with `M-n' from `read-file-name' (bug#24089). diff --git a/etc/NEWS b/etc/NEWS index cd8cc31705..6d8379bd7d 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -235,6 +235,11 @@ time zones will use a form like "+0100" instead of "CET". ** Dired +*** '=' ('dired-diff') will now put all backup files into the 'M-n' history. +When using '=' on a file with backup files, the default file to use +when diffing the newest backup file. You can now use 'M-n' to quickly +select a different backup file instead. + +++ *** New user option 'dired-maybe-use-globstar'. If set, enables globstar (recursive globbing) in shells that support diff --git a/lisp/dired-aux.el b/lisp/dired-aux.el index c197ed04fe..ab13b3e26e 100644 --- a/lisp/dired-aux.el +++ b/lisp/dired-aux.el @@ -134,7 +134,20 @@ the string of command switches used as the third argument of `diff'." (file-name-directory default) (dired-current-directory)) (dired-dwim-target-directory))) - (defaults (dired-dwim-target-defaults (list current) target-dir))) + (defaults (append + (if (backup-file-name-p current) + ;; This is a backup file -- put the other + ;; main file, and the other backup files into + ;; the `M-n' list. + (delete (expand-file-name current) + (cons (expand-file-name + (file-name-sans-versions current)) + (file-backup-file-names + (file-name-sans-versions current)))) + ;; Non-backup file -- use the backup files as + ;; `M-n' candidates. + (file-backup-file-names current)) + (dired-dwim-target-defaults (list current) target-dir)))) (list (minibuffer-with-setup-hook (lambda () commit b74aaee5a473f70e5b78218724cd4d10b123c388 Author: Lars Ingebrigtsen Date: Mon Aug 24 18:26:05 2020 +0200 Add a new function 'file-backup-file-names' * lisp/files.el (file-backup-file-names): New function (bug#24089). (file-newest-backup): Use it. diff --git a/etc/NEWS b/etc/NEWS index a65852fcd0..cd8cc31705 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -1108,6 +1108,10 @@ ledit.el, lmenu.el, lucid.el and old-whitespace.el. * Lisp Changes in Emacs 28.1 +--- +*** New function 'file-backup-file-names'. +This function returns all backup file names for the file in question. + +++ ** The 'count-lines' function now takes an optional parameter to ignore invisible lines. diff --git a/lisp/files.el b/lisp/files.el index f92c3793b0..5102585d7d 100644 --- a/lisp/files.el +++ b/lisp/files.el @@ -5655,25 +5655,27 @@ like `write-region' does." (defun file-newest-backup (filename) "Return most recent backup file for FILENAME or nil if no backups exist." + (car (file-backup-file-names filename))) + +(defun file-backup-file-names (filename) + "Return a list of backup files for FILENAME. +The list will be sorted by newness." ;; `make-backup-file-name' will get us the right directory for ;; ordinary or numeric backups. It might create a directory for ;; backups as a side-effect, according to `backup-directory-alist'. (let* ((filename (file-name-sans-versions (make-backup-file-name (expand-file-name filename)))) - (file (file-name-nondirectory filename)) - (dir (file-name-directory filename)) - (comp (file-name-all-completions file dir)) - (newest nil) - tem) - (while comp - (setq tem (pop comp)) - (cond ((and (backup-file-name-p tem) - (string= (file-name-sans-versions tem) file)) - (setq tem (concat dir tem)) - (if (or (null newest) - (file-newer-than-file-p tem newest)) - (setq newest tem))))) - newest)) + (dir (file-name-directory filename))) + (sort + (seq-filter + (lambda (candidate) + (and (backup-file-name-p candidate) + (string= (file-name-sans-versions candidate) filename))) + (mapcar + (lambda (file) + (concat dir file)) + (file-name-all-completions (file-name-nondirectory filename) dir))) + #'file-newer-than-file-p))) (defun rename-uniquely () "Rename current buffer to a similar name not already taken. commit 9e68413c7f0a7f71e1cee923ace7282d14c2e686 Author: Noam Postavsky Date: Mon Aug 24 17:33:49 2020 +0200 Fix inferior octave single-quote font lock * lisp/progmodes/octave.el (octave-mode-syntax-table): Fix fontification of single quotes in inferior octave mode (bug#25517). It looks like the problem is that octave-mode-syntax-table sets single quotes as punctuation even though GNU Octave's manual says single quotes are string syntax [1]. [1]: https://www.gnu.org/software/octave/doc/interpreter/String-Objects.html diff --git a/lisp/progmodes/octave.el b/lisp/progmodes/octave.el index e07f818a68..3dd9b8dae6 100644 --- a/lisp/progmodes/octave.el +++ b/lisp/progmodes/octave.el @@ -165,7 +165,7 @@ parenthetical grouping.") (modify-syntax-entry ?| "." table) (modify-syntax-entry ?! "." table) (modify-syntax-entry ?\\ "." table) - (modify-syntax-entry ?\' "." table) + (modify-syntax-entry ?\' "\"" table) (modify-syntax-entry ?\` "." table) (modify-syntax-entry ?. "." table) (modify-syntax-entry ?\" "\"" table) commit 88795c52ff13203dda5940ed5defc26ce2c20e5e Author: Lars Ingebrigtsen Date: Mon Aug 24 16:44:24 2020 +0200 Have gnutls_symmetric cache the results from Fgnutls_ciphers * src/gnutls.c (gnutls_symmetric): Cache the results from Fgnutls_ciphers, since that function isn't very fast (bug#42998). (syms_of_gnutls): Initialize cache variable. diff --git a/src/gnutls.c b/src/gnutls.c index 416fb15470..0010553a9d 100644 --- a/src/gnutls.c +++ b/src/gnutls.c @@ -2298,6 +2298,8 @@ gnutls_symmetric_aead (bool encrypting, gnutls_cipher_algorithm_t gca, # endif } +static Lisp_Object cipher_cache; + static Lisp_Object gnutls_symmetric (bool encrypting, Lisp_Object cipher, Lisp_Object key, Lisp_Object iv, @@ -2329,7 +2331,9 @@ gnutls_symmetric (bool encrypting, Lisp_Object cipher, if (SYMBOLP (cipher)) { - info = Fassq (cipher, Fgnutls_ciphers ()); + if (NILP (cipher_cache)) + cipher_cache = Fgnutls_ciphers (); + info = Fassq (cipher, cipher_cache); if (!CONSP (info)) xsignal2 (Qerror, build_string ("GnuTLS cipher is invalid or not found"), @@ -2914,6 +2918,9 @@ level in the ones. For builds without libgnutls, the value is -1. */); defsubr (&Sgnutls_hash_digest); defsubr (&Sgnutls_symmetric_encrypt); defsubr (&Sgnutls_symmetric_decrypt); + + cipher_cache = Qnil; + staticpro (&cipher_cache); #endif DEFVAR_INT ("gnutls-log-level", global_gnutls_log_level, commit 230bddbd78cc86c4520112c4cead2e1ec3cddb77 Author: Lars Ingebrigtsen Date: Mon Aug 24 15:08:55 2020 +0200 Explain what C-h t means in the preface * doc/emacs/emacs.texi (Top): Explain what C-h t means (since this section is for people who haven't even used the tutorial) (bug#42982). diff --git a/doc/emacs/emacs.texi b/doc/emacs/emacs.texi index 5b6b7b7e93..6aed7bd92a 100644 --- a/doc/emacs/emacs.texi +++ b/doc/emacs/emacs.texi @@ -1285,11 +1285,12 @@ programmer, but if you are not interested in customizing, you can ignore the customization hints. This is primarily a reference manual, but can also be used as a -primer. If you are new to Emacs, we recommend you start with -the integrated, learn-by-doing tutorial, before reading the manual. To -run the tutorial, start Emacs and type @kbd{C-h t}. The tutorial -describes commands, tells you when to try them, and explains the -results. The tutorial is available in several languages. +primer. If you are new to Emacs, we recommend you start with the +integrated, learn-by-doing tutorial, before reading the manual. To +run the tutorial, start Emacs and type @kbd{C-h t} (which is ``control +h and then t''). The tutorial describes commands, tells you when to +try them, and explains the results. The tutorial is available in +several languages. On first reading, just skim chapters 1 and 2, which describe the notational conventions of the manual and the general appearance of the commit 1fa90f77ede33a9b988072173ec10c4364b24192 Author: Lars Ingebrigtsen Date: Mon Aug 24 14:34:42 2020 +0200 Change how #:uninterned symbols are font-locked in Lisp mode * lisp/emacs-lisp/lisp-mode.el (lisp-fdefs): Font-lock #:uninterned symbols as a single entity instead of #: and uninterned separately (bug#43001). diff --git a/lisp/emacs-lisp/lisp-mode.el b/lisp/emacs-lisp/lisp-mode.el index 584ed8c6f9..352210f859 100644 --- a/lisp/emacs-lisp/lisp-mode.el +++ b/lisp/emacs-lisp/lisp-mode.el @@ -506,9 +506,7 @@ This will generate compile-time constants from BINDINGS." (1 font-lock-constant-face prepend)) ;; Uninterned symbols, e.g., (defpackage #:my-package ...) ;; must come before keywords below to have effect - (,(concat "\\(#:\\)\\(" lisp-mode-symbol-regexp "\\)") - (1 font-lock-comment-delimiter-face) - (2 font-lock-doc-face)) + (,(concat "#:" lisp-mode-symbol-regexp "") 0 font-lock-builtin-face) ;; Constant values. (,(concat "\\_<:" lisp-mode-symbol-regexp "\\_>") (0 font-lock-builtin-face)) commit 787b19115378909c472f018629da763407f6e2a0 Author: Michael Albinus Date: Mon Aug 24 12:11:48 2020 +0200 Add sanity check in tramp-sh-get-signal-strings * lisp/net/tramp-sh.el (tramp-sh-get-signal-strings): Add sanity check. * test/lisp/net/tramp-tests.el (tramp-test28-process-file): Remove instrumentation. (tramp--test--deftest-direct-async-process): Adapt docstring. (tramp--test-windows-nt-p, tramp--test-windows-nt-and-batch-p): Rename from `tramp--test-windows-nt', `tramp--test-windows-nt-and-batch'. diff --git a/lisp/net/tramp-sh.el b/lisp/net/tramp-sh.el index fae15fe6a8..7a3f3fe8f0 100644 --- a/lisp/net/tramp-sh.el +++ b/lisp/net/tramp-sh.el @@ -3025,6 +3025,10 @@ implementation will be used." (setq signals (append '(0) (split-string (shell-command-to-string "kill -l") nil 'omit))) + ;; Sanity check. Sometimes, the first entry is "0", although we + ;; don't expect it. Remove it. + (when (and (stringp (cadr signals)) (string-equal "0" (cadr signals))) + (setcdr signals (cddr signals))) ;; Sanity check. "kill -l" shall have returned just the signal ;; names. Some shells don't, like the one in "docker alpine". (let (signal-hook-function) diff --git a/test/lisp/net/tramp-tests.el b/test/lisp/net/tramp-tests.el index 6bfc7f93c4..7e9ae33f84 100644 --- a/test/lisp/net/tramp-tests.el +++ b/test/lisp/net/tramp-tests.el @@ -3557,7 +3557,7 @@ This tests also `make-symbolic-link', `file-truename' and `add-name-to-file'." ;; `tmp-name3' is a local file name. Therefore, the link ;; target remains unchanged, even if quoted. ;; `make-symbolic-link' might not be permitted on w32 systems. - (unless (tramp--test-windows-nt) + (unless (tramp--test-windows-nt-p) (make-symbolic-link tmp-name1 tmp-name3) (should (string-equal tmp-name1 (file-symlink-p tmp-name3)))) @@ -3671,7 +3671,7 @@ This tests also `make-symbolic-link', `file-truename' and `add-name-to-file'." (concat (file-remote-p tmp-name2) penguin))))) ;; `tmp-name3' is a local file name. ;; `make-symbolic-link' might not be permitted on w32 systems. - (unless (tramp--test-windows-nt) + (unless (tramp--test-windows-nt-p) (make-symbolic-link tmp-name1 tmp-name3) (should (file-symlink-p tmp-name3)) (should-not (string-equal tmp-name3 (file-truename tmp-name3))) @@ -4230,7 +4230,6 @@ This tests also `make-symbolic-link', `file-truename' and `add-name-to-file'." (skip-unless (or (tramp--test-adb-p) (tramp--test-sh-p))) (skip-unless (not (tramp--test-crypt-p))) - (tramp--test-instrument-test-case 10 (dolist (quoted (if (tramp--test-expensive-test) '(nil t) '(nil))) (let* ((tmp-name (tramp--test-make-temp-name nil quoted)) (fnnd (file-name-nondirectory tmp-name)) @@ -4291,7 +4290,7 @@ This tests also `make-symbolic-link', `file-truename' and `add-name-to-file'." (should-not (get-buffer-window (current-buffer) t)))) ;; Cleanup. - (ignore-errors (delete-file tmp-name))))))) + (ignore-errors (delete-file tmp-name)))))) ;; Must be a command, because used as `sigusr' handler. (defun tramp--test-timeout-handler (&rest _ignore) @@ -4375,7 +4374,7 @@ This tests also `make-symbolic-link', `file-truename' and `add-name-to-file'." (defmacro tramp--test--deftest-direct-async-process (test docstring &optional unstable) - "Define ert `TEST-direct-async' for direct async processes. + "Define ert test `TEST-direct-async' for direct async processes. If UNSTABLE is non-nil, the test is tagged as `:unstable'." (declare (indent 1)) `(ert-deftest ,(intern (concat (symbol-name test) "-direct-async")) () @@ -5708,11 +5707,11 @@ This does not support special file names." "Check, whether the sudoedit method is used." (tramp-sudoedit-file-name-p tramp-test-temporary-file-directory)) -(defun tramp--test-windows-nt () +(defun tramp--test-windows-nt-p () "Check, whether the locale host runs MS Windows." (eq system-type 'windows-nt)) -(defun tramp--test-windows-nt-and-batch () +(defun tramp--test-windows-nt-and-batch-p () "Check, whether the locale host runs MS Windows in batch mode. This does not support special characters." (and (eq system-type 'windows-nt) noninteractive)) @@ -6019,7 +6018,7 @@ Use the `ls' command." (skip-unless (tramp--test-enabled)) (skip-unless (tramp--test-sh-p)) (skip-unless (not (tramp--test-rsync-p))) - (skip-unless (not (tramp--test-windows-nt-and-batch))) + (skip-unless (not (tramp--test-windows-nt-and-batch-p))) (skip-unless (not (tramp--test-windows-nt-and-pscp-psftp-p))) (let ((tramp-connection-properties @@ -6085,7 +6084,7 @@ Use the `ls' command." (skip-unless (tramp--test-enabled)) (skip-unless (not (tramp--test-docker-p))) (skip-unless (not (tramp--test-rsync-p))) - (skip-unless (not (tramp--test-windows-nt-and-batch))) + (skip-unless (not (tramp--test-windows-nt-and-batch-p))) (skip-unless (not (tramp--test-windows-nt-and-pscp-psftp-p))) (skip-unless (not (tramp--test-ksh-p))) (skip-unless (not (tramp--test-crypt-p))) @@ -6100,7 +6099,7 @@ Use the `stat' command." (skip-unless (tramp--test-sh-p)) (skip-unless (not (tramp--test-docker-p))) (skip-unless (not (tramp--test-rsync-p))) - (skip-unless (not (tramp--test-windows-nt-and-batch))) + (skip-unless (not (tramp--test-windows-nt-and-batch-p))) (skip-unless (not (tramp--test-windows-nt-and-pscp-psftp-p))) (skip-unless (not (tramp--test-ksh-p))) (skip-unless (not (tramp--test-crypt-p))) @@ -6122,7 +6121,7 @@ Use the `perl' command." (skip-unless (tramp--test-sh-p)) (skip-unless (not (tramp--test-docker-p))) (skip-unless (not (tramp--test-rsync-p))) - (skip-unless (not (tramp--test-windows-nt-and-batch))) + (skip-unless (not (tramp--test-windows-nt-and-batch-p))) (skip-unless (not (tramp--test-windows-nt-and-pscp-psftp-p))) (skip-unless (not (tramp--test-ksh-p))) (skip-unless (not (tramp--test-crypt-p))) @@ -6147,7 +6146,7 @@ Use the `ls' command." (skip-unless (tramp--test-sh-p)) (skip-unless (not (tramp--test-docker-p))) (skip-unless (not (tramp--test-rsync-p))) - (skip-unless (not (tramp--test-windows-nt-and-batch))) + (skip-unless (not (tramp--test-windows-nt-and-batch-p))) (skip-unless (not (tramp--test-windows-nt-and-pscp-psftp-p))) (skip-unless (not (tramp--test-ksh-p))) (skip-unless (not (tramp--test-crypt-p))) @@ -6242,7 +6241,7 @@ process sentinels. They shall not disturb each other." (shell-file-name (if (tramp--test-adb-p) "/system/bin/sh" "/bin/sh")) ;; It doesn't work on w32 systems. (watchdog - (unless (tramp--test-windows-nt) + (unless (tramp--test-windows-nt-p) (start-process-shell-command "*watchdog*" nil (format @@ -6610,7 +6609,8 @@ If INTERACTIVE is non-nil, the tests are run interactively." ;; * Fix `tramp-test06-directory-file-name' for `ftp'. ;; * Investigate, why `tramp-test11-copy-file' and `tramp-test12-rename-file' ;; do not work properly for `nextcloud'. -;; * Implement `tramp-test31-interrupt-process' for `adb'. +;; * Implement `tramp-test31-interrupt-process' for `adb' and for +;; direct async processes. ;; * Fix Bug#16928 in `tramp-test43-asynchronous-requests'. A remote ;; file name operation cannot run in the timer. Remove `:unstable' tag?