]> git.eshelyaron.com Git - emacs.git/log
emacs.git
4 years agoLet the OS clear large new objects
Paul Eggert [Fri, 3 Jan 2020 02:02:32 +0000 (18:02 -0800)]
Let the OS clear large new objects

Prefer calloc to malloc+memset when allocating large zeroed objects.
This avoids page thrashing when (make-vector 1000000000 nil)
allocates a large nil vector, as Emacs need not touch the
vector’s pages.  This wins on platforms like GNU/Linux where
calloc can fiddle with page tables to create a block of memory
that is lazily zeroed.
* src/alloc.c (lisp_malloc, lmalloc, allocate_vectorlike):
New arg CLEARIT to tell callee whether to use malloc or calloc.
All callers changed.
(allocate_clear_vector, allocate_nil_vector): New functions.
* src/alloc.c (xzalloc, make_vector):
* src/lisp.h (make_nil_vector):
Prefer calloc to malloc + memset(...,0,...).

4 years agoFix compilation with GTK versions older than 3
Eli Zaretskii [Wed, 1 Jan 2020 17:55:35 +0000 (19:55 +0200)]
Fix compilation with GTK versions older than 3

* src/xfns.c (x_get_net_workarea): Change a recently moved #ifndef
so that GTK builds which need this function will compile it.
Reported by John <jpff@codemist.co.uk>.

4 years ago; Auto-commit of loaddefs files.
Glenn Morris [Wed, 1 Jan 2020 14:28:39 +0000 (06:28 -0800)]
; Auto-commit of loaddefs files.

4 years agoAssume C99-style ‘long long’
Paul Eggert [Wed, 1 Jan 2020 04:15:27 +0000 (04:15 +0000)]
Assume C99-style ‘long long’

Now that Gnulib assumes ‘long long’, it is a good time to clean
out old cruft porting to pre-C99 compilers that lack it.
* src/data.c (ULL_WIDTH, ULL_MAX): Remove.
All uses replaced by ULLONG_WIDTH, ULLONG_MAX.
(bits_word_to_host_endian): Assume ‘unsigned long long’.
By the way, the old code had a performance typo: it used
HAVE_UNSIGNED_LONG_LONG where it should have used
HAVE_UNSIGNED_LONG_LONG_INT.
* src/sysdep.c (ULLONG_MAX): Remove, as lib/limits.h does this now.
(time_from_jiffies) [GNU_LINUX]: Assume ‘long long’.

4 years agoRemove files no longer needed from Gnulib
Paul Eggert [Wed, 1 Jan 2020 04:15:27 +0000 (04:15 +0000)]
Remove files no longer needed from Gnulib

* m4/count-leading-zeros.m4, m4/count-one-bits.m4:
* m4/count-trailing-zeros.m4, m4/longlong.m4:
Remove.

4 years ago* etc/NEWS: Update copyright year.
Paul Eggert [Wed, 1 Jan 2020 03:14:33 +0000 (03:14 +0000)]
* etc/NEWS: Update copyright year.

4 years agoUpdate from gnulib
Paul Eggert [Wed, 1 Jan 2020 03:11:22 +0000 (03:11 +0000)]
Update from gnulib

This incorporates:
2019-12-23 mktime, nstrftime: tweak division performance
2019-12-22 count-leading-zeros: assume 'long long'
2019-12-22 count-one-bits: assume 'long long'
2019-12-22 count-trailing-zeros: assume 'long long'
2019-12-12 inttypes-incomplete: assume 'long long'
2019-12-22 malloca: assume 'long long'
2019-12-22 stdint: assume 'long long'
2019-12-22 strtoll, strtoimax, strtoumax: assume 'long long'
2019-12-22 prefer lib_SOURCES to unconditional AC_LIBOBJ
2019-12-19 nstrftime: avoid a shadowing warning
2019-12-18 improve port of AC_C_RESTRICT to Oracle C++
2019-12-12 stdalign: port to xlclang 16.01
2019-12-11 stddef, unistd: fix compilation error in C++ mode on MSVC
2019-12-08 fix compilation errors in C++ mode on Haiku
2019-12-08 fix compilation errors in 32-bit C++ mode on HP-UX 11/ia64
2019-12-08 fix compilation error in C++ mode on OpenBSD
* build-aux/config.guess, doc/misc/texinfo.tex:
* lib/count-leading-zeros.h, lib/count-one-bits.h:
* lib/count-trailing-zeros.h, lib/inttypes.in.h, lib/malloca.h:
* lib/mktime.c, lib/nstrftime.c, lib/signal.in.h, lib/stdalign.in.h:
* lib/stddef.in.h, lib/stdint.in.h, lib/stdio.in.h, lib/stdlib.in.h:
* lib/strtoimax.c, lib/unistd.in.h, m4/gnulib-common.m4:
* m4/inttypes.m4, m4/largefile.m4, m4/malloca.m4, m4/strtoimax.m4:
* m4/strtoll.m4:
Copy from Gnulib.  Also, change copyright notices in some other
Gnulib-copied files to exactly match Gnulib, as Gnulib updated
them in a trivially different way.
* lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.

4 years agoMerge from origin/emacs-27
Paul Eggert [Wed, 1 Jan 2020 01:08:16 +0000 (01:08 +0000)]
Merge from origin/emacs-27

186152ba40 Pacify gcc -Wunused-function on Ubuntu 18.04.3
4cd143aded Fix copyright years by hand
365e01cc9f Update copyright year to 2020
cd2c156163 ; * etc/NEWS: Make the description of XDG fallback more ac...

# Conflicts:
# etc/NEWS
# etc/refcards/ru-refcard.tex

4 years agoPacify gcc -Wunused-function on Ubuntu 18.04.3
Paul Eggert [Wed, 1 Jan 2020 01:03:14 +0000 (01:03 +0000)]
Pacify gcc -Wunused-function on Ubuntu 18.04.3

This improves on 2019-12-25T20:01:07Z!eggert@cs.ucla.edu,
by fixing a GCC warning on Ubuntu 18.04.3
“‘x_get_net_workarea’ defined but not used”.
* src/xfns.c (x_get_net_workarea) [!USE_GTK]: Do not define.

