Noam Postavsky [Thu, 11 May 2017 03:27:37 +0000 (23:27 -0400)]
; CONTRIBUTE: Better example for multi-entry example ChangeLog
The new example has entries spanning multiple functions in a single
file as well as multiple files.
Glenn Morris [Thu, 1 Jun 2017 01:17:28 +0000 (21:17 -0400)]
Quieten compilation of some test files
* test/lisp/dired-tests.el (dired-test-bug25609): Mark unused args.
* test/src/data-tests.el (binding-test-set-constant-t)
(binding-test-set-constant-nil, binding-test-set-constant-keyword)
(binding-test-set-constant-nil): Silence compiler.
* test/src/regex-tests.el (regex-tests-BOOST): Escape char literal.
Glenn Morris [Thu, 1 Jun 2017 01:13:40 +0000 (21:13 -0400)]
Use true names for invocation- and source-directory
* src/emacs.c (init_cmdargs) <Vinvocation_directory>:
* src/lread.c (init_lread) <Vsource_directory>: Use true names.
Glenn Morris [Thu, 1 Jun 2017 01:11:47 +0000 (21:11 -0400)]
Avoid elisp-mode test failures when source dir has multiple names
* test/lisp/progmodes/elisp-mode-tests.el (emacs-test-dir):
Use the true name of the directory.
Paul Eggert [Wed, 31 May 2017 23:50:08 +0000 (16:50 -0700)]
Fix bug with "%%" in error format
* src/doprnt.c (doprnt): Format "%%" correctly.
Problem reported by Philipp Stephani in:
http://lists.gnu.org/archive/html/emacs-devel/2017-05/msg00901.html
Paul Eggert [Wed, 31 May 2017 23:22:24 +0000 (16:22 -0700)]
* src/editfns.c (Fmessage): Improve doc string (Bug#23425#130).
Katsumi Yamaoka [Wed, 31 May 2017 23:21:27 +0000 (23:21 +0000)]
Revert mml-generate-mime-1 (bug#27141)
* lisp/gnus/mml.el (mml-generate-mime-1): Reverted to emacs-25 version
with slight modernizations (bug#27141).
Michael Albinus [Wed, 31 May 2017 18:32:31 +0000 (20:32 +0200)]
Fix Bug#27108
* lisp/recentf.el (recentf-load-list): Bind `non-essential',
in order to avoid Tramp password requests during Emacs
startup. (Bug#27108)
Glenn Morris [Wed, 31 May 2017 16:56:40 +0000 (12:56 -0400)]
* test/Makefile.in (.SECONDARY): Stop make deleting .elc files.
Eli Zaretskii [Wed, 31 May 2017 16:15:40 +0000 (19:15 +0300)]
Document current-line hscrolling in ELisp manual
* doc/lispref/windows.texi (Horizontal Scrolling): Document the
new mode of auto-hscrolling only the current line.
Eli Zaretskii [Wed, 31 May 2017 16:01:31 +0000 (19:01 +0300)]
Support lower bound on hscrolling when only current line scrolls
* doc/emacs/display.texi (Horizontal Scrolling): Document the new
mode of auto-hscrolling only the current line.
* src/xdisp.c (init_iterator): When hscrolling only the
current line, apply the window's min_hscroll here, so that
non-current lines will be hscrolled by that minimum.
Suggested by Stephen Berman <stephen.berman@gmx.net>.
(hscroll_window_tree): Account for window's min_hscroll when
deciding whether to recompute the hscroll.
(display_line): Subtract window's min_hscroll from x_incr, as that
was already accounted for in init_iterator. (Bug#27008)
Noam Postavsky [Sun, 28 May 2017 21:01:05 +0000 (17:01 -0400)]
cl-print: handle circular objects when `print-circle' is nil (Bug#27117)
* lisp/emacs-lisp/cl-print.el (cl-print--currently-printing): New variable.
(cl-print-object): When `print-circle' is nil, bind it to a list of
objects that are currently printing to avoid printing the same object
endlessly.
* test/lisp/emacs-lisp/cl-print-tests.el (cl-print-circle): New test.
Noam Postavsky [Wed, 31 May 2017 03:31:18 +0000 (23:31 -0400)]
Further simplify test/Makefile, optionally load elc tests
* test/Makefile.in: Use make's error ignoring feature instead of
suppressing test errors with shell. Compile test files in the main
make invocation instead of a recursive 'make' call. Optionally load
.elc test files if TEST_LOAD_EL is set to something other than 'yes'.
Remove obsolete commentary.
Eli Zaretskii [Wed, 31 May 2017 09:05:06 +0000 (12:05 +0300)]
Avoid inflooping in redisplay due to Spacemacs and linum-mode
* src/xdisp.c (redisplay_internal): Limit the number of redisplay
retries when a frame becomes garbaged as result of redisplaying
it. (Bug#27115)
Tino Calancha [Wed, 31 May 2017 01:15:20 +0000 (10:15 +0900)]
* src/editfns.c (decode-time): Fix docstring.
Glenn Morris [Wed, 31 May 2017 01:03:16 +0000 (21:03 -0400)]
* admin/update_autogen: Remove bzr support.
Glenn Morris [Wed, 31 May 2017 01:01:56 +0000 (21:01 -0400)]
Avoid subr test failure when source dir has multiple names
* test/lisp/subr-tests.el (subr-tests--this-file):
Use the true name of the file. The following test does a string
comparison of this value with that from method-files, which uses
load-history, which contains true names.
Dmitry Gutov [Tue, 30 May 2017 22:29:34 +0000 (01:29 +0300)]
Extract eldoc--supported-p
* lisp/emacs-lisp/eldoc.el (eldoc--supported-p): New function.
(turn-on-eldoc-mode, eldoc-mode): Use it.
(http://lists.gnu.org/archive/html/emacs-devel/2017-05/msg00865.html)
Glenn Morris [Tue, 30 May 2017 18:16:35 +0000 (14:16 -0400)]
Make "make check" less verbose by default
* test/Makefile.in (AM_DEFAULT_VERBOSITY, AM_V_ELC, am__v_ELC_)
(am__v_ELC_0, am__v_ELC_1, AM_V_GEN, am__v_GEN_, am__v_GEN_0)
(am__v_GEN_1, AM_V_at, am__v_at_, am__v_at_0, am__v_at_1):
New, copied from lisp/Makefile.in.
(%.elc, %.log): Simplify and quieten.
Alan Mackenzie [Tue, 30 May 2017 17:42:52 +0000 (17:42 +0000)]
Mode line "%q" construct: Just use one number when both would be the same.
* src/xdisp (decode_mode_spec): recode the "%q" bit appropriately.
Alan Mackenzie [Tue, 30 May 2017 17:39:40 +0000 (17:39 +0000)]
Merge branch 'master' of /home/acm/emacs/emacs.git/master
Alan Mackenzie [Tue, 30 May 2017 17:07:12 +0000 (17:07 +0000)]
c-defun-name: Return fully qualified method names when wanted in C++, etc.
* lisp/progmodes/cc-cmds.el (c-defun-name): Use
c-back-over-compound-identifier in place of c-backward-token-2 near the end
of the function.
Glenn Morris [Tue, 30 May 2017 16:50:54 +0000 (12:50 -0400)]
Reduce scope of recent test/Makefile HOME change
* test/Makefile.in (%.log): Move setting of HOME here from top-level.
Paul Eggert [Tue, 30 May 2017 16:27:33 +0000 (09:27 -0700)]
Skip .#* temporaries when finding sources
Without this patch, ‘make check’ can fail with the diagnostic
‘invalid syntax in conditional’ if there is an Emacs temporary
file whose name starts with ‘.#’, because the ‘#’ is treated as
the start of a Make comment.
* lisp/Makefile.in (loaddefs, tagsfiles, check-defun-deps):
* test/Makefile.in (ELFILES):
Skip files starting with ‘.’, so that the .#* files do not cause
trouble. (We cannot easily skip just files starting with ‘.#’,
since ‘#’ starts a Make comment!)
Alan Mackenzie [Tue, 30 May 2017 16:27:36 +0000 (16:27 +0000)]
Merge branch 'master' of /home/acm/emacs/emacs.git/master
Alan Mackenzie [Tue, 30 May 2017 16:21:31 +0000 (16:21 +0000)]
Fix the mouse help/key map on the "%p" part of the mode line.
* lisp/bindings.el (mode-line-percent-position): give it a
`risky-local-variable' property.
(mode-line-position): correct the quoting on the mode-line-percent-position
part of the variable, allowing the properties to be properly recognized.
Alan Mackenzie [Tue, 30 May 2017 16:21:31 +0000 (16:21 +0000)]
Fix the mouse help/key map on the "%p" part of the mode line.
* lisp/bindings.el (mode-line-percent-position): give it a
`risky-local-variable' property.
(mode-line-position): correct the quoting on the mode-line-percent-position
part of the variable, allowing the properties to be properly recognized.
Paul Eggert [Tue, 30 May 2017 16:15:05 +0000 (09:15 -0700)]
Merge from gnulib
* build-aux/config.guess: Copy from gnulib.
* lib/gnulib.mk.in: Regenerate.
Glenn Morris [Tue, 30 May 2017 15:39:39 +0000 (08:39 -0700)]
Stop make check interacting with HOME
* test/Makefile.in (HOME): Export a non-existent value.
Paul Eggert [Tue, 30 May 2017 15:28:54 +0000 (08:28 -0700)]
; Spelling fixes for "SpamAssassin"
Paul Eggert [Tue, 30 May 2017 15:22:27 +0000 (08:22 -0700)]
Update .gitattributes to match sources better
* .gitattributes: Remove nt/nmake.defs. Move dostorture.c, c.C,
algrthms.html. Use pattern for todo-mode. Improve patterns for
Ada, C, ObjC, shell. Add Pascal. Remove unused pattern *.ruby.
Add config.guess and config.sub as shell files.
Noam Postavsky [Tue, 30 May 2017 02:13:53 +0000 (22:13 -0400)]
Rename '--new-daemon' to 'fg-daemon' and '--old-daemon' to '--bg-daemon'
* doc/emacs/cmdargs.texi (Initial Options):
* doc/lispref/os.texi (Startup Summary):
* etc/NEWS:
* etc/emacs.service:
* src/emacs.c (main):
* src/lisp.h: Rename '--new-daemon' to 'fg-daemon' and '--old-daemon' to
'--bg-daemon'.
Glenn Morris [Tue, 30 May 2017 00:50:36 +0000 (17:50 -0700)]
todo-mode: don't assume an ordering of tests
* test/lisp/calendar/todo-mode-tests.el (todo-test-todo-quit02)
(todo-test-item-highlighting): Avoid prompting for input file.
Paul Eggert [Tue, 30 May 2017 00:15:11 +0000 (17:15 -0700)]
Improve .gdbinit Lisp value pretty-printing
* src/.gdbinit (to_string): Use an unsigned representation for
Lisp values, as requested by Eli Zaretskii (Bug#27098).
Also, use "make_number(N)" for Lisp integers.
Dmitry Gutov [Mon, 29 May 2017 23:55:28 +0000 (02:55 +0300)]
Turn global-eldoc-mode into a globalized minor mode
* lisp/emacs-lisp/eldoc.el (global-eldoc-mode):
Turn into globalized mode (bug#19853).
(turn-on-eldoc-mode): Make it into a wrapper instead of alias.
(eldoc-mode): Only show the message when called interactively.
Dmitry Gutov [Mon, 29 May 2017 21:58:39 +0000 (00:58 +0300)]
Use regexp matching instead of checking exit status
* lisp/progmodes/xref.el (xref-collect-matches):
See if the output buffer contents look like Grep output
instead of checking exit status (bug#23451).
Stephen Berman [Mon, 29 May 2017 21:49:41 +0000 (23:49 +0200)]
Add initial tests for todo-mode.el
*test/lisp/calendar/todo-mode-tests.el:
*test/lisp/calendar/todo-mode-resources/todo-test-1.toda:
*test/lisp/calendar/todo-mode-resources/todo-test-1.todo: New files.
* .gitattributes: Ignore trailing whitespace in todo-mode test
data files, since it is part of the todo-mode file format.
Stephen Berman [Mon, 29 May 2017 18:26:49 +0000 (20:26 +0200)]
Make `todo-toggle-item-highlighting' work on multiline items (bug#27133)
* lisp/calendar/todo-mode.el (todo-hl-line-range): New named function,
replacing an anonymous function for the sake of `describe-variable'.
(todo-modes-set-2): Use it as buffer-local value of hl-line-range-function
and remove boundp test of this variable, so its value is available on
invoking `todo-toggle-item-highlighting'.
Alan Third [Mon, 29 May 2017 16:01:44 +0000 (17:01 +0100)]
Fix build error on macOS 10.6
* src/nsfns.m (compute_tip_xy): Cast NSRect to CGRect and NSPoint to
CGPoint.
Noam Postavsky [Mon, 22 May 2017 16:36:20 +0000 (12:36 -0400)]
; Fix backslashes in python-tests
* test/lisp/progmodes/python-tests.el (python-indent-after-backslash-1)
(python-indent-after-backslash-2)
(python-indent-after-backslash-3)
(python-indent-after-backslash-4)
(python-indent-after-backslash-5)
(python-nav-beginning-of-statement-1)
(python-nav-end-of-statement-1)
(python-nav-forward-statement-1)
(python-nav-backward-statement-1)
(python-nav-backward-statement-2)
(python-info-statement-starts-block-p-2)
(python-info-statement-ends-block-p-2)
(python-info-beginning-of-statement-p-2)
(python-info-end-of-statement-p-2)
(python-info-beginning-of-block-p-2)
(python-info-end-of-block-p-2)
(python-info-line-ends-backslash-p-1)
(python-info-beginning-of-backslash-1)
(python-info-continuation-line-p-1)
(python-info-block-continuation-line-p-1)
(python-info-assignment-statement-p-1)
(python-info-assignment-continuation-line-p-1): Backslashes in
literals should be doubled only once to produce one backslash in the
buffer. If there backslashes inside a Python string literal in a Lisp
literal, that would need to be doubled twice, but there are no such
cases. Note that `python-tests-looking-at' takes a plain string, not
a regexp.
Noam Postavsky [Mon, 22 May 2017 16:32:04 +0000 (12:32 -0400)]
; Update test for previous change
* test/lisp/progmodes/python-tests.el
(python-indent-after-backslash-4): Indent after backslash is now
python-indent-offset.
Jules Tamagnan [Thu, 27 Oct 2016 22:03:31 +0000 (15:03 -0700)]
Comply with pep 8 style guide for backslash in assignment (Bug#24809)
* lisp/progmodes/python.el (python-indent--calculate-indentation):
Increase indent by `python-indent-offset' after
`:after-backslash-assignment-continuation'.
Copyright-paperwork-exempt: yes
Wilfred Hughes [Mon, 29 May 2017 00:04:41 +0000 (01:04 +0100)]
Add suggestion to docstring
* lisp/subr.el (interactive-p): Mention commandp, as this is often
what users are actually looking for.
Wilfred Hughes [Mon, 29 May 2017 00:00:05 +0000 (01:00 +0100)]
Ensure button-get works in any buffer
* lisp/button.el (button-get): Previously we assumed that button-get
was called in the buffer containing the button. In other buffers,
button-get always returned nil. Fix this by passing the relevant
buffer from the marker.
Dmitry Gutov [Sun, 28 May 2017 23:55:42 +0000 (02:55 +0300)]
Signal error if find-grep returns a nonzero status
* lisp/progmodes/xref.el (xref-collect-matches): Signal error
if find-grep returns a nonzero status (bug#23451). Remove the
comment: even if some output is present, a non-zero status
means something went wrong and it can't be relied upon.
Stephen Berman [Sun, 28 May 2017 20:52:05 +0000 (22:52 +0200)]
Make sure exiting todo-mode buffer buries it (bug#27121)
This failed due to commit
ea3ae33b from 2013-05-16, which prevented
quitting todo-mode buffer after visiting todo-archive buffer from
making the archive buffer current again. Avoid this now by simply
killing the archive buffer, since there's no need to keep it a live
buffer. Consequently, quitting a todo-mode buffer can now use
bury-buffer without an argument, which ensures that is will not
becomes current on quitting the buffer that replaced it in the window.
* lisp/calendar/todo-mode.el (todo-quit): Kill todo-archive-mode
buffer instead of burying it. This now allows exiting the
todo-mode buffer by bury-buffer without an argument, so do that.
Michael Albinus [Sun, 28 May 2017 21:44:10 +0000 (23:44 +0200)]
Some tweaks, almost all for Tramp adb method
* lisp/net/tramp-adb.el (tramp-adb-parse-device-names):
Use `make-tramp-file-name'.
(tramp-adb-get-device): Use `tramp-file-name-port-or-default'.
(tramp-adb-maybe-open-connection): Set "prompt" property.
(tramp-adb-wait-for-output): Use it.
* lisp/net/tramp-cache.el (tramp-cache-print): Use `elt'.
(tramp-dump-connection-properties): Check also that there are
properties to be saved. Don't save "started" property of
"ftp" method.
* lisp/net/tramp-gvfs.el (tramp-gvfs-handle-expand-file-name):
Use `make-tramp-file-name'.
* lisp/net/tramp.el (tramp-remote-file-name-spec-regexp):
Host could be empty.
(tramp-file-name-port-or-default): New defun.
(tramp-dissect-file-name): Simplify `make-tramp-file-name' call.
(tramp-handle-file-name-case-insensitive-p): Use a progress reporter.
(tramp-call-process, tramp-call-process-region):
Use `make-tramp-file-name'.
* test/lisp/net/tramp-tests.el (tramp-test03-file-name-defaults):
Revert change from 2017-05-24.
(tramp-test05-expand-file-name-relative): Let it also pass for
"adb" method.
Jürgen Hötzel [Sun, 28 May 2017 11:06:53 +0000 (13:06 +0200)]
Fix Tramp for Android 7
* tramp-adb.el (tramp-adb-ls-toolbox-regexp):
Username part of prompt is empty on Android 7.
(tramp-adb-ls-toolbox-regexp):
Ignore addition links column on Android 7.
(tramp-adb-get-ls-command):
Dont use --color=none when using toybox (Android 7). It's not
possible to disable coloring explicitly for toybox ls.
Svante Carl v. Erichsen [Sun, 6 Oct 2013 18:33:24 +0000 (20:33 +0200)]
Fix cl-indent for `loop' with :keywords (Bug#15543)
* lisp/emacs-lisp/cl-indent.el (lisp-extended-loop-p): Allow for
":keywords".
Copyright-paperwork-exempt: yes
Paul Eggert [Sat, 27 May 2017 17:54:25 +0000 (10:54 -0700)]
Depromiscuify inotify with IN_MASK_ADD
Use IN_MASK_ADD instead of using a no-longer-promiscuous-enough
mask. This simplifies the code and restores the ability to
use IN_ACCESS, IN_CLOSE_WRITE, IN_CLOSE_NOWRITE, and IN_OPEN
in some cases (Bug#26973).
* src/inotify.c (INOTIFY_DEFAULT_MASK): Remove.
(Finotify_add_watch): Use IN_MASK_ADD instead.
Paul Eggert [Sat, 27 May 2017 17:54:25 +0000 (10:54 -0700)]
Restore inotify onlydir support
There was no need to remove it in the 2017-03-26 inotify change,
as it is like IN_DONT_FOLLOW and does not affect other watchers
for the same file.
* src/inotify.c (symbol_to_inotifymask, Finotify_add_watch)
(syms_of_inotify): Bring back onlydir.
Paul Eggert [Sat, 27 May 2017 17:54:25 +0000 (10:54 -0700)]
Simplify computation of inotify mask
* src/inotify.c (add_watch): Accept uint32_t imask instead
of Lisp_Object aspect. Caller changed.
(Finotify_add_watch): Use aspect_to_inotifymask earlier, to
simplify the code.
Philipp Stephani [Sat, 27 May 2017 12:39:01 +0000 (14:39 +0200)]
Don't attempt to recover from undefined behavior in some cases
These functions can only be run in batch mode and exit Emacs on
return, so nothing can be recovered. Disable unsafe recover
mechanisms so that we get real failures and good stack traces on
fatal signals.
* lisp/emacs-lisp/bytecomp.el (batch-byte-compile)
(batch-byte-recompile-directory):
* lisp/emacs-lisp/ert.el (ert-run-tests-batch-and-exit)
(ert-summarize-tests-batch-and-exit): Don't attempt to recover
from undefined behavior.
Philipp Stephani [Sat, 27 May 2017 13:26:49 +0000 (15:26 +0200)]
Avoid another compiler warning on macOS
When configured with --without-ns, HAVE_NS is not defined on macOS,
thus 'memory-limit' calls the deprecated sbrk(2) function. Avoid that
by using the pre-defined __APPLE__ preprocessor macro.
* src/alloc.c (Fmemory_limit): Never use sbrk(2) on macOS.
Luke Yen-Xun Lee [Sat, 27 May 2017 13:25:02 +0000 (16:25 +0300)]
Fix ruler-mode text-scaling issues
* lisp/ruler-mode.el (ruler-mode-text-scaled-width): New function
for computing scaled text width.
(ruler-mode-text-scaled-window-hscroll)
(ruler-mode-text-scaled-window-width): Compute text scaled
`window-width' value.
(ruler-mode-mouse-grab-any-column, ruler-mode-mouse-add-tab-stop)
(ruler-mode-ruler): Change `window-hscroll' into
`ruler-mode-text-scaled-window-hscroll', and change `window-width'
into `ruler-mode-text-scaled-window-width'.
Martin Rudalics [Sat, 27 May 2017 13:14:52 +0000 (15:14 +0200)]
Minor doc and doc-string fixes (Bug#27091)
* src/window.c (Fset_window_scroll_bars): Fix doc-string.
* doc/lispref/display.texi (Fringe Size/Pos, Scroll Bars)
(Display Margins): Mention that `set-window-buffer' may override
settings made by `set-window-fringes', `set-window-scroll-bars'
and `set-window-margins'.
* doc/lispref/windows.texi (Buffers and Windows): Fix doc of
`set-window-buffer'.
Eli Zaretskii [Sat, 27 May 2017 12:57:38 +0000 (15:57 +0300)]
Avoid args-out-of-range errors on fringe clicks after "C-h k"
* src/keyboard.c (echo_truncate): Don't call Ftruncate if the echo
message is already shorter than NCHARS. (Bug#27040)
Eli Zaretskii [Sat, 27 May 2017 12:15:18 +0000 (15:15 +0300)]
Fix GUD "Stop" display when running pdb
* lisp/progmodes/gud.el (gud-menu-map): Don't call gdb-show-stop-p
when GUD mode is 'pdb'. (Bug#27024)
Tak Kunihiro [Sat, 27 May 2017 11:57:11 +0000 (14:57 +0300)]
Support drag and drop of region by mouse (Bug#26725)
* doc/emacs/frames.texi (Drag and Drop): Document support of drag
and drop region by mouse.
* lisp/mouse.el (mouse-drag-region): Call mouse-drag-and-drop-region
when start-event is on region.
(mouse-drag-and-drop-region): New function, moves the region by
(mouse-drag-and-drop-region): New defcustom.
* etc/NEWS: Mention mouse-drag-and-drop-region.
Noam Postavsky [Sat, 27 May 2017 03:26:27 +0000 (23:26 -0400)]
* lisp/emacs-lisp/eieio.el (defclass): Fix quote in warning message.
Alan Third [Thu, 25 May 2017 18:23:39 +0000 (19:23 +0100)]
Check if instancetype supported in ObjC
* configure.ac: Add check for instancetype.
* src/nsterm.h [!NATIVE_OBJC_INSTANCETYPE]: Define instancetype.
Wilfred Hughes [Fri, 26 May 2017 21:45:58 +0000 (22:45 +0100)]
Mark keywordp as a safe, error-free function
* lisp/emacs-lisp/byte-opt.el: Add keywordp to
side-effect-and-error-free-fns.
Paul Eggert [Fri, 26 May 2017 16:07:50 +0000 (09:07 -0700)]
* src/inotify.c: Add FIXME comments.
Andreas Politz [Fri, 26 May 2017 14:42:43 +0000 (16:42 +0200)]
Fix Bug#26973
* src/inotify.c (INOTIFY_DEFAULT_MASK): Removing ACCESS, OPEN
and CLOSE events on order do let other processes also reading
from their descriptors. (Bug#26973).
Michael Albinus [Fri, 26 May 2017 14:25:18 +0000 (16:25 +0200)]
Remove Emacs 23 compat code from Tramp
* doc/misc/tramp.texi (Remote processes): Don't mention
Emacs 24 explicitely.
(Frequently Asked Questions): Remove Emacs 23 from
compatibility list.
* lisp/net/tramp.el:
* lisp/net/tramp-adb.el:
* lisp/net/tramp-cache.el:
* lisp/net/tramp-gvfs.el:
* lisp/net/tramp-sh.el:
* lisp/net/tramp-smb.el: Replace compat function calls.
* lisp/net/tramp-compat.el (remote-file-name-inhibit-cache)
(tramp-compat-condition-case-unless-debug)
(tramp-compat-copy-file, tramp-compat-copy-directory)
(tramp-compat-delete-file, tramp-compat-delete-directory)
(tramp-compat-process-live-p): Remove them.
* lisp/net/trampver.el: Make version check fit for Emacs 24.
Katsumi Yamaoka [Fri, 26 May 2017 08:07:58 +0000 (08:07 +0000)]
Work for application/x-tar-gz and image/svg+xml
;; Try inlining the attachment in the article <87wp94dzj6.fsf@gmail.com>
;; of bug#27078 in the Emacs bug list using Gnus.
* lisp/gnus/mm-archive.el (mm-archive-decoders):
Add a decoder for application/x-tar-gz.
(mm-dissect-archive): Error out if a decoder is not found.
* lisp/gnus/mm-decode.el (mm-get-image): Allow image/svg+xml.
Tino Calancha [Fri, 26 May 2017 01:59:19 +0000 (10:59 +0900)]
test-calc-23889: Skip test on 32-bit platforms
This test fails on some 32-bit platforms as mentioned in
https://lists.gnu.org/archive/html/emacs-devel/2017-05/msg00737.html
* test/lisp/calc/calc-tests.el (test-calc-23889): Skip when
the Lisp integer is not big enough.
Alan Third [Thu, 25 May 2017 19:13:21 +0000 (20:13 +0100)]
Fix NS tooltips showing in the wrong place (bug#27053)
* src/nsfns.m (compute_tip_xy): Get current mouse position instead of
last recorded position.
Thomas Fitzsimmons [Wed, 24 May 2017 18:34:13 +0000 (14:34 -0400)]
lisp/net/soap-client.el: Bump version to 3.1.2
* lisp/net/soap-client.el: Bump version to 3.1.2.
Thomas Fitzsimmons [Wed, 24 May 2017 19:01:01 +0000 (15:01 -0400)]
Fix soap-inspect.el doc strings
* lisp/net/soap-inspect.el (soap-inspect-xs-attribute): Fix doc
string.
(soap-inspect-xs-attribute-group): Likewise.
Thomas Fitzsimmons [Wed, 24 May 2017 18:58:47 +0000 (14:58 -0400)]
Fix two soap-client.el byte compilation warnings
* lisp/net/soap-client.el (url-http-response-status): Add defvar.
(soap-fetch-xml-from-url): Remove special declaration of
url-http-response-status.
(soap-invoke-internal): Likewise.
Thomas Fitzsimmons [Wed, 24 May 2017 18:32:00 +0000 (14:32 -0400)]
lisp/net/soap-client.el: Require cl-lib version 0.6.1
* lisp/net/soap-client.el: Require cl-lib version 0.6.1.
Thomas Fitzsimmons [Wed, 24 May 2017 18:28:32 +0000 (14:28 -0400)]
lisp/net/soap-client.el: Shorten some long lines
* lisp/net/soap-client.el (soap-encode-xs-element): Remove
unnecessary progn.
(soap-xs-add-union): Wrap long line.
Co-authored-by: Stefan Monnier <monnier@iro.umontreal.ca>
Alex Harsanyi [Wed, 24 May 2017 18:18:39 +0000 (14:18 -0400)]
Remove cl dependency in soap-client.el and soap-inspect.el
* lisp/net/soap-inspect.el: Replace cl library with cl-lib, case
with cl-case, destructuring-bind with cl-destructuring-bind and
loop with cl-loop.
* lisp/net/soap-client.el: Replace cl library with cl-lib,
defstruct with cl-defstruct, assert with cl-assert, case with
cl-case, ecase with cl-ecase, loop with cl-loop and
destructuring-bind with cl-destructuring-bind.
Co-authored-by: Stefan Monnier <monnier@iro.umontreal.ca>
Michael Albinus [Thu, 25 May 2017 08:04:12 +0000 (10:04 +0200)]
Switch Tramp to cl-lib
* lisp/net/tramp-compat.el (cl-lib): Require it rather than cl.
* lisp/net/tramp-ftp.el: Don't require cl.
* lisp/net/tramp-gvfs.el: Don't require cl.
(tramp-gvfs-handler-mounted-unmounted)
(tramp-gvfs-connection-mounted-p): Use `cl-*' macros.
* lisp/net/tramp-sh.el: Don't require cl.
(tramp-set-file-uid-gid): Use `shell-quote-argument'.
(tramp-sh-gvfs-monitor-dir-process-filter)
(tramp-sh-inotifywait-process-filter): Use `cl-*' macros.
* lisp/net/tramp-smb.el: Don't require cl.
(tramp-smb-read-file-entry): Use `cl-*' macros.
* lisp/net/tramp.el (cl-lib): Require it rather than cl.
(tramp-parse-file, tramp-parse-shostkeys-sknownhosts)
(tramp-parse-passwd, tramp-parse-etc-group)
(tramp-parse-putty): Use `cl-*' macros.
Paul Eggert [Thu, 25 May 2017 07:43:13 +0000 (00:43 -0700)]
* CONTRIBUTE: Suggest autogen.sh's 'all' operand.
Paul Eggert [Thu, 25 May 2017 07:24:51 +0000 (00:24 -0700)]
Port ATTRIBUTE_MAY_ALIAS to recent icc
* src/conf_post.h (ATTRIBUTE_MAY_ALIAS) [__ICC]:
Define to empty. Otherwise, icc (ICC) 17.0.4
20170411 says
“warning #2621: attribute "__may_alias__" does not apply here”
for constructs like ‘struct sockaddr *sa = (whatever);
struct sockaddr_in __attribute__ ((__may_alias__)) *sin
= (struct sockaddr_in *) sa;’.
Paul Eggert [Thu, 25 May 2017 07:13:14 +0000 (00:13 -0700)]
Merge from gnulib
This incorporates:
2017-05-25 port to recent icc
* lib/intprops.h: Copy from gnulib.
Michael Albinus [Wed, 24 May 2017 20:26:20 +0000 (22:26 +0200)]
Fix Tramp for python.el
* lisp/net/tramp.el (tramp-get-connection-process): Check,
that VEC is a `tramp-file-name' structure.
Alan Third [Wed, 24 May 2017 19:18:52 +0000 (20:18 +0100)]
Raise version of macOS we define instancetype for (bug#27059)
* src/nsterm.m: Increase supported version number.
Alan Third [Wed, 24 May 2017 18:40:19 +0000 (19:40 +0100)]
Define new types on macOS 10.6 (bug#27041)
* src/nsterm.h: Enable instancetype typedef for older macOS, and use
correct NSUInteger instead of int.
Glenn Morris [Wed, 24 May 2017 17:11:32 +0000 (13:11 -0400)]
Don't autoload new dns-mode command
* lisp/textmodes/dns-mode.el (dns-mode-ipv6-to-nibbles):
Remove autoload cookie.
Stefan Monnier [Wed, 24 May 2017 15:55:13 +0000 (11:55 -0400)]
* src/fns.c (sxhash): Fix records hashing (bug#27057, bug#26639)
(sxhash_vector): Make it work on pseudo vectors as well.
(sxhash): Treat records like vectors.
Michael Albinus [Wed, 24 May 2017 14:17:59 +0000 (16:17 +0200)]
Adapt tramp-tests.el according to new defstruct
* test/lisp/net/tramp-tests.el (tramp-test03-file-name-defaults):
Fix test according to new defstruct.
(tramp-test29-environment-variables-and-port-numbers):
Expect it now as passed. Cleanup at the end.
Michael Albinus [Wed, 24 May 2017 14:16:53 +0000 (16:16 +0200)]
Introduce a defstruct `tramp-file-name' as central data structure.
This solves also Bug#27009.
* lisp/net/tramp.el (tramp-current-domain)
(tramp-current-port): New defvars.
(tramp-file-name): New defstruct.
(tramp-file-name-user-domain, tramp-file-name-host-port)
(tramp-file-name-equal-p): New defuns.
(tramp-file-name-p, tramp-file-name-method)
(tramp-file-name-user, tramp-file-name-host)
(tramp-file-name-localname, tramp-file-name-hop)
(tramp-file-name-real-user, tramp-file-name-domain)
(tramp-file-name-real-host, tramp-file-name-port):
Remove defuns. They are provided by the defstruct, or not
needed anymore.
(tramp-dissect-file-name, tramp-buffer-name)
(tramp-make-tramp-file-name, tramp-get-buffer)
(tramp-set-connection-local-variables)
(tramp-debug-buffer-name, tramp-message)
(tramp-error-with-buffer, with-parsed-tramp-file-name)
(tramp-completion-dissect-file-name1)
(tramp-handle-file-name-as-directory)
(tramp-handle-file-name-directory)
(tramp-handle-file-remote-p, tramp-handle-file-symlink-p)
(tramp-handle-find-backup-file-name)
(tramp-handle-insert-file-contents, tramp-process-actions)
(tramp-check-cached-permissions, tramp-local-host-p)
(tramp-get-remote-tmpdir, tramp-call-process)
(tramp-call-process-region, tramp-read-passwd)
(tramp-clear-passwd):
* lisp/net/tramp-adb.el (tramp-adb-parse-device-names)
(tramp-adb-handle-expand-file-name)
(tramp-adb-handle-file-truename, tramp-adb-handle-copy-file)
(tramp-adb-handle-process-file)
(tramp-adb-maybe-open-connection):
* lisp/net/tramp-cache.el (tramp-get-hash-table)
(tramp-get-file-property, tramp-set-file-property)
(tramp-flush-file-property, tramp-flush-directory-property)
(tramp-get-connection-property)
(tramp-set-connection-property, tramp-connection-property-p)
(tramp-flush-connection-property, tramp-cache-print)
(tramp-list-connections, tramp-dump-connection-properties)
(tramp-parse-connection-properties):
* lisp/net/tramp-cmds.el (tramp-cleanup-connection):
* lisp/net/tramp-ftp.el (tramp-ftp-file-name-handler):
* lisp/net/tramp-gvfs.el (tramp-gvfs-handle-expand-file-name)
(tramp-gvfs-url-file-name, tramp-gvfs-handler-askpassword)
(tramp-gvfs-handler-mounted-unmounted)
(tramp-gvfs-mount-spec, tramp-gvfs-get-remote-uid)
(tramp-gvfs-get-remote-gid)
(tramp-gvfs-maybe-open-connection):
* lisp/net/tramp-sh.el (tramp-sh-handle-file-truename)
(tramp-do-copy-or-rename-file-out-of-band)
(tramp-sh-handle-expand-file-name)
(tramp-sh-handle-start-file-process)
(tramp-sh-handle-process-file, tramp-compute-multi-hops)
(tramp-maybe-open-connection)
(tramp-make-copy-program-file-name, tramp-get-remote-path)
(tramp-get-inline-coding):
* lisp/net/tramp-smb.el (tramp-smb-handle-copy-directory)
(tramp-smb-handle-expand-file-name)
(tramp-smb-handle-file-acl, tramp-smb-handle-process-file)
(tramp-smb-handle-set-file-acl)
(tramp-smb-maybe-open-connection): Adapt according to defstruct.
Stephen Berman [Wed, 24 May 2017 11:33:27 +0000 (13:33 +0200)]
Fix and improve UI of scroll bar menu (bug#27047)
In addition, since the Emacs manual writes "scroll bar", "tool
bar" and "menu bar", use this convention in the Show/Hide menues
and tooltips as well.
* lisp/menu-bar.el (menu-bar-showhide-scroll-bar-menu): Make
pressing a radio button in the menu actually show that it was
pressed. Replace the two radio buttons to turn the horizontal
scroll bar on and off with a single check-box toggle and add a
separator between this and the vertical scroll bar radio
buttons. Use conventional spelling.
(menu-bar-horizontal-scroll-bar)
(menu-bar-no-horizontal-scroll-bar): Remove, since now unused.
(menu-bar-showhide-tool-bar-menu, menu-bar-showhide-menu)
(menu-bar-mode): Use conventional spelling.
Katsumi Yamaoka [Wed, 24 May 2017 08:18:52 +0000 (08:18 +0000)]
Remove string-as-unibyte
* lisp/gnus/canlock.el (canlock-sha1): Remove useless variable.
(canlock-make-cancel-key): No need to use string-as-unibyte.
Tino Calancha [Wed, 24 May 2017 01:54:48 +0000 (10:54 +0900)]
Fix concatenation of "^" with diff-file-junk-re
This regexp contains "\\|", thus a concatenation
of "^" with it just matches the beginning of line for the
first alternative in diff-file-junk-re.
* lisp/vc/ediff-ptch.el (ediff-map-patch-buffer): Concat "^" with
diff-file-junk-re wrapped in a shy group.
Glenn Morris [Wed, 24 May 2017 00:44:52 +0000 (20:44 -0400)]
Suppress intermittent test failure on hydra
* test/lisp/emacs-lisp/eieio-tests/eieio-tests.el
(eieio-test-37-obsolete-name-in-constructor): Skip on hydra.
Glenn Morris [Wed, 24 May 2017 00:42:28 +0000 (20:42 -0400)]
; Move recent test file to correct directory (my mistake)
Peder O. Klingenberg [Wed, 24 May 2017 00:34:08 +0000 (20:34 -0400)]
New dns-mode command for IPv6 address conversion
This converts IPv6 addresses to a format suitable for
reverse lookup zone files. (Bug#26820)
* lisp/textmodes/dns-mode.el (dns-mode-map, dns-mode-menu):
Add dns-mode-ipv6-to-nibbles.
(dns-mode-ipv6-to-nibbles, dns-mode-reverse-and-expand-ipv6):
New functions.
* test/lisp/dns-mode-tests.el: New file.
; * etc/NEWS: Mention this.
Noam Postavsky [Tue, 25 Apr 2017 12:39:17 +0000 (08:39 -0400)]
Protect *Backtrace* from being killed (Bug#26650)
* lisp/emacs-lisp/debug.el (debugger-mode): Call `top-level' in
`kill-buffer-hook'.
Noam Postavsky [Fri, 21 Apr 2017 04:00:26 +0000 (00:00 -0400)]
Give a name to lisp-mode's adaptive-fill-function (Bug#22730)
* lisp/emacs-lisp/lisp-mode.el (lisp-adaptive-fill): New function.
(lisp-mode-variables): Use it.
Philipp Stephani [Tue, 23 May 2017 19:23:55 +0000 (21:23 +0200)]
vc-hg.el: Silence byte compiler warning
* lisp/vc/vc-hg.el (compilation-arguments): Forward-declare.
Paul Eggert [Tue, 23 May 2017 19:18:35 +0000 (21:18 +0200)]
Don't warn about missing brances on macOS
On macOS, removing -Wmissing-braces is not enough; the warning has to
be disabled explicitly.
Wilfred Hughes [Tue, 23 May 2017 17:48:19 +0000 (18:48 +0100)]
Don't treat ' as a string delimiter in RPM spec files
' is commonly used as an apostrophe in the prose sections of spec
files, which was erroneously highlighted as strings. See for example
http://kmymoney2.sourceforge.net/phb/rpm-example.html
* lisp/progmodes/sh-script.el (sh-mode-syntax-table): Treat ' as
punctuation in RPM spec files.
Stefan Monnier [Tue, 23 May 2017 13:23:54 +0000 (09:23 -0400)]
* lisp/emacs-lisp/cl-indent.el: Don't require CL. Use lexical-binding.
(common-lisp-indent-function-1): Remove unused var `last-point`.
(lisp-indent-error-function): Move defvar before first use.
Stefan Monnier [Tue, 23 May 2017 13:18:26 +0000 (09:18 -0400)]
* lisp/international/rfc1843.el: Don't require CL. Use lexical-binding.
Stefan Monnier [Tue, 23 May 2017 13:12:06 +0000 (09:12 -0400)]
* lisp/international/utf7.el: Don't require CL. Use lexical-binding.
Stefan Monnier [Tue, 23 May 2017 13:09:28 +0000 (09:09 -0400)]
* lisp/net/shr.el: Use cl-lib instead of cl.