]> git.eshelyaron.com Git - emacs.git/log
emacs.git
6 years agoMerge from origin/emacs-26
Glenn Morris [Tue, 24 Jul 2018 13:40:58 +0000 (06:40 -0700)]
Merge from origin/emacs-26

f64c277 (origin/emacs-26) Let bookmark-jump override window-point (Bu...
1208aaa Omit keymap from subword-mode docstring (Bug#32212)
2b70b54 Prevent line-mode term from showing user passwords
5de4441 Check for special filenames in eshell (Bug#30724)
1b4b965 Fix indent-sexp of #s(...) (Bug#31984)
59e8533 Add save-match-data to abbreviate-file-name (Bug#32201)
47f75b1 Fix last change in editfns.c
671dc5a Fix calls to buffer modification hooks from replace-buffer-co...
cc4ceed ; etc/NEWS: Remove unnecessary reference to a bug number.
e0f33ea Fix Bug#32226
7308fa0 Improve doc strings of several variables in keyboard.c

6 years agoFix typo in `find-alternate-file'
Michael Albinus [Tue, 24 Jul 2018 08:16:22 +0000 (10:16 +0200)]
Fix typo in `find-alternate-file'

* lisp/files.el (find-alternate-file): Add missing arguments to
`find-file-noselect' call.

6 years agoLet bookmark-jump override window-point (Bug#31751)
Noam Postavsky [Tue, 24 Jul 2018 01:49:00 +0000 (21:49 -0400)]
Let bookmark-jump override window-point (Bug#31751)

* lisp/bookmark.el (bookmark-jump): Use pop-to-buffer-same-window
instead of switch-to-buffer, the latter obeys
switch-to-buffer-preserve-window-point and so loses the bookmark's
point.

6 years ago(format "%#x" 0) yields "0", not "0x0"
Paul Eggert [Mon, 23 Jul 2018 17:23:35 +0000 (10:23 -0700)]
(format "%#x" 0) yields "0", not "0x0"

* doc/lispref/strings.texi (Formatting Strings):
* src/editfns.c (Fformat): Document this.

6 years agoOmit keymap from subword-mode docstring (Bug#32212)
Noam Postavsky [Sun, 22 Jul 2018 20:15:43 +0000 (16:15 -0400)]
Omit keymap from subword-mode docstring (Bug#32212)

* lisp/progmodes/subword.el (subword-mode): Remove listing of
subword-mode-map bindings, since it is empty as of 2014-03-23 "Merge
capitalized-words-mode and subword-mode".

6 years agoPrevent line-mode term from showing user passwords
Tino Calancha [Thu, 15 Feb 2018 00:09:50 +0000 (09:09 +0900)]
Prevent line-mode term from showing user passwords

For buffers whose mode derive from comint-mode, the user password is
read from the minibuffer and it's hidden.  A buffer in term-mode and
line submode, instead shows the passwords.  Make buffers in line
term-mode to hide passwords too (Bug#30190).

* lisp/term.el (term-send-invisible): Prefer the more robust
`read-passwd' instead of `term-read-noecho'.
(term-watch-for-password-prompt): New function.
(term-emulate-terminal): Call it each time we receive non-escape
sequence output.

Co-authored-by: Noam Postavsky <npostavs@gmail.com>
6 years ago0x%x → %#x in elisp formats
Paul Eggert [Mon, 23 Jul 2018 07:57:06 +0000 (00:57 -0700)]
0x%x → %#x in elisp formats

* lisp/emacs-lisp/cl-print.el (cl-print-object):
* lisp/profiler.el (profiler-format-entry):
* lisp/progmodes/hideif.el (hif-evaluate-macro):
Prefer %#x to 0x%x in elisp formats when formatting arbitrary
integers, as it’ll produce more-readable output with negative args
should we change how negative values are printed with %x.

6 years agopositive → nonnegative doc fixes
Paul Eggert [Mon, 23 Jul 2018 07:05:25 +0000 (00:05 -0700)]
positive → nonnegative doc fixes

* doc/lispref/numbers.texi (Bitwise Operations)
(Math Functions):
* doc/lispref/strings.texi (Formatting Strings):
* src/editfns.c (Fformat):
Correct “positive” with “nonnegative” in some documentation.

6 years agoRevert "Make nnimap support IMAP namespaces"
Lars Ingebrigtsen [Mon, 23 Jul 2018 07:01:24 +0000 (09:01 +0200)]
Revert "Make nnimap support IMAP namespaces"

This reverts commit 7b5b3ddb2dfa98d640aff7b5b160f777e22cc794.

Insufficiently tested before committing -- bugs out several places
when not using namespaces.

6 years agoAdd \eqref to RefTeX's reference styles (Bug#32203)
Arash Esbati [Wed, 18 Jul 2018 19:20:12 +0000 (21:20 +0200)]
Add \eqref to RefTeX's reference styles (Bug#32203)

* lisp/textmodes/reftex-vars.el (reftex-ref-style-alist): Add entry
for \eqref provided by amsmath.sty and bind it to "e" key.

6 years agoPreserve nonblank whitespace when indenting (Bug#32200)
Noam Postavsky [Wed, 18 Jul 2018 23:11:23 +0000 (19:11 -0400)]
Preserve nonblank whitespace when indenting (Bug#32200)

* lisp/indent.el (indent-line-to): Remove only spaces and tabs, not
any whitespace syntax characters.

6 years agoAdd further clarifications to gnus-blocked-images
Lars Ingebrigtsen [Sun, 22 Jul 2018 13:57:49 +0000 (15:57 +0200)]
Add further clarifications to gnus-blocked-images

* lisp/gnus/gnus-art.el (gnus-blocked-images): Add further
clarifications.

6 years agoMake nnimap support IMAP namespaces
Nikolaus Rath [Sun, 22 Jul 2018 13:33:38 +0000 (15:33 +0200)]
Make nnimap support IMAP namespaces

* lisp/gnus/nnimap.el (nnimap-use-namespaces): Introduc new
server variable.
(nnimap-group-to-imap, nnimap-get-groups): Transform IMAP group
names to Gnus group name by stripping / prefixing personal
namespace prefix.
(nnimap-open-connection-1): Ask server for namespaces and store them.

* lisp/gnus/nnimap.el (nnimap-request-group-scan)
(nnimap-request-create-group, nnimap-request-delete-group)
(nnimap-request-rename-group, nnimap-request-move-article)
(nnimap-process-expiry-targets)
(nnimap-request-update-group-status)
(nnimap-request-accept-article, nnimap-request-list)
(nnimap-retrieve-group-data-early, nnimap-change-group)
(nnimap-split-incoming-mail): Use nnimap-group-to-imap.
(nnimap-group-to-imap): New function to map Gnus group names to
IMAP folder names.

6 years agoMake async :family 'local failures fail correctly again
Lars Ingebrigtsen [Sun, 22 Jul 2018 11:39:10 +0000 (13:39 +0200)]
Make async :family 'local failures fail correctly again

* src/fileio.c (get_file_errno_data): Refactor out into its own
function so that we can reuse the error handling from an async
context (bug#31901).

* src/process.c (connect_network_socket): When an async :family
'local client fails (with a file error, for instance), mark the
process as failed.

6 years agothread-join returns the result of finished thread
Michael Albinus [Sun, 22 Jul 2018 09:53:24 +0000 (11:53 +0200)]
thread-join returns the result of finished thread

* doc/lispref/threads.texi (Basic Thread Functions):
* etc/NEWS: Document return value of `thread-join'.

* src/thread.c (invoke_thread_function, Fmake_thread)
(init_main_thread): Set result.
(Fthread_join): Propagate signals, and return result.
(Vmain_thread): New defvar.

* src/thread.h (struct thread_state): Add `result' field.

* test/src/thread-tests.el (threads-join): Test also return value.
(threads-join-error): New test.
(threads-mutex-signal): Check for propagation of `quit' signal.

6 years agoAvoid destroying match data in 'setenv' (Bug#32201)
John Shahid [Thu, 19 Jul 2018 00:18:19 +0000 (20:18 -0400)]
Avoid destroying match data in 'setenv' (Bug#32201)

* lisp/env.el (setenv,setenv-internal): Replace string-match with
string-match-p.

6 years agoCheck for special filenames in eshell (Bug#30724)
Jonathan Kyle Mitchell [Tue, 17 Jul 2018 02:46:20 +0000 (21:46 -0500)]
Check for special filenames in eshell (Bug#30724)

* lisp/eshell/esh-cmd.el (eshell-lisp-command): Check for "~"
in lisp commands with the eshell-filename-arguments property
(Bug#30724).

* lisp/eshell/em-dirs.el (eshell/cd, eshell/pushd, eshell/popd):
* lisp/eshell/em-ls.el (eshell/ls):
* lisp/eshell/em-unix.el (eshell/rm, eshell/mkdir, eshell/rmdir)
(eshell/mv, eshell/cp, eshell/ln, eshell/cat, eshell/du, eshell/diff):
* lisp/eshell/esh-ext.el (eshell/addpath): Add
eshell-filename-arguments to symbol plist.

6 years agoFix indent-sexp of #s(...) (Bug#31984)
Noam Postavsky [Thu, 19 Jul 2018 10:40:54 +0000 (06:40 -0400)]
Fix indent-sexp of #s(...) (Bug#31984)

* lisp/emacs-lisp/lisp-mode.el (indent-sexp): Look for a sexp that
ends after the current line.
* test/lisp/emacs-lisp/lisp-mode-tests.el (indent-sexp-go): New test.

6 years agoAdd save-match-data to abbreviate-file-name (Bug#32201)
Noam Postavsky [Wed, 18 Jul 2018 22:45:47 +0000 (18:45 -0400)]
Add save-match-data to abbreviate-file-name (Bug#32201)

* lisp/files.el (abbreviate-file-name): Save match-data around
expand-file-name; it is not guaranteed to preserve match-data, and may
well do so depending on what file handlers and hooks are in effect.

6 years agoFix last change in editfns.c
Eli Zaretskii [Sat, 21 Jul 2018 19:27:33 +0000 (22:27 +0300)]
Fix last change in editfns.c

* src/editfns.c (Freplace_buffer_contents): Fix last change: always
call buffer modification hooks, even if nothing was deleted/inserted.
(bug#32237)

6 years agoFix calls to buffer modification hooks from replace-buffer-contents
Eli Zaretskii [Sat, 21 Jul 2018 18:05:52 +0000 (21:05 +0300)]
Fix calls to buffer modification hooks from replace-buffer-contents

* src/editfns.c (Freplace_buffer_contents): Don't call buffer
modification hooks if nothing was deleted/inserted.  (Bug#32237)

6 years ago; etc/NEWS: Remove unnecessary reference to a bug number.
Eli Zaretskii [Sat, 21 Jul 2018 16:44:38 +0000 (19:44 +0300)]
; etc/NEWS: Remove unnecessary reference to a bug number.

6 years agoPacify GCC 7 with -Wformat-overflow
Ken Brown [Sat, 21 Jul 2018 16:15:22 +0000 (12:15 -0400)]
Pacify GCC 7 with -Wformat-overflow

* src/w32term.c (x_draw_glyphless_glyph_string_foreground):
Force sprintf to write at most 6 bytes, excluding the
terminating null byte.

6 years agoMinor rewording of last change
Eli Zaretskii [Sat, 21 Jul 2018 16:11:32 +0000 (19:11 +0300)]
Minor rewording of last change

* lisp/vc/add-log.el (add-log-dont-create-changelog-file)
(add-log--pseudo-changelog-buffer-name)
(add-log--changelog-buffer-p, add-change-log-entry): Doc fixes.

* etc/NEWS: Improve wording of last change.

* doc/emacs/maintaining.texi (Change Log Commands): Improve
wording of last change.

6 years agoNew option to make 'C-x 4 a' use file-less ChangeLog buffers
João Távora [Sat, 21 Jul 2018 14:54:21 +0000 (15:54 +0100)]
New option to make 'C-x 4 a' use file-less ChangeLog buffers

* doc/emacs/maintaining.texi (Change Log Commands): Document
add-log-dont-create-changelog-file.

* etc/NEWS (Change Logs Mode): Mention
add-log-dont-create-changelog-file.

* lisp/vc/add-log.el (add-log-file-name): Add comment.
(add-log-dont-create-changelog-file): New variable.
(add-log--pseudo-changelog-buffer-name)
(add-log--changelog-buffer-p): New helpers.
(add-log-find-changelog-buffer): New function.
(add-log--pseudo-changelog-buffer-name): Respect
add-log-dont-create-changelog-file.

* lisp/vc/log-edit.el (log-edit-changelog-entries): Use
add-log-find-changelog-buffer.

6 years agoMake ielm accept an optional buffer name param
Bozhidar Batsov [Sat, 21 Jul 2018 11:00:11 +0000 (14:00 +0300)]
Make ielm accept an optional buffer name param

The ielm buffer name was hardcoded which made it hard for programs to
interactively create ielm buffers with different names and switch to
them (e.g. perhaps you want to have one ielm buffer for each of the
Elisp projects you're working on).

6 years agoFix Bug#32226
Michael Albinus [Sat, 21 Jul 2018 10:29:06 +0000 (12:29 +0200)]
Fix Bug#32226

* lisp/shadowfile.el (shadow-site-name, shadow-name-site):
Use "[-.[:word:]]+" as hostname regexp.  (Bug#32226)

* test/lisp/shadowfile-tests.el (shadow-test06-literal-groups)
(shadow-test07-regexp-groups, shadow-test08-shadow-todo)
(shadow-test09-shadow-copy-files): Skip if needed.

6 years agoImprove doc strings of several variables in keyboard.c
Eli Zaretskii [Sat, 21 Jul 2018 09:28:11 +0000 (12:28 +0300)]
Improve doc strings of several variables in keyboard.c

* src/keyboard.c (syms_of_keyboard) <debug-on-event>
<attempt-stack-overflow-recovery>
<attempt-orderly-shutdown-on-fatal-signal>: Make sure the first
sentence of the doc string fits on a single line.

6 years agoFix recording keyboard macros when input method is active
Eli Zaretskii [Sat, 21 Jul 2018 09:10:20 +0000 (12:10 +0300)]
Fix recording keyboard macros when input method is active

* lisp/international/quail.el (quail-start-translation)
(quail-start-conversion): Bind inhibit--record-char to t for
the first character of a translated sequence.

* src/keyboard.c (record_char): Don't record events from
macros to dribble file, per documentation.
(Fopen_dribble_file): Doc fix.
(syms_of_keyboard) <inhibit--record-char>: New variable.
(record_char): Don't record input event if
inhibit--record-char is non-nil.  (Bug#32108)

6 years agoReport base of out-of-range input fixnums
Paul Eggert [Sat, 21 Jul 2018 07:25:27 +0000 (00:25 -0700)]
Report base of out-of-range input fixnums

* src/lread.c (string_to_number): Report the base of an
out-of-range fixnum.  Problem reported by Andy Moreton in:
https://lists.gnu.org/r/emacs-devel/2018-07/msg00696.html

6 years ago* src/fns.c (Feql, Fequal): Improve floating-point doc.
Paul Eggert [Fri, 20 Jul 2018 20:55:12 +0000 (13:55 -0700)]
* src/fns.c (Feql, Fequal): Improve floating-point doc.

6 years ago; Merge from origin/emacs-26
Glenn Morris [Fri, 20 Jul 2018 17:00:32 +0000 (10:00 -0700)]
; Merge from origin/emacs-26

The following commit was skipped:

61de292 (origin/emacs-26) Fix (Bug#32218).  Do not merge with master

6 years agoMerge from origin/emacs-26
Glenn Morris [Fri, 20 Jul 2018 17:00:32 +0000 (10:00 -0700)]
Merge from origin/emacs-26

3e72298 Improve documentation of 'pcase-defmacro rx'
ba9b9bb Fix TTY colors breakage by 'clear-face-cache'
f56ad42 * admin/MAINTAINERS: Add files maintained by me (Michael Albi...
7a258fa Adapt shadowfile.el for Tramp  (Bug#4526, Bug#4846)
cb50077 Fix auth-source-delete (Bug#26184)
a4767a6 Avoid assertion violations in gnutls.c
90110f8 Don't use a literal "C-u" in ispell.el  help message text
f4e7f6d Improve documentation of 'seqp'
ed13639 Clarify usage and dependencies between several Flyspell features

Conflicts:
etc/NEWS
test/lisp/auth-source-tests.el

6 years agoSimplify w32cygwinx.c and pacify GCC (Bug#32189)
Paul Eggert [Thu, 19 Jul 2018 23:12:17 +0000 (16:12 -0700)]
Simplify w32cygwinx.c and pacify GCC (Bug#32189)

* src/w32cygwinx.c (format_string): New function.
(Fw32_battery_status): Use it.

6 years ago* lisp/net/trampver.el (customize-package-emacs-version-alist):
Michael Albinus [Fri, 20 Jul 2018 09:30:04 +0000 (11:30 +0200)]
* lisp/net/trampver.el (customize-package-emacs-version-alist):

Add Tramp version integrated in Emacs 26.2.

6 years agoFix (Bug#32218). Do not merge with master
Michael Albinus [Fri, 20 Jul 2018 08:56:41 +0000 (10:56 +0200)]
Fix (Bug#32218).  Do not merge with master

* doc/misc/trampver.texi:
* lisp/net/trampver.el: Change version to "2.3.4.26.2".
(customize-package-emacs-version-alist): Add Tramp version
integrated in Emacs 26.2.

* lisp/net/tramp.el (tramp-handle-file-truename):
* lisp/net/tramp-adb.el (tramp-adb-handle-file-truename):
* lisp/net/tramp-sh.el (tramp-sh-handle-file-truename): Fix problem
with trailing slash.  (Bug#32218)

* test/lisp/net/tramp-tests.el (tramp-test21-file-links):
Remove `tramp--test-emacs27-p' check.

6 years agoImprove documentation of 'pcase-defmacro rx'
Eli Zaretskii [Fri, 20 Jul 2018 08:44:36 +0000 (11:44 +0300)]
Improve documentation of 'pcase-defmacro rx'

* lisp/emacs-lisp/rx.el (rx): Clarify and improve the doc string.
For the details, see the discussion starting at
http://lists.gnu.org/archive/html/emacs-devel/2018-06/msg00399.html.

6 years agoPrefer NILP (x) to EQ (x, Qnil)
Paul Eggert [Fri, 20 Jul 2018 05:03:34 +0000 (22:03 -0700)]
Prefer NILP (x) to EQ (x, Qnil)

This simplifies the code a bit, and also simplifies some
potential future changes slightly (e.g., altering eq vs eql).
* src/alloc.c (mark_object):
* src/callint.c (fix_command):
* src/chartab.c (Fchar_table_range, Fset_char_table_range):
* src/dbusbind.c (XD_OBJECT_TO_DBUS_TYPE, xd_signature):
* src/dired.c (Fsystem_users):
* src/fileio.c (Fdo_auto_save):
* src/fns.c (concat):
* src/frame.c (get_frame_param, frame_inhibit_resize)
(store_in_alist, store_frame_param, x_set_autoraise)
(x_set_autolower, x_get_arg):
* src/image.c (Fclear_image_cache):
* src/intervals.c (intervals_equal):
* src/intervals.h (DEFAULT_INTERVAL_P):
* src/lread.c (substitute_object_recurse):
* src/menu.c (digest_single_submenu)
(find_and_call_menu_selection)
(find_and_return_menu_selection):
* src/nsfns.m (x_set_icon_name, Fx_create_frame):
* src/nsmenu.m (ns_menu_show):
* src/nsselect.m (ns_string_to_pasteboard_internal)
(Fns_selection_exists_p, Fns_selection_owner_p):
* src/process.c (Faccept_process_output)
(wait_reading_process_output):
* src/terminal.c (store_terminal_param):
* src/textprop.c (verify_interval_modification):
* src/xdisp.c (next_element_from_buffer):
* src/xfaces.c (Finternal_set_lisp_face_attribute):
* src/xfns.c (x_set_icon_type, Fx_synchronize):
* src/xmenu.c (x_menu_show):
* src/xselect.c (Fx_selection_owner_p)
(Fx_selection_exists_p):
* src/xwidget.c (xwidget_view_lookup):
Prefer NILP (x) to EQ (x, Qnil).

6 years agoImprove doc for floating point ‘=’ vs ‘eql’
Paul Eggert [Thu, 19 Jul 2018 20:29:28 +0000 (13:29 -0700)]
Improve doc for floating point ‘=’ vs ‘eql’

* doc/lispref/numbers.texi (Float Basics, Comparison of Numbers):
Improve documentation of ‘=’ vs ‘eq’, ‘eql’ and ‘equal’
when NaNs and signed zeros are involved.

6 years ago; * etc/NEWS: Fix confused documentation markers.
Charles A. Roelli [Thu, 19 Jul 2018 20:17:24 +0000 (22:17 +0200)]
; * etc/NEWS: Fix confused documentation markers.

The options.el marker was accidentally moved in 2018-07-16
"Improve description of window configs in 'register-val-describe'".

6 years agoAdd 'font-lock-maximum-decoration' levels for Python
Charles A. Roelli [Thu, 19 Jul 2018 20:06:07 +0000 (22:06 +0200)]
Add 'font-lock-maximum-decoration' levels for Python

* etc/NEWS: New entry under Python mode.

* lisp/progmodes/python.el (python-font-lock-keywords-level-1)
(python-font-lock-keywords-level-2)
(python-font-lock-keywords-maximum-decoration): New variables
based off the incumbent 'python-font-lock-keywords'.
(python-font-lock-keywords): Change it to a list of the new
symbols, for use in the 'car' of 'font-lock-defaults'.
(python-mode): Set the 'car' of 'font-lock-defaults' to the
value of 'python-font-lock-keywords', instead of the symbol
'python-font-lock-keywords'.

6 years agoFix TTY colors breakage by 'clear-face-cache'
Eli Zaretskii [Thu, 19 Jul 2018 17:44:32 +0000 (20:44 +0300)]
Fix TTY colors breakage by 'clear-face-cache'

Without examining the right frame, 'tty-color-24bit' was erroneously
treating a GUI frame as a 24-bit TTY frame.
* lisp/term/tty-colors.el (tty-color-24bit): Accept optional
argument DISPLAY and pass it to display-color-cells.  Doc fix.
(tty-color-define, tty-color-desc): Pass the FRAME argument to
tty-color-24bit.  (Bug#32072)

6 years ago* etc/NEWS: Fix eql typo in previous change.
Paul Eggert [Wed, 18 Jul 2018 18:27:06 +0000 (11:27 -0700)]
* etc/NEWS: Fix eql typo in previous change.

6 years ago* admin/MAINTAINERS: Add files maintained by me (Michael Albinus).
Michael Albinus [Wed, 18 Jul 2018 14:52:12 +0000 (16:52 +0200)]
* admin/MAINTAINERS: Add files maintained by me (Michael Albinus).

6 years agoAdapt shadowfile.el for Tramp (Bug#4526, Bug#4846)
Michael Albinus [Wed, 18 Jul 2018 14:51:56 +0000 (16:51 +0200)]
Adapt shadowfile.el for Tramp  (Bug#4526, Bug#4846)

* etc/NEWS: Mention changes in shadowfile.el.

* lisp/shadowfile.el (top): Require 'tramp instead of 'ange-ftp.
(shadow-cluster): New defstruct.
(shadow-make-cluster, shadow-cluster-name, shadow-cluster-primary)
(shadow-cluster-regexp, shadow-get-user)
(shadow-parse-fullname): Remove.
(shadow-info-file, shadow-todo-file, shadow-system-name)
(shadow-homedir, shadow-regexp-superquote, shadow-suffix)
(shadow-set-cluster, shadow-get-cluster, shadow-site-name)
(shadow-name-site, shadow-site-primary, shadow-site-cluster)
(shadow-read-site, shadow-parse-name, shadow-make-fullname)
(shadow-replace-name-component, shadow-local-file)
(shadow-expand-cluster-in-file-name, shadow-contract-file-name)
(shadow-same-site, shadow-file-match, shadow-define-cluster)
(shadow-define-literal-group, shadow-define-regexp-group)
(shadow-make-group, shadow-shadows-of-1, shadow-read-files)
(shadow-write-info-file, shadow-write-todo-file)
(shadow-initialize): Adapt variables and functions.

* test/lisp/shadowfile-tests.el: New file.

6 years ago* lisp/comint.el: Clean up namespace
Stefan Monnier [Wed, 18 Jul 2018 14:23:20 +0000 (10:23 -0400)]
* lisp/comint.el: Clean up namespace

(shell-strip-ctrl-m): Mark as obsolete.
(comint-send-invisible): Rename from `send-invisible`.
(send-invisible): Make it an obsolete alias.
* lisp/net/rlogin.el: Adjust accordingly; Use lexical-binding.
* lisp/shell.el: Adjust accordingly.

6 years agoFix imenu--generic-function after fix for Bug#32024.
Filipp Gunbin [Wed, 18 Jul 2018 13:11:47 +0000 (16:11 +0300)]
Fix imenu--generic-function after fix for Bug#32024.

* lisp/imenu.el (imenu--generic-function): Restore returning of nconc
  result from the function.  Move filtering out empty menus so it is
  done before removing dummy element and splicing main element into
  index-alist.

6 years ago* etc/NEWS: Mention eql etc. NaN fix.
Paul Eggert [Wed, 18 Jul 2018 11:55:34 +0000 (04:55 -0700)]
* etc/NEWS: Mention eql etc. NaN fix.

6 years agoFix bug with eql etc. on NaNs
Paul Eggert [Wed, 18 Jul 2018 10:16:54 +0000 (03:16 -0700)]
Fix bug with eql etc. on NaNs

Fix a bug where eql, sxhash-eql, memql, and make-hash-table
were not consistent on NaNs.  Likewise for equal,
sxhash-equal, member, and make-hash-table.  Some of these
functions ignored NaN significands, whereas others treated
them as significant.  It's more logical to treat significands
as significant, and this typically makes eql a bit more
efficient on floats, with just one integer comparison instead
of one to three floating-point comparisons.
* doc/lispref/numbers.texi (Float Basics): Document that
NaNs are never numerically equal, but might be eql.
* src/fns.c (WORDS_PER_DOUBLE): Move to top level of this file.
(union double_and_words): Now named, and at the top level of this file.
(same_float): New function.
(Fmemql, Feql, internal_equal, cmpfn_eql): Use it, so that
the corresponding functions treat NaNs consistently.
(sxhash_float): Simplify based on above-mentioned changes.

* test/src/fns-tests.el (fns-tests-equality-nan): New test.

6 years ago* lisp/net/soap-client.el (soap-type-of): Optimize for Emacs≥26
Stefan Monnier [Wed, 18 Jul 2018 02:22:15 +0000 (22:22 -0400)]
* lisp/net/soap-client.el (soap-type-of): Optimize for Emacs≥26

6 years agoRemove menu name from emacs-lisp-mode-map (Bug#27114)
Alex [Wed, 9 Aug 2017 23:07:57 +0000 (17:07 -0600)]
Remove menu name from emacs-lisp-mode-map (Bug#27114)

* lisp/progmodes/elisp-mode.el (emacs-lisp-mode-map): Don't give a
menu name to the top-level map, the menu name is only useful for the
menu-map.

6 years agoFix auth-source-delete (Bug#26184)
Noam Postavsky [Wed, 18 Jul 2018 01:00:27 +0000 (21:00 -0400)]
Fix auth-source-delete (Bug#26184)

* lisp/auth-source.el (auth-source-delete): Fix `auth-source-search'
call.
* test/lisp/auth-source-tests.el (auth-source-delete): New test.

6 years agoUpdate from gnulib
Paul Eggert [Tue, 17 Jul 2018 22:45:27 +0000 (15:45 -0700)]
Update from gnulib

This incorporates:
2018-07-17 gnulib-tool: limit line length for git send-email
* lib/gnulib.mk.in: Regenerate.

6 years agoAvoid assertion violations in gnutls.c
Eli Zaretskii [Tue, 17 Jul 2018 16:58:27 +0000 (19:58 +0300)]
Avoid assertion violations in gnutls.c

* src/gnutls.c (Fgnutls_hash_digest, gnutls_symmetric)
(Fgnutls_hash_mac): Check CONSP before invoking XCDR.  (Bug#32187)
Report values of invalid arguments when signaling an error.

6 years agoUpdate from Gnulib
Paul Eggert [Tue, 17 Jul 2018 16:26:39 +0000 (09:26 -0700)]
Update from Gnulib

This causes config.guess to assume support for shell functions,
a safe assumption nowadays.
* build-aux/config.guess, build-aux/config.sub: Copy from Gnulib.

6 years ago; * etc/NEWS: Mention 'main-thread'. (Bug#32169)
Eli Zaretskii [Tue, 17 Jul 2018 15:46:02 +0000 (18:46 +0300)]
; * etc/NEWS: Mention 'main-thread'.  (Bug#32169)

6 years agoAdd variable main-thread, fix Bug#32169
Michael Albinus [Tue, 17 Jul 2018 10:03:43 +0000 (12:03 +0200)]
Add variable main-thread, fix Bug#32169

* doc/lispref/threads.texi (Basic Thread Functions): Add example,
how to propagate signals to the main thread.  Describe variable
`main-thread'.  Document optional argument CLEANUP of
`thread-last-error'.

* src/thread.c (Fthread_last_error): Add optional argument
CLEANUP.  (Bug#32169)
(main-thread): New defvar.

* test/src/thread-tests.el (thread-last-error): Adapt declaration.
(main-thread): Declare.
(threads-main-thread): New test.
(threads-errors): Extend test.

6 years agoImprove description of window configs in 'register-val-describe'
Charles A. Roelli [Mon, 16 Jul 2018 18:57:06 +0000 (20:57 +0200)]
Improve description of window configs in 'register-val-describe'

* etc/NEWS: Describe the change.
* lisp/register.el (register-val-describe)
[(window-configuration-p (car val))]: Include the shown
buffers in the return value to make
'register-read-with-preview' more useful.  (Bug#30863)

6 years ago* configure.ac [$HAVE_NS]: Correct build instructions.
Charles A. Roelli [Mon, 16 Jul 2018 18:36:31 +0000 (20:36 +0200)]
* configure.ac [$HAVE_NS]: Correct build instructions.

Running 'make install' to test a repo build on macOS used to
be required, but is no longer needed.

6 years ago; Remove tracing for epg-tests (Bug#23561)
Noam Postavsky [Mon, 16 Jul 2018 11:10:14 +0000 (07:10 -0400)]
; Remove tracing for epg-tests (Bug#23561)

6 years agoReject gpg 2.0 for epg configs by default (Bug#23561)
Noam Postavsky [Mon, 16 Jul 2018 01:40:05 +0000 (21:40 -0400)]
Reject gpg 2.0 for epg configs by default (Bug#23561)

Previously, gpg2 2.0 would be rejected, but the same version installed
as "gpg" would be accepted.

* lisp/epg-config.el (epg-gpg2-minimum-version): New constant.
(epg-config--program-alist) <OpenPGP>: Require a version in 1.4.3..2.0
or 2.1.6+., not just anything above 1.4.3.
(epg-check-configuration): Accept a list of required version
intervals, in addtion to just a single minimum.

6 years ago* lisp/format.el (format-proper-list-p): New alias.
Paul Eggert [Mon, 16 Jul 2018 01:28:35 +0000 (18:28 -0700)]
* lisp/format.el (format-proper-list-p): New alias.

6 years ago; Trace epg-tests (Bug#23561)
Noam Postavsky [Sat, 14 Jul 2018 12:58:26 +0000 (08:58 -0400)]
; Trace epg-tests (Bug#23561)

6 years agoDon't test symmetric operations on gpg 2.0 (Bug#23561)
Noam Postavsky [Sun, 15 Jul 2018 13:37:59 +0000 (09:37 -0400)]
Don't test symmetric operations on gpg 2.0 (Bug#23561)

On the Hydra test machines, which have gpg 2.0, the symmetric tests
fail.
* test/lisp/epg-tests.el (with-epg-tests): Pass REQUIRE-PUBLIC-KEY to
`epg-tests-find-usable-gpg-configuration' and call it before
`epg-make-context' so that the latter uses the resulting cached
config.
(epg-tests-find-usable-gpg-configuration): Only allow gpg 2.0 for
symmetric operations.  Clear `epg--configurations' and don't pass
NO-CACHE to `epg-find-configuration'.
(epg-tests--config-program-alist): Use copy-tree to avoid modifying
the epg-config--program-alist cons values.
* test/lisp/emacs-lisp/package-tests.el (package-test-signed): Allow
running with gpg 2.0.

6 years agoPrecise dav/davs in Tramp manual
Michael Albinus [Sun, 15 Jul 2018 07:47:47 +0000 (09:47 +0200)]
Precise dav/davs in Tramp manual

* doc/misc/tramp.texi (GVFS based methods): Mention `owncloud'
method for special `dav'/`davs' file names.

6 years agoFix Bug#32147
Michael Albinus [Sun, 15 Jul 2018 07:47:08 +0000 (09:47 +0200)]
Fix Bug#32147

* test/lisp/net/secrets-tests.el (secrets-test02-collections)
(secrets-test03-items): Test for both "Login" or "login"
collection.  (Bug#32147)

6 years agoUpdate package.el test for message format changes
Noam Postavsky [Sun, 15 Jul 2018 04:06:29 +0000 (00:06 -0400)]
Update package.el test for message format changes

* test/lisp/emacs-lisp/package-tests.el (package-test-signed): Update
the expected message.  The message was changed in 2018-06-25 "Reformat
package.el message strings for future l10n".
(with-package-test, with-fake-help-buffer): Add debug declarations.

6 years agoFix gpg detection for tests (Bug#23561)
Noam Postavsky [Sun, 15 Jul 2018 03:45:27 +0000 (23:45 -0400)]
Fix gpg detection for tests (Bug#23561)

* test/lisp/emacs-lisp/package-tests.el (package-test-signed): Stop
using epg-check-configuration and ignore-errors, they're redundant
because epg-find-configuration already does all that.
* test/lisp/epg-tests.el (epg-tests-find-usable-gpg-configuration):
Remove tracing.
(with-epg-tests): Skip test if no gpg config is found.
(epg-decrypt-1 epg-roundtrip-1, epg-sign-verify-1, epg-sign-verify-2)
(epg-import-1): Don't check gpg configuration at top-level, rely on
`with-epg-tests' instead.  Checking the gpg configuration requires a
valid HOME (or GNUPGHOME), which is provided by `with-epg-tests'.

6 years ago; Trace gpg stderr config output during epg-tests (Bug#23561)
Noam Postavsky [Sun, 15 Jul 2018 00:04:25 +0000 (20:04 -0400)]
; Trace gpg stderr config output during epg-tests (Bug#23561)

6 years ago; Further tracing of epg-tests gpg config (Bug#23561)
Noam Postavsky [Sat, 14 Jul 2018 22:31:49 +0000 (18:31 -0400)]
; Further tracing of epg-tests gpg config (Bug#23561)

6 years agoDon't use a literal "C-u" in ispell.el help message text
Eli Zaretskii [Sat, 14 Jul 2018 15:53:40 +0000 (18:53 +0300)]
Don't use a literal "C-u" in ispell.el  help message text

* lisp/textmodes/ispell.el (ispell-command-loop): Use
"\\[universal-argument]" instead of a literal "C-u".  (Bug#32142)

6 years agoAdd to documentation of 'jump-to-register'
Charles A. Roelli [Sat, 14 Jul 2018 13:12:36 +0000 (15:12 +0200)]
Add to documentation of 'jump-to-register'

* lisp/register.el (jump-to-register):
* doc/emacs/regs.texi (Position Registers): Document that
jumping to a register can push the mark.

6 years ago; Trace epg-tests gpg config finding (Bug#23561)
Noam Postavsky [Sat, 14 Jul 2018 12:58:26 +0000 (08:58 -0400)]
; Trace epg-tests gpg config finding (Bug#23561)

6 years agoAvoid infloop in redisplay due to faulty mode-line properties
Jonathan Kyle Mitchell [Thu, 5 Jul 2018 03:38:29 +0000 (22:38 -0500)]
Avoid infloop in redisplay due to faulty mode-line properties

* xdisp.c (safe_set_text_properties): New function.
(display_mode_element): Call Fset_text_properties through
internal_condition_case_n, using safe_set_text_properties as a
wrapper.  (Bug#32038)

6 years agoImprove documentation of 'seqp'
Eli Zaretskii [Sat, 14 Jul 2018 08:18:04 +0000 (11:18 +0300)]
Improve documentation of 'seqp'

* doc/lispref/sequences.texi (Sequence Functions): Add text to
explain the relation between 'seqp' and 'sequencep'.  (Bug#32125)

6 years agoClarify usage and dependencies between several Flyspell features
Eli Zaretskii [Sat, 14 Jul 2018 07:43:32 +0000 (10:43 +0300)]
Clarify usage and dependencies between several Flyspell features

* lisp/textmodes/flyspell.el (flyspell-region)
(flyspell-small-region, flyspell-persistent-highlight):
Documentation improvements.  (Bug#32142)

6 years ago* lisp/vc/diff-mode.el (diff-font-lock-prettify): New var
Stefan Monnier [Fri, 13 Jul 2018 16:34:50 +0000 (12:34 -0400)]
* lisp/vc/diff-mode.el (diff-font-lock-prettify): New var

(diff--font-lock-prettify): New function.
(diff-font-lock-keywords): Use it.

6 years agoMerge from origin/emacs-26
Glenn Morris [Fri, 13 Jul 2018 16:28:15 +0000 (09:28 -0700)]
Merge from origin/emacs-26

17ebb6e (origin/emacs-26) Use consistent function names in thread-tes...
1c86229 Fix format error in Faccept_process_output
b38b91a Lessen stack consumption in recursive read1
3eb4603 Match w32 paths in grep sans --null hits (Bug#32051)
5cc7c4b Fix previous make-network-process change
d6a1b69 Another documentation improvement in flyspell.el
9b49a8e Improve documentation of Flyspell
3744fda Provide feature 'threads
ef9025f Save the server alias on reconnect (Bug#29657)
db3874b Refer to "proper lists" instead of "true lists"
35e0305 Avoid turning on the global-minor-mode recursively
51bf4e4 Fix Bug#32085

6 years agoTweak subr-x.el substring functions
Basil L. Contovounesios [Fri, 1 Jun 2018 20:58:10 +0000 (21:58 +0100)]
Tweak subr-x.el substring functions

* lisp/emacs-lisp/subr-x.el (string-join): #'-quote function symbol.
(string-trim-left, string-trim-right):
Make better use of substring for minor speedup.
* test/lisp/emacs-lisp/subr-x-tests.el
(subr-x-test-string-trim-left, subr-x-test-string-trim-right)
(subr-x-test-string-remove-prefix)
(subr-x-test-string-remove-suffix): New tests.

6 years agoMinor cus-theme.el simplifications
Basil L. Contovounesios [Thu, 10 May 2018 02:08:10 +0000 (03:08 +0100)]
Minor cus-theme.el simplifications

* lisp/cus-theme.el (custom-new-theme-mode, customize-themes)
(custom-theme-choose-mode): Use setq-local.
(customize-create-theme): Ditto.  Use delete-all-overlays.
(describe-theme-1, custom-theme-summary): Simplify logic.

6 years agoMinor custom.el simplifications
Basil L. Contovounesios [Thu, 31 May 2018 17:37:02 +0000 (18:37 +0100)]
Minor custom.el simplifications

* lisp/custom.el (custom-quote): Duplicate macroexp-quote.
(custom-load-symbol, customize-mark-to-save, customize-mark-as-set)
(custom-theme-name-valid-p, enable-theme, custom-enabled-themes)
(disable-theme): Simplify logic.

6 years ago* lisp/cus-theme.el: Use lexical-binding
Basil L. Contovounesios [Fri, 11 May 2018 14:35:09 +0000 (15:35 +0100)]
* lisp/cus-theme.el: Use lexical-binding

6 years ago* lisp/custom.el: Use lexical-binding
Basil L. Contovounesios [Fri, 11 May 2018 15:09:57 +0000 (16:09 +0100)]
* lisp/custom.el: Use lexical-binding

Remove duplicate 'Custom Themes' comment heading.
(deftheme, custom-declare-theme): Fix advertised calling convention.
(custom-enabled-themes): Fix message grammar.

6 years agoFix custom-available-themes file expansion
Basil L. Contovounesios [Mon, 4 Jun 2018 01:12:33 +0000 (02:12 +0100)]
Fix custom-available-themes file expansion

For discussion, see thread starting at
https://lists.gnu.org/archive/html/emacs-devel/2018-05/msg00222.html.
* lisp/custom.el: (custom-available-themes): Use directory-files
instead of performing arbitrary wildcard expansion in file names.
(custom-theme--load-path): Document return value.
* test/lisp/custom-tests.el: New file.
(custom-theme--load-path): New test.

6 years agoDisable no-byte-compile in built-in themes
Basil L. Contovounesios [Wed, 9 May 2018 21:30:48 +0000 (22:30 +0100)]
Disable no-byte-compile in built-in themes

* etc/themes/adwaita-theme.el:
* etc/themes/deeper-blue-theme.el:
* etc/themes/dichromacy-theme.el:
* etc/themes/leuven-theme.el:
* etc/themes/light-blue-theme.el:
* etc/themes/manoj-dark-theme.el:
* etc/themes/misterioso-theme.el:
* etc/themes/tango-dark-theme.el:
* etc/themes/tango-theme.el:
* etc/themes/tsdh-dark-theme.el:
* etc/themes/tsdh-light-theme.el:
* etc/themes/wheatgrass-theme.el:
* etc/themes/whiteboard-theme.el:
* etc/themes/wombat-theme.el: Disable no-byte-compile.

https://lists.gnu.org/archive/html/emacs-devel/2018-01/msg00614.html
https://lists.gnu.org/archive/html/emacs-devel/2018-02/msg00060.html

6 years agoImprove loading of byte-compiled custom themes
Basil L. Contovounesios [Wed, 9 May 2018 21:20:47 +0000 (22:20 +0100)]
Improve loading of byte-compiled custom themes

* lisp/custom.el (load-theme):
Load byte-compiled file of safe themes when available.

https://lists.gnu.org/archive/html/emacs-devel/2018-01/msg00614.html
https://lists.gnu.org/archive/html/emacs-devel/2018-02/msg00060.html

6 years agoUse consistent function names in thread-tests.el
Michael Albinus [Fri, 13 Jul 2018 12:28:12 +0000 (14:28 +0200)]
Use consistent function names in thread-tests.el

* test/src/thread-tests.el (threads-call-error, threads-custom)
(threads-errors, threads-sticky-point, threads-signal-early):
Rename, using naming convention to prefix with "threads-".

6 years agoFix format error in Faccept_process_output
Michael Albinus [Fri, 13 Jul 2018 12:27:33 +0000 (14:27 +0200)]
Fix format error in Faccept_process_output

* src/process.c (Faccept_process_output): Do not use format spec
"%p", it isn't valid for error().

6 years agoLessen stack consumption in recursive read1
Paul Eggert [Fri, 13 Jul 2018 03:23:07 +0000 (20:23 -0700)]
Lessen stack consumption in recursive read1

* src/lread.c (read1): Shrink local buffer size from
MAX_ALLOCA to 128 (Bug#31995).

6 years agoMatch w32 paths in grep sans --null hits (Bug#32051)
Noam Postavsky [Mon, 9 Jul 2018 20:56:47 +0000 (16:56 -0400)]
Match w32 paths in grep sans --null hits (Bug#32051)

* lisp/progmodes/grep.el (grep-regexp-alist): Add an optional part to
match paths starting with C: (other drive letters).
* test/lisp/progmodes/compile-tests.el
(compile-tests--grep-regexp-testcases)
(compile-tests--grep-regexp-tricky-testcases)
(compile-test-grep-regexps): New tests.
(compile--test-error-line): Return `compilation-message'.

6 years agoSpeed up smerge-refine-regions by avoiding fsync
Noam Postavsky [Thu, 12 Jul 2018 00:13:25 +0000 (20:13 -0400)]
Speed up smerge-refine-regions by avoiding fsync

* lisp/vc/smerge-mode.el (smerge-refine-regions): Bind
write-region-inhibit-fsync to t.  This was reported in
https://github.com/magit/magit/pull/2834 to give a noticable speedup.

6 years agoDon't skip epg-tests even with gpg 2.0 (Bug#23561)
Noam Postavsky [Thu, 12 Jul 2018 00:01:11 +0000 (20:01 -0400)]
Don't skip epg-tests even with gpg 2.0 (Bug#23561)

* test/lisp/epg-tests.el (epg-tests--config-program-alist): New
constant, which allows gpg2 version 2.0+.
(epg-tests-find-usable-gpg-configuration): Pass it to
epg-find-configuration.

6 years agoFix previous make-network-process change
Noam Postavsky [Thu, 12 Jul 2018 23:41:03 +0000 (19:41 -0400)]
Fix previous make-network-process change

* src/process.c (Fmake_network_process): On 2018-07-09 "Explicitly
reject :server and :nowait (Bug#31903)", the sense of the SERVER check
was accidentally reversed so that we ended up looking for the wrong
ADDRESS.  Reported by T.V Raman in
<https://lists.gnu.org/archive/html/emacs-devel/2018-07/msg00437.html>.

6 years agoAnother documentation improvement in flyspell.el
Eli Zaretskii [Thu, 12 Jul 2018 16:24:06 +0000 (19:24 +0300)]
Another documentation improvement in flyspell.el

* lisp/textmodes/flyspell.el (flyspell-persistent-highlight): Doc
fix.

6 years agoImprove documentation of Flyspell
Eli Zaretskii [Thu, 12 Jul 2018 15:59:18 +0000 (18:59 +0300)]
Improve documentation of Flyspell

For the background, see
http://lists.gnu.org/archive/html/help-gnu-emacs/2018-07/msg00099.html.

* doc/emacs/fixit.texi (Spelling): Add a couple of caveats.
* lisp/textmodes/flyspell.el: Update commentary.

6 years agoFix the bootstrap differently, so zerop can be where it belongs
Stefan Monnier [Thu, 12 Jul 2018 14:29:28 +0000 (10:29 -0400)]
Fix the bootstrap differently, so zerop can be where it belongs

Suggested by Robert Pluim <rpluim@gmail.com>.

* lisp/emacs-lisp/byte-run.el (defun-declarations-alist): Avoid cadr/cddr.
* lisp/subr.el (zerop): Un-revert 2018-07-10T23:08:58-07:00!contovob@tcd.ie.

6 years agoProvide feature 'threads
Michael Albinus [Thu, 12 Jul 2018 08:49:06 +0000 (10:49 +0200)]
Provide feature 'threads

* src/thread.c (syms_of_threads): Provide feature "threads".

* test/src/thread-tests.el (top): Declare the functions.
(all): Use (featurep 'threads) check.

6 years ago; Add commentary on location of zerop
Basil L. Contovounesios [Wed, 11 Jul 2018 17:11:55 +0000 (20:11 +0300)]
; Add commentary on location of zerop

* lisp/subr.el (zerop): Add commentary explaining why moving the
function's location within the file broke bootstrap in
2018-07-10T23:08:58-07:00!contovob@tcd.ie.

6 years agoUnbreak bootstrap
Glenn Morris [Wed, 11 Jul 2018 15:27:14 +0000 (08:27 -0700)]
Unbreak bootstrap

* lisp/subr.el (zerop): Revert previous change, which caused
bootstrap to fail with void function cadr.

6 years ago; Rearrange definition of zerop in subr.el
Basil L. Contovounesios [Wed, 11 Jul 2018 06:08:58 +0000 (23:08 -0700)]
; Rearrange definition of zerop in subr.el

* lisp/subr.el (zerop): Move from under 'List functions' heading to
under 'Basic Lisp functions' heading.