4 years agoFix copyright years by hand
Paul Eggert [Wed, 1 Jan 2020 01:01:53 +0000 (01:01 +0000)]
Fix copyright years by hand

These are dates that admin/update-copyright did not update.

4 years agoUpdate copyright year to 2020
Paul Eggert [Wed, 1 Jan 2020 00:19:43 +0000 (00:19 +0000)]
Update copyright year to 2020

Run "TZ=UTC0 admin/update-copyright $(git ls-files)".

4 years ago; * etc/NEWS: Make the description of XDG fallback more accurate.
Eli Zaretskii [Tue, 31 Dec 2019 19:28:54 +0000 (21:28 +0200)]
; * etc/NEWS: Make the description of XDG fallback more accurate.

4 years ago; Merge from origin/emacs-27
Glenn Morris [Tue, 31 Dec 2019 15:50:15 +0000 (07:50 -0800)]
; Merge from origin/emacs-27

The following commits were skipped:

195bde9ea8 (origin/emacs-27) Don't always resort in recently introduc...
f2a349ba8d Don't force completion recalculation in icomplete-fido-ret
9b1053ba27 Correctly cache sorted completions in icomplete--sorted-co...
b1c3ed9f32 Move flex style's minibuffer-default-aware sorting to lisp...
e3276f36c0 Make fido-mode behave more like ido-mode when finding dire...
fe0ed17175 Slightly simplify lisp/icomplete.el with new icomplete--ca...
5352947d0d Another adjustment to flex completion style's sorting func...

4 years agoMerge from origin/emacs-27
Glenn Morris [Tue, 31 Dec 2019 15:50:15 +0000 (07:50 -0800)]
Merge from origin/emacs-27

9b6872b4e4 ; * test/lisp/calc/calc-tests.el: Fix warnings
957cdca6f0 Make minibuffer-tests work in out-of-tree builds (bug#38816)
2065316749 Make comint-tests more robust (bug#38813)

4 years agoDon't always resort in recently introduced icomplete--sorted-completions
João Távora [Wed, 25 Dec 2019 19:18:17 +0000 (19:18 +0000)]
Don't always resort in recently introduced icomplete--sorted-completions

Doing so breaks icomplete-forward-completions and
icomplete-backward-completions.

* lisp/icomplete.el (icomplete--sorted-completions): Don't always
resort.

(cherry picked from commit 639fb50ed4c622f99dfbde32fbdbca42ce36d385)

4 years agoDon't force completion recalculation in icomplete-fido-ret
João Távora [Wed, 25 Dec 2019 17:57:20 +0000 (17:57 +0000)]
Don't force completion recalculation in icomplete-fido-ret

Besides the adverse effect of delaying completions, it tripped up the
useful logic of icomplete-force-complete-and-exit in the case where a
default was available, but no completions calculated yet.

* lisp/icomplete.el (icomplete-fido-ret): Don't force calculation
of completions.

(cherry picked from commit 13778aa5be7bf028893672d84c2a291f491d8216)

4 years agoCorrectly cache sorted completions in icomplete--sorted-completions
João Távora [Wed, 25 Dec 2019 17:54:00 +0000 (17:54 +0000)]
Correctly cache sorted completions in icomplete--sorted-completions

* lisp/icomplete.el (icomplete--sorted-completions): Use
completion--cache-all-sorted-completions.

(cherry picked from commit 83587bb68830bd91124f99ddf8590d1d5f63869f)

4 years agoMove flex style's minibuffer-default-aware sorting to lisp/icomplete.el
João Távora [Tue, 24 Dec 2019 10:40:39 +0000 (10:40 +0000)]
Move flex style's minibuffer-default-aware sorting to lisp/icomplete.el

This moves the logic from the series of commits starting in the commit named:

  Improve sorting of flex completion style with non-nil minibuffer-default

to lisp/icomplete.el, so far the only confirmed beneficiary of that
functionality.

* lisp/icomplete.el (icomplete--sorted-completions): Consider
minibuffer-default here.

* lisp/minibuffer.el (completion--flex-adjust-metadata): Simplify.

(cherry picked from commit 0d2a711dc9a65dc8eb6e995369e70cddbcd7d9a4)

4 years agoMake fido-mode behave more like ido-mode when finding directories
João Távora [Mon, 23 Dec 2019 23:43:30 +0000 (23:43 +0000)]
Make fido-mode behave more like ido-mode when finding directories

Notably C-x d (M-x dired) and C-x v d (M-x vc-dir) behaved quite
differently, having regular files as the default instead of ido's
usual "./".

* lisp/icomplete.el (icomplete--sorted-completions): New helper.
(icomplete-completions): Use it.

(cherry picked from commit ee914051fbb4fbff9073a23b5ea7668bf48b5c6a)

4 years agoSlightly simplify lisp/icomplete.el with new icomplete--category helper
João Távora [Mon, 23 Dec 2019 23:19:01 +0000 (23:19 +0000)]
Slightly simplify lisp/icomplete.el with new icomplete--category helper

* lisp/icomplete.el (icomplete-fido-kill)
(icomplete-fido-delete-char, icomplete-fido-ret)
(icomplete-fido-backward-updir, icomplete-exhibit): Use
icomplete--category.
(icomplete--category): New helper.

(cherry picked from commit 24a1f520f91c278cb8cc57325ea80285a3b252cf)

4 years agoAnother adjustment to flex completion style's sorting function
João Távora [Mon, 23 Dec 2019 23:11:59 +0000 (23:11 +0000)]
Another adjustment to flex completion style's sorting function

* lisp/minibuffer.el (completion--flex-adjust-metadata): Adjust
case when minibuffer-default is non-nil.

(cherry picked from commit 9c912049927cfb18b9c8b37039b38ddf51f2fe81)

4 years ago* admin/gitmerge.el (gitmerge-skip-regexp): Be more restrictive.
Glenn Morris [Mon, 30 Dec 2019 17:28:29 +0000 (09:28 -0800)]
* admin/gitmerge.el (gitmerge-skip-regexp): Be more restrictive.

4 years ago; * test/lisp/calc/calc-tests.el: Fix warnings
Mattias Engdegård [Mon, 30 Dec 2019 14:24:13 +0000 (15:24 +0100)]
; * test/lisp/calc/calc-tests.el: Fix warnings

4 years agoMake minibuffer-tests work in out-of-tree builds (bug#38816)
Mattias Engdegård [Mon, 30 Dec 2019 14:40:13 +0000 (15:40 +0100)]
Make minibuffer-tests work in out-of-tree builds (bug#38816)

* test/lisp/minibuffer-tests.el (completion-table-test-quoting):
Set default-directory.

4 years agoMake comint-tests more robust (bug#38813)
Mattias Engdegård [Mon, 30 Dec 2019 13:10:02 +0000 (14:10 +0100)]
Make comint-tests more robust (bug#38813)

* test/lisp/comint-tests.el (comint-test-no-password-function)
(comint-test-password-function-with-value)
(comint-test-password-function-with-nil):
Call accept-process-output as many times as needed, with a slightly
more generous timeout (100 ms), after sending the Password: prompt to
the process, since there must be time for some back-and-forth
communication.  Also clear the process-query-on-exit flag, since it
doesn't go well with noninteractive tests.

4 years agoSync with Tramp 2.4.3
Michael Albinus [Sun, 29 Dec 2019 12:53:06 +0000 (13:53 +0100)]
Sync with Tramp 2.4.3

* doc/misc/trampver.texi:
* lisp/net/trampver.el: Change version to "2.4.3".

* lisp/net/tramp.el: Bump version.
(tramp-handle-shell-command): The temp file for error-buffer is remote.

* test/lisp/net/tramp-tests.el (tramp-test30-make-process):
Simplify buffer generation.
(tramp-test32-shell-command): Extend test.

(cherry picked from commit d6922db49dea33ac2bca8b33d24763cc7b2e4cd7)

4 years agoMerge from origin/emacs-27
Glenn Morris [Mon, 30 Dec 2019 17:12:25 +0000 (09:12 -0800)]
Merge from origin/emacs-27

59f71d20ea (origin/emacs-27) Fix tar-mode reading the oldgnu Tar format
e3ec84fd7d Ensure mini-window is resized to show active minibuffer co...
450633f85a Fix mini-window resizing under resize-mini-windows = t
219d47893a (emacs-27) Fixes for makeinfo 4.13
4bbfd2b42f ; fix previous NEWS entry
81b697d106 Fix crash under -nw on macOS properly this time
9ce4207969 Revert "Check for GUI frame in ns_color_index_to_rgba"
732dcfc850 Ignore all color fonts when using XFT
aa0c679f48 Avoid unbounded growth of cl-random-state components (bug#...

# Conflicts:
# etc/NEWS
# src/nsterm.m

4 years ago; Merge from origin/emacs-27
Glenn Morris [Mon, 30 Dec 2019 17:04:05 +0000 (09:04 -0800)]
; Merge from origin/emacs-27

The following commit was skipped:

d6922db49d Sync with Tramp 2.4.3

4 years agoMerge from origin/emacs-27
Glenn Morris [Mon, 30 Dec 2019 17:04:05 +0000 (09:04 -0800)]
Merge from origin/emacs-27

70fe552c61 ; xref-references-in-directory: Autoload as well
181f571651 Fix up requires
43f66c3368 Extract xref-matches-in-files from project--find-regexp-in...
65af18d86e Rename xref-collect-references and xref-collect-matches
98788bf976 ; Improve the docstring some more
c190e91a1e Improve docstrings
012c12a05e Fix when expose draws partially visible first glyph (bug#3...
d915b8c3f1 Don't require semantic/fw
50a0126402 Do some renames for clarity
74261ff301 Rearrange NEWS, add missing documentation
6c9571379e Fix interactive spec in netrc-parse
32222fb34c Fix documentation of define-obsolete-* functions

# Conflicts:
# etc/NEWS

4 years ago; Merge from origin/emacs-27
Glenn Morris [Mon, 30 Dec 2019 17:04:04 +0000 (09:04 -0800)]
; Merge from origin/emacs-27

The following commit was skipped:

3434ac67b9 Fix recent gnus-start.el breakage

4 years agoMerge from origin/emacs-27
Glenn Morris [Mon, 30 Dec 2019 17:04:04 +0000 (09:04 -0800)]
Merge from origin/emacs-27

8224ed7d40 (xref--find-buffer-visiting): Speed up by using get-file-b...

4 years agoFix tar-mode reading the oldgnu Tar format
Eli Zaretskii [Mon, 30 Dec 2019 16:17:03 +0000 (18:17 +0200)]
Fix tar-mode reading the oldgnu Tar format

This makes sure an entry for a long file name will not
accidentally appear as a directory, and thus its size will be
disregarded, causing corrupted file headers for all the subsequent
entries.  The original problem happened because the long file name
truncated to 99 bytes happened to end in a slash, which tar-mode
takes to be the indication of a directory.
* lisp/tar-mode.el (tar-header-block-tokenize): Accept an
additional argument DISABLE-SLASH; if non-nil, don't set the
link-type field of the descriptor to 5 (meaning a directory) just
because the name ends in a slash.  Use this argument when calling
itself recursively, to read the entry of the file with a long
name.  Set the link-type to 5 if the long name ends in a slash.
(Bug#38777)

4 years agoEnsure mini-window is resized to show active minibuffer contents
Eli Zaretskii [Mon, 30 Dec 2019 16:00:17 +0000 (18:00 +0200)]
Ensure mini-window is resized to show active minibuffer contents

* src/keyboard.c (read_char, command_loop_1): Resize the
mini-window after clearing the echo area while minibuffer is
active.  (Bug#38645)

4 years agoFix mini-window resizing under resize-mini-windows = t
Eli Zaretskii [Mon, 30 Dec 2019 15:53:52 +0000 (17:53 +0200)]
Fix mini-window resizing under resize-mini-windows = t

* src/window.c (grow_mini_window): Fix resizing of mini-window
when the echo area is cleared, and the caller asks for the
mini-window to have zero lines.  (Bug#38791)

4 years agoFixes for makeinfo 4.13
Glenn Morris [Sun, 29 Dec 2019 23:41:52 +0000 (15:41 -0800)]
Fixes for makeinfo 4.13

* doc/lispref/customize.texi (Variable Definitions): Fix xref.
* doc/lispref/internals.texi (Writing Emacs Primitives)
(Module Values): Follow xref with comma.

4 years ago; fix previous NEWS entry
Robert Pluim [Sun, 29 Dec 2019 21:21:48 +0000 (22:21 +0100)]
; fix previous NEWS entry

4 years agoFix crash under -nw on macOS properly this time
Robert Pluim [Sun, 29 Dec 2019 19:41:28 +0000 (20:41 +0100)]
Fix crash under -nw on macOS properly this time

* src/dispextern.h (FACE_COLOR_TO_PIXEL): Only use
ns_color_index_to_rgba when we're running under the NS gui
(Bug#38564).

4 years agoRevert "Check for GUI frame in ns_color_index_to_rgba"
Robert Pluim [Sun, 29 Dec 2019 19:34:20 +0000 (20:34 +0100)]
Revert "Check for GUI frame in ns_color_index_to_rgba"

This reverts commit ea84a95bd8d43612b4a424fb93de25a68ac31d05.

4 years agoIgnore all color fonts when using XFT
Robert Pluim [Sun, 29 Dec 2019 19:08:38 +0000 (20:08 +0100)]
Ignore all color fonts when using XFT

* etc/NEWS: Announce change to matching color fonts when using XFT.

* src/ftfont.c (ftfont_list) [HAVE_XFT && FC_COLOR]: Query for the
color attribute of the matched font, and skip it if it is not
FcFalse (Bug#37786).

4 years agoAvoid unbounded growth of cl-random-state components (bug#38753)
Mattias Engdegård [Sun, 29 Dec 2019 12:51:48 +0000 (13:51 +0100)]
Avoid unbounded growth of cl-random-state components (bug#38753)

* lisp/emacs-lisp/cl-extra.el (cl-random):
Perform the modulo 2**23 operation before updating the state instead
of after.  The result is always the same, but it prevents the state
from growing into arbitrary large bignums.

Patch from Christopher Wellons.

4 years agoSync with Tramp 2.4.3
Michael Albinus [Sun, 29 Dec 2019 12:53:06 +0000 (13:53 +0100)]
Sync with Tramp 2.4.3

* doc/misc/trampver.texi:
* lisp/net/trampver.el: Change version to "2.4.3".

* lisp/net/tramp.el: Bump version.
(tramp-handle-shell-command): The temp file for error-buffer is remote.

* test/lisp/net/tramp-tests.el (tramp-test30-make-process):
Simplify buffer generation.
(tramp-test32-shell-command): Extend test.

4 years ago; xref-references-in-directory: Autoload as well
Dmitry Gutov [Sun, 29 Dec 2019 12:38:17 +0000 (15:38 +0300)]
; xref-references-in-directory: Autoload as well

4 years agoFix up requires
Dmitry Gutov [Sun, 29 Dec 2019 12:22:11 +0000 (15:22 +0300)]
Fix up requires

* lisp/progmodes/project.el (project-files):
Remove (require 'xref).
(project--files-in-directory): Add it here instead.
(project-find-regexp, project-or-external-find-regexp): And here.
For 'xref--show-xrefs'.

4 years agoExtract xref-matches-in-files from project--find-regexp-in-files
Dmitry Gutov [Sun, 29 Dec 2019 12:11:53 +0000 (15:11 +0300)]
Extract xref-matches-in-files from project--find-regexp-in-files

* lisp/progmodes/xref.el (xref-matches-in-files): Extract from
project--find-regexp-in-files.

* lisp/dired-aux.el (dired-do-find-regexp): Also use it here.

4 years agoRename xref-collect-references and xref-collect-matches
Dmitry Gutov [Sun, 29 Dec 2019 12:44:08 +0000 (15:44 +0300)]
Rename xref-collect-references and xref-collect-matches

* lisp/progmodes/xref.el (xref-references-in-directory): Rename
from xref-collect-references.  Update the sole caller.
(xref-matches-in-directory): Rename from xref-collect-matches.
Update all callers (all of them are in the /tests/ dir).

* test/lisp/progmodes/xref-tests.el (xref-tests-data-dir):
Don't use the EMACS_TEST_DIRECTORY env var. It doesn't work when
running interactively.

4 years ago; Improve the docstring some more
Dmitry Gutov [Sun, 29 Dec 2019 11:28:22 +0000 (14:28 +0300)]
; Improve the docstring some more

4 years agoImprove docstrings
Dmitry Gutov [Sat, 28 Dec 2019 17:07:25 +0000 (20:07 +0300)]
Improve docstrings

* lisp/progmodes/xref.el (xref-collect-matches)
(xref-collect-references): Improve docstrings.

4 years agoFix when expose draws partially visible first glyph (bug#38731)
Alan Third [Fri, 27 Dec 2019 16:16:37 +0000 (16:16 +0000)]
Fix when expose draws partially visible first glyph (bug#38731)

* src/xdisp.c (expose_area): When the face extends to the end of the
line draw text from the correct x coordinate.

4 years agoDon't require semantic/fw
Dmitry Gutov [Sat, 28 Dec 2019 16:37:22 +0000 (19:37 +0300)]
Don't require semantic/fw

* lisp/progmodes/xref.el (xref-collect-matches): Don't require
semantic/fw, we haven't been using semantic-find-file-noselect
here for a while.

4 years agoDo some renames for clarity
Dmitry Gutov [Sat, 28 Dec 2019 16:28:30 +0000 (19:28 +0300)]
Do some renames for clarity

* lisp/progmodes/xref.el (xref--last-file-buffer):
Rename from xref--last-visiting-buffer.  Update users.
(xref--find-file-buffer): Rename from xref--find-buffer-visiting
to match the standard function that gets called inside.  Ditto.

4 years agoRearrange NEWS, add missing documentation
Eli Zaretskii [Sat, 28 Dec 2019 13:19:05 +0000 (15:19 +0200)]
Rearrange NEWS, add missing documentation

* etc/NEWS: Rearrange and mark entries whether documented or not.

* doc/lispref/streams.texi (Output Variables): Document the new
default of 'print-quoted'.
* doc/lispref/keymaps.texi (Functions for Key Lookup): Document
that KEYMAP arg to 'lookup-key' can also be a list.
* doc/lispref/customize.texi (Variable Definitions): Document the
:local keyword of 'defcustom'.
* doc/lispref/numbers.texi (Float Basics): Document changes in
'logb'.
* doc/lispref/hooks.texi (Standard Hooks): Document
'comint-password-function'.

* doc/emacs/display.texi (Text Scale): Document text-size
adjustment using the mouse wheel.
* doc/emacs/frames.texi (Mouse Commands): Document image scaling
with the mouse wheel.
* doc/emacs/windows.texi (Window Convenience): Document
'global-tab-line-mode'.
* doc/emacs/search.texi (Repeat Isearch, Symbol Search)
(Isearch Yank): Document the new support for numeric arguments in
Isearch commands.
(Special Isearch): Document 'M-s M->' and 'M-s M-<'.
(Search Customizations): Document 'isearch-lazy-count'.  Improve
indexing.
(Not Exiting Isearch): Document the new value of
'isearch-allow-scroll'.
* doc/emacs/maintaining.texi (Xref Commands): Document the new 'g'
key binding.
* doc/emacs/package.texi (Package Installation): Document changes
in 'package-check-signature'.
* doc/emacs/maintaining.texi (VC Change Log): Document
'vc-log-search'.
* doc/emacs/dired.texi (Operating on Files): Document
'dired-vc-rename'.

4 years agoFix interactive spec in netrc-parse
Xu Chunyang [Sat, 28 Dec 2019 12:40:57 +0000 (13:40 +0100)]
Fix interactive spec in netrc-parse

* lisp/net/netrc.el (netrc-parse): Fix placement of interactive
spec (bug#38773).

4 years agoFix documentation of define-obsolete-* functions
Eli Zaretskii [Sat, 28 Dec 2019 09:13:25 +0000 (11:13 +0200)]
Fix documentation of define-obsolete-* functions

* doc/lispref/functions.texi (Obsolete Functions): Make
documentation of functions that obsolete symbols match the
advertised calling conventions.

* lisp/emacs-lisp/byte-run.el (define-obsolete-function-alias)
(define-obsolete-variable-alias, define-obsolete-face-alias):
State in the doc strings that WHEN is a mandatory argument, to be
consistent with the advertised calling convention.  (Bug#38675)

4 years agoFix recent gnus-start.el breakage
Lars Ingebrigtsen [Sat, 28 Dec 2019 00:45:12 +0000 (01:45 +0100)]
Fix recent gnus-start.el breakage

* lisp/gnus/gnus-start.el (gnus-group-change-level): Fix previous
patch that made info nil when adding new groups (thereby making
gnus-newsrc-alist invalid).

(cherry picked from commit 3434ac67b9ec6b1d19f1c5ebb7d23b0b62dadac9)

4 years agoFix recent gnus-start.el breakage
Lars Ingebrigtsen [Sat, 28 Dec 2019 00:45:12 +0000 (01:45 +0100)]
Fix recent gnus-start.el breakage

* lisp/gnus/gnus-start.el (gnus-group-change-level): Fix previous
patch that made info nil when adding new groups (thereby making
gnus-newsrc-alist invalid).

4 years agoDisplay a help text when listing EPA keys
Richard Stallman [Fri, 27 Dec 2019 18:27:13 +0000 (19:27 +0100)]
Display a help text when listing EPA keys

* lisp/epa.el (epa--list-keys, epa-list-keys): Display a help text
that explains what the letters mean.

4 years ago(xref--find-buffer-visiting): Speed up by using get-file-buffer
Dmitry Gutov [Fri, 27 Dec 2019 16:17:48 +0000 (19:17 +0300)]
(xref--find-buffer-visiting): Speed up by using get-file-buffer

* lisp/progmodes/xref.el (xref--find-buffer-visiting):
Speed up by using get-file-buffer.
(xref--collect-matches): Remove the condition on remote-id.
(https://lists.gnu.org/archive/html/emacs-devel/2019-12/msg00753.html)

4 years agoMerge from origin/emacs-27
Glenn Morris [Fri, 27 Dec 2019 15:50:16 +0000 (07:50 -0800)]
Merge from origin/emacs-27

3f2788d4ac (origin/emacs-27) project--vc-list-files: Recurse into sub...
f0da3aa83e Merge branch 'emacs-27' of git.savannah.gnu.org:/srv/git/e...
3b199614cc Minor improvements of buffer documentation
e1e0a7a751 xref--collect-matches: Speed up on remote
219b91eb2c ; project--find-regexp-in-files: Avoid prepending remote-i...

4 years ago; Merge from origin/emacs-27
Glenn Morris [Fri, 27 Dec 2019 15:50:16 +0000 (07:50 -0800)]
; Merge from origin/emacs-27

The following commit was skipped:

d627fc7d55 ; Use regexp type in tramp-adb-prompt (backport, do not me...

4 years agoMerge from origin/emacs-27
Glenn Morris [Fri, 27 Dec 2019 15:50:16 +0000 (07:50 -0800)]
Merge from origin/emacs-27

8aad80d661 Fix installer build
47a73e3e14 Update Windows build documentation
cd55984153 Calc: add missing dynamic variable declarations
e8aa6f19e9 * doc/emacs/buffers.texi (Kill Buffer): Improve indexing.
ccd7cd2c51 Speed up dired-do-find-regexp
7edb1f0773 ; Remove outdated declarations
6ab40c1a51 ; Clarify the assumption
be38e39fcc project--find-regexp-in-files: Support remote files
21c3020fce Document some restrictions for module functions.
e1ce9f3423 Don't recommend using 'module-load' for loading modules.
03f962a486 Port x_get_monitor_attributes_fallback to !HAVE_GTK3
0b32f59764 Fix compilation warning in gnus-start.el

4 years agoproject--vc-list-files: Recurse into submodules
Dmitry Gutov [Fri, 27 Dec 2019 15:18:41 +0000 (18:18 +0300)]
project--vc-list-files: Recurse into submodules

* lisp/progmodes/project.el (project-try-vc): Do not treat a Git
submodule as a project root, go up to the parent repo.
(project--git-submodules): New function.
(project--vc-list-files): Use it.  Recurse into submodules.

4 years agoMerge branch 'emacs-27' of git.savannah.gnu.org:/srv/git/emacs into emacs-27
Eli Zaretskii [Fri, 27 Dec 2019 14:20:27 +0000 (16:20 +0200)]
Merge branch 'emacs-27' of git.savannah.gnu.org:/srv/git/emacs into emacs-27

4 years agoMinor improvements of buffer documentation
Eli Zaretskii [Fri, 27 Dec 2019 14:19:09 +0000 (16:19 +0200)]
Minor improvements of buffer documentation

* doc/emacs/buffers.texi (Buffers): Say that buffers are killed
when no longer needed.  Suggested by Jean-Christophe Helary
<jean.christophe.helary@traduction-libre.org>.

4 years agoxref--collect-matches: Speed up on remote
Dmitry Gutov [Fri, 27 Dec 2019 14:08:53 +0000 (17:08 +0300)]
xref--collect-matches: Speed up on remote

* lisp/progmodes/xref.el (xref--collect-matches):
Don't call find-buffer-visiting on remote file names, it's pretty
slow (bug#34343).

4 years ago; project--find-regexp-in-files: Avoid prepending remote-id twice (bug#34343)
Dmitry Gutov [Fri, 27 Dec 2019 14:06:25 +0000 (17:06 +0300)]
; project--find-regexp-in-files: Avoid prepending remote-id twice (bug#34343)

4 years agoDeduplicate non-fixnum numeric constants in byte-compilation
Mattias Engdegård [Sun, 22 Dec 2019 11:09:06 +0000 (12:09 +0100)]
Deduplicate non-fixnum numeric constants in byte-compilation

* lisp/emacs-lisp/bytecomp.el (byte-compile-get-constant):
Use eql for looking up constants instead of eq, allowing
for bignum and flonum deduplication (bug#38708).

4 years agoFix error message about recursive use of minibuffer
Eli Zaretskii [Fri, 27 Dec 2019 10:28:31 +0000 (12:28 +0200)]
Fix error message about recursive use of minibuffer

* src/minibuf.c (read_minibuf): Fix formatting of an error
message.  Reported by martin rudalics <rudalics@gmx.at>.

4 years ago; Use regexp type in tramp-adb-prompt (backport, do not merge)
Mattias Engdegård [Fri, 27 Dec 2019 09:25:05 +0000 (10:25 +0100)]
; Use regexp type in tramp-adb-prompt (backport, do not merge)

* lisp/net/tramp-adb.el (tramp-adb-prompt): Use 'regexp' instead
of 'string' as type for values that are regexps in defcustom
declarations.

4 years agoFix installer build
Phillip Lord [Thu, 26 Dec 2019 22:01:02 +0000 (23:01 +0100)]
Fix installer build

* admin/nt/dist-build/build-zips.sh: Ensure that NSIS build always
  uses the actual build number to locate its files.

4 years agoUpdate for Emacs-28
Phillip Lord [Thu, 26 Dec 2019 20:15:32 +0000 (21:15 +0100)]
Update for Emacs-28

* admin/nt/dist-build/build-dep-zips.py: Emacs major version number.

4 years agoUpdate Windows build documentation
Phillip Lord [Thu, 26 Dec 2019 20:13:38 +0000 (21:13 +0100)]
Update Windows build documentation

* admin/nt/dist-build/README-scripts: Update with branch and snapshot
  information.

4 years agoFix bogus test in body of a while loop
Lars Ingebrigtsen [Thu, 26 Dec 2019 18:46:19 +0000 (19:46 +0100)]
Fix bogus test in body of a while loop

* lisp/gnus/nnheader.el (nnheader-find-nov-line): Fix return value
from while loop.

4 years ago* lisp/net/ldap.el (ldap-search-internal): Add missing setq.
Mattias Engdegård [Thu, 26 Dec 2019 18:44:13 +0000 (19:44 +0100)]
* lisp/net/ldap.el (ldap-search-internal): Add missing setq.

4 years agoOptimise 'while' bodies for effect
Mattias Engdegård [Thu, 26 Dec 2019 16:50:19 +0000 (17:50 +0100)]
Optimise 'while' bodies for effect

* lisp/emacs-lisp/byte-opt.el (byte-optimize-form-code-walker):
Treat all expressions in the body of 'while' as for-effect,
since their values are discarded.  This also finds some errors.

4 years agoCalc: add missing dynamic variable declarations
Mattias Engdegård [Thu, 26 Dec 2019 18:37:10 +0000 (19:37 +0100)]
Calc: add missing dynamic variable declarations

* lisp/calc/calc-alg.el (math-simplify-only, calc-simplify-mode)
(math-expand-formulas, calc-poly-div-remainder)
(math-living-dangerously, math-simplifying, calc-angle-mode)
(calc-prefer-frac, math-poly-base-variable):
Declare dynamic variables.
* test/lisp/calc/calc-tests.el (calc-poly-div):
Add test for at least one bug caused by missing declarations.

4 years ago* doc/emacs/buffers.texi (Kill Buffer): Improve indexing.
Eli Zaretskii [Thu, 26 Dec 2019 16:20:12 +0000 (18:20 +0200)]
* doc/emacs/buffers.texi (Kill Buffer): Improve indexing.

4 years agoUse regexp type for regexps in defcustom declarations
Mattias Engdegård [Sat, 21 Dec 2019 17:52:06 +0000 (18:52 +0100)]
Use regexp type for regexps in defcustom declarations

* lisp/calendar/diary-lib.el (diary-face-attrs):
* lisp/cedet/semantic/db-ebrowse.el (semanticdb-ebrowse-file-match):
* lisp/cedet/srecode/document.el
(srecode-document-autocomment-common-nouns-abbrevs)
(srecode-document-autocomment-function-alist)
(srecode-document-autocomment-return-first-alist)
(srecode-document-autocomment-return-last-alist)
(srecode-document-autocomment-param-alist)
(srecode-document-autocomment-param-type-alist):
* lisp/desktop.el (desktop-clear-preserve-buffers):
* lisp/elide-head.el (elide-head-headers-to-hide):
* lisp/erc/erc-backend.el (erc-encoding-coding-alist):
* lisp/erc/erc-ezbounce.el (erc-ezb-regexp):
* lisp/files.el (auto-save-file-name-transforms):
* lisp/gnus/deuglify.el (gnus-outlook-deuglify-attrib-cut-regexp)
(gnus-outlook-deuglify-attrib-verb-regexp)
(gnus-outlook-deuglify-attrib-end-regexp):
* lisp/gnus/gnus-fun.el (gnus-x-face-omit-files, gnus-face-omit-files):
* lisp/gnus/spam.el (spam-spamassassin-positive-spam-flag-header):
* lisp/htmlfontify.el (hfy-src-doc-link-unstyle):
* lisp/info-look.el (info-lookup-file-name-alist):
* lisp/international/rfc1843.el (rfc1843-newsgroups-regexp):
* lisp/mail/feedmail.el (feedmail-queue-slug-suspect-regexp):
* lisp/mail/rmail-spam-filter.el (rsf-white-list, rsf-definitions-alist):
* lisp/man.el (Man-name-local-regexp):
* lisp/net/ange-ftp.el (ange-ftp-dumb-unix-host-regexp):
* lisp/net/newst-backend.el (newsticker-auto-mark-filter-list):
* lisp/net/rcirc.el (rcirc-authinfo, rcirc-coding-system-alist):
* lisp/net/tramp-adb.el (tramp-adb-prompt):
* lisp/org/org-agenda.el (org-agenda-hide-tags-regexp)
(org-agenda-category-icon-alist):
* lisp/org/org-protocol.el (org-protocol-data-separator):
* lisp/org/org-table.el (org-table-number-regexp):
* lisp/org/ox-latex.el (org-latex-known-warnings):
* lisp/progmodes/bug-reference.el (bug-reference-bug-regexp):
* lisp/progmodes/hideif.el (hide-ifdef-header-regexp):
* lisp/progmodes/idlw-help.el (idlwave-help-doclib-name)
(idlwave-help-doclib-keyword):
* lisp/progmodes/idlwave.el (idlwave-no-change-comment):
* lisp/progmodes/python.el (python-shell-prompt-input-regexps)
(python-shell-prompt-output-regexps, python-shell-prompt-regexp)
(python-shell-prompt-block-regexp, python-shell-prompt-output-regexp)
(python-shell-prompt-pdb-regexp, python-shell-compilation-regexp-alist)
(python-pdbtrack-stacktrace-info-regexp):
* lisp/progmodes/sql.el (sql-send-terminator, sql-ansi-statement-starters):
* lisp/speedbar.el (speedbar-directory-unshown-regexp)
(speedbar-file-unshown-regexp):
* lisp/textmodes/flyspell.el (flyspell-mark-duplications-exceptions)
(flyspell-tex-command-regexp):
* lisp/textmodes/paragraphs.el (sentence-end-base):
* lisp/textmodes/tildify.el (tildify-pattern, tildify-space-pattern):
* lisp/vc/ediff-init.el (ediff-metachars):
* lisp/vc/vc-git.el (vc-git-root-log-format):
* lisp/vc/vc-hg.el (vc-hg-root-log-format):
* lisp/whitespace.el (whitespace-indentation-regexp)
(whitespace-space-after-tab-regexp):
* lisp/woman.el (woman-manpath-man-regexp)
(woman-imenu-generic-expression):
Use 'regexp' instead of 'string' as type for values that are regexps
in defcustom declarations.

4 years agoSpeed up dired-do-find-regexp
Dmitry Gutov [Thu, 26 Dec 2019 15:39:48 +0000 (17:39 +0200)]
Speed up dired-do-find-regexp

* lisp/dired-aux.el (dired-do-find-regexp): Speed up (bug#36857).
Previously, 'find' was called for every marked file (for plain
files and directories both).  Now 'find' is only called for
directories.

4 years ago; Remove outdated declarations
Dmitry Gutov [Thu, 26 Dec 2019 15:32:30 +0000 (17:32 +0200)]
; Remove outdated declarations

4 years ago; Clarify the assumption
Dmitry Gutov [Thu, 26 Dec 2019 15:31:11 +0000 (17:31 +0200)]
; Clarify the assumption

4 years agoproject--find-regexp-in-files: Support remote files
Dmitry Gutov [Thu, 26 Dec 2019 13:38:53 +0000 (15:38 +0200)]
project--find-regexp-in-files: Support remote files

* lisp/progmodes/project.el (project--find-regexp-in-files):
Support remote files (bug#34343).

4 years agoDocument some restrictions for module functions.
Philipp Stephani [Thu, 26 Dec 2019 10:31:51 +0000 (11:31 +0100)]
Document some restrictions for module functions.

* doc/lispref/internals.texi (Module Functions): Document some
restrictions for module functions.

4 years agoDon't recommend using 'module-load' for loading modules.
Philipp Stephani [Thu, 26 Dec 2019 10:08:56 +0000 (11:08 +0100)]
Don't recommend using 'module-load' for loading modules.

'module-load' most likely doesn't do what users expect.  Users should
use 'load' and its wrappers, which do the right thing.

* doc/lispref/loading.texi (Dynamic Modules): Document
disadvantages of 'module-load' and recommend normal 'load' and
its wrappers instead.

* doc/lispref/internals.texi (Module Functions): Recommend
'load' over 'module-load'.

4 years agoSimplify an example in the modules manual
Philipp Stephani [Thu, 26 Dec 2019 09:58:55 +0000 (10:58 +0100)]
Simplify an example in the modules manual

* doc/lispref/internals.texi (Module Misc): Simplify example for how
to call 'intern'.  There's no need to pass the optional argument
explicitly.

4 years agoPromote function type aliases to the public module API.
Philipp Stephani [Thu, 26 Dec 2019 09:29:21 +0000 (10:29 +0100)]
Promote function type aliases to the public module API.

Previously module authors had to define type aliases for module
functions and finalizers themselves.  This commit adds and documents
aliases so that this is no longer necessary.

* src/emacs-module.h.in: Add 'emacs_function' and 'emacs_finalizer'
type aliases.

* src/emacs-module.c: Remove old 'emacs_subr' and 'emacs_finalizer'
type aliases.
(struct Lisp_Module_Function, module_make_function): Switch from
'emacs_subr' to 'emacs_function'.

* doc/lispref/internals.texi (Module Functions): Document and use
'emacs_function' type alias.
(Module Values): Document 'emacs_finalizer' type alias.

* etc/NEWS: Mention change.

4 years agoPort x_get_monitor_attributes_fallback to !HAVE_GTK3
Paul Eggert [Wed, 25 Dec 2019 20:01:07 +0000 (12:01 -0800)]
Port x_get_monitor_attributes_fallback to !HAVE_GTK3

* src/xfns.c (x_get_net_workarea) [!HAVE_GTK3]:
Define in this case too, since x_get_monitor_attributes_fallback
contains a call to it regardless whether HAVE_GTK3 is defined.

4 years agoDon't always resort in recently introduced icomplete--sorted-completions
João Távora [Wed, 25 Dec 2019 19:18:17 +0000 (19:18 +0000)]
Don't always resort in recently introduced icomplete--sorted-completions

Doing so breaks icomplete-forward-completions and
icomplete-backward-completions.

* lisp/icomplete.el (icomplete--sorted-completions): Don't always
resort.

4 years agoDon't force completion recalculation in icomplete-fido-ret
João Távora [Wed, 25 Dec 2019 17:57:20 +0000 (17:57 +0000)]
Don't force completion recalculation in icomplete-fido-ret

Besides the adverse effect of delaying completions, it tripped up the
useful logic of icomplete-force-complete-and-exit in the case where a
default was available, but no completions calculated yet.

* lisp/icomplete.el (icomplete-fido-ret): Don't force calculation
of completions.

4 years agoCorrectly cache sorted completions in icomplete--sorted-completions
João Távora [Wed, 25 Dec 2019 17:54:00 +0000 (17:54 +0000)]
Correctly cache sorted completions in icomplete--sorted-completions

* lisp/icomplete.el (icomplete--sorted-completions): Use
completion--cache-all-sorted-completions.

4 years ago; * etc/NEWS: Fix a recently added entry.
Eli Zaretskii [Wed, 25 Dec 2019 17:26:07 +0000 (19:26 +0200)]
; * etc/NEWS: Fix a recently added entry.

4 years ago* .gitignore: Ignore .dylib files (shared libraries on macOS)
Philipp Stephani [Wed, 25 Dec 2019 17:13:12 +0000 (18:13 +0100)]
* .gitignore: Ignore .dylib files (shared libraries on macOS)

4 years agoAdd some documentation for support of .dylib suffix on macOS
Philipp Stephani [Wed, 25 Dec 2019 17:03:26 +0000 (18:03 +0100)]
Add some documentation for support of .dylib suffix on macOS

* doc/lispref/loading.texi (Dynamic Modules):
* etc/NEWS: Document that dynamic module files on macOS can now have
the suffix .dylib.

4 years agoFix compilation warning in gnus-start.el
Lars Ingebrigtsen [Wed, 25 Dec 2019 16:12:10 +0000 (17:12 +0100)]
Fix compilation warning in gnus-start.el

* lisp/gnus/gnus-start.el (gnus-gnus-to-quick-newsrc-format): Fix
compilation warning by not binding XEmacs-only variable.

* lisp/gnus/gnus-util.el (gnus-bind-print-variables): Ditto.
(gnus-prin1, gnus-prin1-to-string, gnus-pp, gnus-pp-to-string):
Adjust doc string.

4 years agoDon't bind XEmacs-only variable in edebug
Lars Ingebrigtsen [Wed, 25 Dec 2019 16:14:26 +0000 (17:14 +0100)]
Don't bind XEmacs-only variable in edebug

* lisp/emacs-lisp/edebug.el (edebug-safe-prin1-to-string): Remove
binding of XEmacs-only variable print-readably.

4 years agoMerge from origin/emacs-27
Glenn Morris [Wed, 25 Dec 2019 15:50:19 +0000 (07:50 -0800)]
Merge from origin/emacs-27

91c16acbe2 (origin/emacs-27) Improve doc string of 'files--message'
c3be58a8f5 (emacs-27) Improve vc--add-line, vc--remove-regexp
9ea9ac9a61 Apply the 'xref-group' property properly

4 years ago; Merge from origin/emacs-27
Glenn Morris [Wed, 25 Dec 2019 15:50:19 +0000 (07:50 -0800)]
; Merge from origin/emacs-27

The following commits were skipped:

41f0cf266e * src/pdumper.c (Fdump_emacs_portable): Reword error message.
719a6924c4 Don’t allow portable dumping in interactive mode (Bug#38453).

4 years agoMerge from origin/emacs-27
Glenn Morris [Wed, 25 Dec 2019 15:50:19 +0000 (07:50 -0800)]
Merge from origin/emacs-27

ca6a53d3bc Don't default to showing X-Faces externally in Gnus
dbf4b5b2d0 Fix manual typo in Special Read Syntax
a9fe6dfa90 Fix problem with emacs -nw / eww / svg
0de63092c8 Clarify base64 requirements and say what {en,de}code_codin...
6184aa003f ; * etc/NEWS: Fix boring oddities.
51ea32dd12 * src/emacs-module.h.in: Add reference to manual.
75d0cef20d Trivial docstring fixes
ee12c421b6 imagemagick-types needs to initialize ImageMagick

# Conflicts:
# etc/NEWS

4 years ago; Merge from origin/emacs-27
Glenn Morris [Wed, 25 Dec 2019 15:50:13 +0000 (07:50 -0800)]
; Merge from origin/emacs-27

The following commit was skipped:

9eb871c8d1 Cut the emacs-27 release branch

4 years agoImprove doc string of 'files--message'
Eli Zaretskii [Wed, 25 Dec 2019 15:00:06 +0000 (17:00 +0200)]
Improve doc string of 'files--message'

* lisp/files.el (files--message): Improve the wording of doc
string.  (Bug#38737)

4 years agoSupport .dylib suffix for modules on macOS (Bug#36226).
Philipp Stephani [Wed, 25 Dec 2019 14:41:39 +0000 (15:41 +0100)]
Support .dylib suffix for modules on macOS (Bug#36226).

On macOS, shared libraries typically have the suffix .dylib.  This
commit switches the module suffix to .dylib on Darwin to account for
that.  To also support the .so suffix, introduce the concept of a
secondary module suffix.

* configure.ac: Switch MODULES_SUFFIX to .dylib for Darwin, introduce
MODULES_SECONDARY_SUFFIX.

* src/lread.c (Fload, syms_of_lread): Also use
MODULES_SECONDARY_SUFFIX if defined.

* test/src/emacs-module-tests.el (module-darwin-secondary-suffix): New
unit test.