]> git.eshelyaron.com Git - emacs.git/log
emacs.git
7 years agoDired: Handle posix wildcards in directory part
Tino Calancha [Sun, 30 Jul 2017 02:02:49 +0000 (11:02 +0900)]
Dired: Handle posix wildcards in directory part

Allow Dired to handle calls like
\(dired \"~/foo/*/*.el\"), that is, with wildcards within
the directory part of the file argument (Bug#27631).
* lisp/files.el (insert-directory-wildcard-in-dir-p): New predicate.
(insert-directory-clean): New defun extracted from insert-directory.
(insert-directory)
* lisp/dired.el (dired-internal-noselect)
(dired-insert-directory): Use the new predicate; when it's true,
handle the directory wildcards with a shell call.
* lisp/eshell/em-ls.el (eshell-ls-use-in-dired): Add/remove both advices.
(eshell-ls-unload-hook): New defun.  Use it in
eshell-ls-unload-hook instead of an anonymous function.
(eshell-ls--dired)
* lisp/ls-lisp.el (ls-lisp--dired):
Advice dired to handle wildcards in the directory part with both
eshell-ls and ls-lisp.
* etc/NEWS: Announce it.
* doc/emacs/dired.texi (Dired Enter): Update manual.
* test/lisp/dired-tests.el (dired-test-bug27631): Add test.

7 years ago* lisp/find-lisp.el: Enable lexical binding
Tino Calancha [Sat, 29 Jul 2017 16:00:51 +0000 (01:00 +0900)]
* lisp/find-lisp.el: Enable lexical binding

7 years ago* lisp/find-dired.el: Enable lexical binding
Tino Calancha [Sat, 29 Jul 2017 15:50:52 +0000 (00:50 +0900)]
* lisp/find-dired.el: Enable lexical binding

7 years ago* lisp/kmacro.el: Use lexical binding.
Mark Oteiza [Sat, 29 Jul 2017 15:01:57 +0000 (11:01 -0400)]
* lisp/kmacro.el: Use lexical binding.

7 years agoUse lexical-binding in dired-aux.el
Mark Oteiza [Sat, 29 Jul 2017 15:00:51 +0000 (11:00 -0400)]
Use lexical-binding in dired-aux.el

* lisp/dired.el: Use lexical binding.
(dired-do-shell-command): Remove unused bindings.

7 years ago* lisp/ido.el: Use lexical binding.
Mark Oteiza [Sat, 29 Jul 2017 14:28:57 +0000 (10:28 -0400)]
* lisp/ido.el: Use lexical binding.

7 years ago* lisp/whitespace.el: Use lexical binding.
Mark Oteiza [Sat, 29 Jul 2017 14:25:49 +0000 (10:25 -0400)]
* lisp/whitespace.el: Use lexical binding.

7 years agoartist.el: Avoid error with keyboard command invocation
Stephen Berman [Sat, 29 Jul 2017 11:59:18 +0000 (13:59 +0200)]
artist.el: Avoid error with keyboard command invocation

* lisp/textmodes/artist.el (artist-mouse-choose-operation):
Call x-popup-menu with t instead of last-nonmenu-event as the
value of the position argument; this allows invoking the
command from the keyboard without raising an error (bug#27819).

7 years agoPreserve point under 'dired-auto-revert-buffer' (third case)
Stephen Berman [Sat, 29 Jul 2017 11:34:47 +0000 (13:34 +0200)]
Preserve point under 'dired-auto-revert-buffer' (third case)

* lisp/files.el (find-file): Use pop-to-buffer-same-window
instead of switch-to-buffer.  This preserves Dired window
point when dired-auto-revert-buffer is non-nil.  (Bug#27243)

* test/lisp/dired-tests.el (dired-test-bug27243-01)
(dired-test-bug27243-02, dired-test-bug27243-03): New tests.
The first two replace a previous test that combined them; that
test intermittently fails in the Hydra build system, so maybe
separating the two cases will help locate the point of
failure.  The third test involves find-file but is here
because it, like the others, is testing the effect of
dired-auto-revert-buffer.

7 years agoDo not unset user key remaps in dired-x
Allen Li [Sat, 29 Jul 2017 09:00:56 +0000 (12:00 +0300)]
Do not unset user key remaps in dired-x

* lisp/dired-x.el (dired-x-bind-find-file): Don't map any keys if user
sets dired-x-hands-off-my-keys.  (Bug#27828)

Copyright-paperwork-exempt: yes

7 years agoImprove documentation of 'occur'
Eli Zaretskii [Sat, 29 Jul 2017 08:25:29 +0000 (11:25 +0300)]
Improve documentation of 'occur'

* doc/emacs/search.texi (Other Repeating Search):
* lisp/replace.el (occur): Make the documentation of 'occur' be
more accurate when matches overlap.  (Bug#27818)

7 years agoMinor copyedits of comments in faces.el
Eli Zaretskii [Sat, 29 Jul 2017 07:56:57 +0000 (10:56 +0300)]
Minor copyedits of comments in faces.el

* lisp/faces.el (face-font-family-alternatives): More info about
requirements from "Monospace Serif".

7 years ago; Revert "; * .gitignore: Add .deps/."
Eli Zaretskii [Sat, 29 Jul 2017 07:43:23 +0000 (10:43 +0300)]
; Revert "; * .gitignore: Add .deps/."

This reverts commit f1ed31a8f5c6f19aa5e119e670533241c6375945.

7 years agoDo not worry about paxctl on newer NetBSD
Paul Eggert [Sat, 29 Jul 2017 07:01:02 +0000 (00:01 -0700)]
Do not worry about paxctl on newer NetBSD

Problem reported privately by Thomas Klausner.
* configure.ac (emacs_uname_r): New var.  Use it to avoid paxctl
on newer NetBSD platforms, where it is not needed.  Also use it to
simplify Cygwin diagnostic.

7 years agoClarify documentation of ':inherit' face attribute
Eli Zaretskii [Sat, 29 Jul 2017 06:57:51 +0000 (09:57 +0300)]
Clarify documentation of ':inherit' face attribute

* doc/lispref/display.texi (Face Attributes): Document the special
treatment of 'unspecified' in the ':inherit' attribute.

7 years ago* lisp/password-cache.el (password-data): Use a hash-table
Stefan Monnier [Fri, 28 Jul 2017 16:27:00 +0000 (12:27 -0400)]
* lisp/password-cache.el (password-data): Use a hash-table

* lisp/auth-source.el (auth-source-magic): Remove.
(auth-source-forget+, auth-source-forget-all-cached): Adjust to new
format of password-data.
(auth-source-format-cache-entry): Just use a cons.

(password-cache-remove, password-cache-add, password-reset)
(password-read-from-cache, password-in-cache-p): Adjust accordingly.

Fixes: bug#26699
7 years ago* lisp/subr.el (define-symbol-prop): New function
Stefan Monnier [Fri, 28 Jul 2017 16:02:01 +0000 (12:02 -0400)]
* lisp/subr.el (define-symbol-prop): New function

(symbol-file): Make it find symbol property definitions.

* lisp/emacs-lisp/pcase.el (pcase-defmacro):
* lisp/emacs-lisp/ert.el (ert-set-test): Use it instead of `put'.
(ert-describe-test): Adjust call to symbol-file accordingly.

7 years ago* lisp/subr.el (method-files): Move function to cl-generic.el
Stefan Monnier [Fri, 28 Jul 2017 15:28:48 +0000 (11:28 -0400)]
* lisp/subr.el (method-files): Move function to cl-generic.el

* lisp/emacs-lisp/cl-generic.el (cl-generic-p): New function.
(cl--generic-method-files): New function, moved from subr.el.
* lisp/emacs-lisp/edebug.el (edebug-instrument-function): Use them.
* test/lisp/emacs-lisp/cl-generic-tests.el:
* test/lisp/subr-tests.el: Move and adjust method-files tests accordingly.

7 years agoPreserve this-command-keys across recursive-edit invocations
Eli Zaretskii [Fri, 28 Jul 2017 12:40:25 +0000 (15:40 +0300)]
Preserve this-command-keys across recursive-edit invocations

* src/minibuf.c (read_minibuf, read_minibuf_unwind): Save and
restore this-command-keys, to preserve it across recursive-edit.
(Bug#27470)

7 years ago; * .gitignore: Add .deps/.
Eli Zaretskii [Fri, 28 Jul 2017 09:38:22 +0000 (12:38 +0300)]
; * .gitignore: Add .deps/.

7 years agoImprove doc string of 'locate-dominating-file'
Eli Zaretskii [Fri, 28 Jul 2017 09:35:36 +0000 (12:35 +0300)]
Improve doc string of 'locate-dominating-file'

* lisp/files.el (locate-dominating-file): Doc fix.  (Bug#27798)

7 years agoNew commands 'apropos-local-variable', 'apropos-local-value'
Drew Adams [Fri, 28 Jul 2017 07:47:20 +0000 (10:47 +0300)]
New commands 'apropos-local-variable', 'apropos-local-value'

* lisp/apropos.el (apropos-local-variable, apropos-local-value):
New functions.  (Bug#27424)

* doc/emacs/help.texi (Apropos): Document 'apropos-local-variable'
and 'apropos-local-value'.
* etc/NEWS: Mention the new commands.

7 years ago* lisp/loadhist.el (unload-feature): Remove ad-hoc ELP code
Stefan Monnier [Fri, 28 Jul 2017 02:51:37 +0000 (22:51 -0400)]
* lisp/loadhist.el (unload-feature): Remove ad-hoc ELP code

* lisp/emacs-lisp/elp.el (loadhist-unload-element): Un-instrument functions.

7 years agoFix C++ class initializers not always being fontified at mode start.
Alan Mackenzie [Thu, 27 Jul 2017 17:56:23 +0000 (17:56 +0000)]
Fix C++ class initializers not always being fontified at mode start.

The problem here happened when an "outer list" of declarations moved beyond an
"inner list" containing class initializers.  These weren't being checked for
by the code.

Also, fix places in c-get-fontification-context where point is undefined.

* lisp/progmodes/cc-fonts.el (c-get-fontification-context): when argument
not-front-decl is set, test for class initializers.  Also, anchor point in
places where it is moved and is otherwise undefined.

7 years agoFix variables in C++ "for" statement not always being fontified.
Alan Mackenzie [Thu, 27 Jul 2017 17:05:53 +0000 (17:05 +0000)]
Fix variables in C++ "for" statement not always being fontified.

The error happened when there was a comma inside template delimiters.

* lisp/progmodes/cc-fonts.el (c-get-fontification-context): In "for"
statements, recognise template delimiters containing "," and "&".

7 years agoAdd watchdog process to tramp-test36-asynchronous-requests
Michael Albinus [Thu, 27 Jul 2017 10:51:45 +0000 (12:51 +0200)]
Add watchdog process to tramp-test36-asynchronous-requests

* test/lisp/net/tramp-tests.el (tramp--test-timeout-handler):
New defun.
(tramp-test36-asynchronous-requests): Use a watchdog process,
listening for SIGUSR1.

7 years agoCC Mode: Fix declarator being cut off from terminator by end of jit-lock chunk
Alan Mackenzie [Thu, 27 Jul 2017 06:27:13 +0000 (06:27 +0000)]
CC Mode: Fix declarator being cut off from terminator by end of jit-lock chunk

If a declarator is so cut off, extend the fontification chunk to include it.

* lisp/progmodes/cc-mode.el (c-fl-decl-end): New function.
(c-change-expand-fl-region, c-context-expand-fl-region): Use the new function.

7 years ago* lisp/vc/smerge-mode.el: Avoid N² blow up in degenerate cases
Stefan Monnier [Thu, 27 Jul 2017 04:21:35 +0000 (00:21 -0400)]
* lisp/vc/smerge-mode.el: Avoid N² blow up in degenerate cases

(smerge--refine-long-words): New var.
(smerge--refine-chopup-region): Use it.

7 years ago* lisp/url/url-cookie.el: Use lexical-binding
Stefan Monnier [Thu, 27 Jul 2017 04:13:27 +0000 (00:13 -0400)]
* lisp/url/url-cookie.el: Use lexical-binding

(url-cookie-host-can-set-p): Remove unused var `last'.
Use string-suffix-p.
(url-cookie-list): De morgan.
(url-cookie-quit): Remove.
(url-cookie-mode): Inherit from special-mode.
(url-cookie-mode-map): Simplify accordingly.

7 years ago* lisp/calendar/todo-mode.el (todo-print-buffer-function): Rework docstring.
Stefan Monnier [Thu, 27 Jul 2017 04:09:17 +0000 (00:09 -0400)]
* lisp/calendar/todo-mode.el (todo-print-buffer-function): Rework docstring.

7 years ago* lisp/ruler-mode.el (ruler-mode-ruler): Document problem.
Stefan Monnier [Thu, 27 Jul 2017 04:07:17 +0000 (00:07 -0400)]
* lisp/ruler-mode.el (ruler-mode-ruler): Document problem.

7 years ago* lisp/emacs-lisp/cl-generic.el (cl-generic-define-method):
Stefan Monnier [Thu, 27 Jul 2017 03:22:58 +0000 (23:22 -0400)]
* lisp/emacs-lisp/cl-generic.el (cl-generic-define-method):

Record this as the function's definition site if it's the first def.

7 years ago* doc/lispref/loading.texi (When to Autoload): New section.
Glenn Morris [Wed, 26 Jul 2017 16:40:13 +0000 (12:40 -0400)]
* doc/lispref/loading.texi (When to Autoload): New section.

7 years agoStop using unibyte buffers for ert backtraces
Glenn Morris [Wed, 26 Jul 2017 16:38:46 +0000 (12:38 -0400)]
Stop using unibyte buffers for ert backtraces

* lisp/emacs-lisp/ert.el
(ert-results-pop-to-backtrace-for-test-at-point):
Set multibyte true, not false.  This copies a
debugger-setup-buffer change from 2009-08-30, and stops the
"Backtrace for" header line containing ^X and ^Y.

7 years agoFix semantic-symref-parse-tool-output-one-line after 644cdd1aa0
Dmitry Gutov [Wed, 26 Jul 2017 16:34:48 +0000 (19:34 +0300)]
Fix semantic-symref-parse-tool-output-one-line after 644cdd1aa0

* lisp/cedet/semantic/symref/grep.el
(semantic-symref-grep--line-re): Delete.
(semantic-symref-parse-tool-output-one-line):
Use regexp and group numbers from (grep-regexp-alist).

7 years agoFix cl-defmethod indentation
Grégoire Jadi [Wed, 26 Jul 2017 15:46:16 +0000 (18:46 +0300)]
Fix cl-defmethod indentation

* lisp/emacs-lisp/cl-generic.el (cl-defmethod):
Declare (indent defun).  Fixes bug#23994.

7 years agoFix two customization types in frame.el
Martin Rudalics [Wed, 26 Jul 2017 08:14:06 +0000 (10:14 +0200)]
Fix two customization types in frame.el

* lisp/frame.el (window-divider-default-bottom-width)
(window-divider-default-right-width): Fix customization types.

7 years agoDired: Support eshell-ls from the beginning if the user wants to
Tino Calancha [Wed, 26 Jul 2017 07:42:30 +0000 (16:42 +0900)]
Dired: Support eshell-ls from the beginning if the user wants to

* lisp/dired.el (dired-insert-directory): Check for eshell-ls
as well (Bug#27817).
* test/lisp/dired-tests.el (dired-test-bug27817): Add test.

7 years ago* lisp/progmodes/sh-script.el (sh-mode): Recognize mkshrc.
Mark Oteiza [Wed, 26 Jul 2017 02:13:20 +0000 (22:13 -0400)]
* lisp/progmodes/sh-script.el (sh-mode): Recognize mkshrc.

7 years ago* lisp/emacs-lisp/eieio-compat.el (eieio--defgeneric-init-form):
Stefan Monnier [Tue, 25 Jul 2017 14:12:58 +0000 (10:12 -0400)]
* lisp/emacs-lisp/eieio-compat.el (eieio--defgeneric-init-form):

Adjust to change in cl-generic-ensure-function.

7 years ago; Instrument entry of tramp--test-instrument-test-case
Michael Albinus [Tue, 25 Jul 2017 08:05:43 +0000 (10:05 +0200)]
; Instrument entry of tramp--test-instrument-test-case

7 years agols-lisp: Add an unload function and enable lexical binding
Tino Calancha [Tue, 25 Jul 2017 05:53:44 +0000 (14:53 +0900)]
ls-lisp: Add an unload function and enable lexical binding

Enable lexical binding.
* lisp/ls-lisp.el (ls-lisp-unload-function): New defun.
* test/lisp/ls-lisp.el (ls-lisp-unload): Add test.

7 years agoregister-read-with-preview: Quit if user input C-g or ESC
Tino Calancha [Tue, 25 Jul 2017 02:38:28 +0000 (11:38 +0900)]
register-read-with-preview: Quit if user input C-g or ESC

* lisp/register.el (register-read-with-preview):
Quit if user input C-g or ESC (bug#27634).
* doc/emacs/regs.texi (Registers): Update manual.
* test/lisp/register-tests.el (register-test-bug27634): Add test.

7 years ago; Fix previous commit
Mark Oteiza [Tue, 25 Jul 2017 00:17:50 +0000 (20:17 -0400)]
; Fix previous commit

Functions prefixed with `turn-on-foo' are quite old, and in general
subsumed by the corresponding `foo-mode` command.
* lisp/display-line-numbers.el (turn-on-display-line-numbers-mode):
Rename with library prefix, mark as internal.  Nix autoload.

7 years agoRecognize MirBSD Korn shell rc file
Mark Oteiza [Tue, 25 Jul 2017 00:13:33 +0000 (20:13 -0400)]
Recognize MirBSD Korn shell rc file

* lisp/files.el (auto-mode-alist): Add .mkshrc to the list.

7 years ago* configure.ac: Be explicit about ImageMagick version in summary.
Glenn Morris [Mon, 24 Jul 2017 23:51:27 +0000 (19:51 -0400)]
* configure.ac: Be explicit about ImageMagick version in summary.

7 years agoProperly align global lispsym
Andreas Schwab [Mon, 24 Jul 2017 23:12:50 +0000 (01:12 +0200)]
Properly align global lispsym

* lib-src/make-docfile.c (close_emacs_globals): Wrap struct
Lisp_Symbols inside struct.
* src/alloc.c (sweep_symbols): Update use of lispsym.
* src/lisp.h (builtin_lisp_symbol): Likewise.

7 years agoDo not use ImageMagick 7 and later
Paul Eggert [Mon, 24 Jul 2017 22:13:26 +0000 (15:13 -0700)]
Do not use ImageMagick 7 and later

Suggested by Glenn Morris (Bug#25967#15).
* configure.ac (IMAGEMAGICK_MODULE): Reject 7 and later.

7 years ago* lisp/progmodes/perl-mode.el: Add support for indented here docs
Stefan Monnier [Mon, 24 Jul 2017 22:10:02 +0000 (18:10 -0400)]
* lisp/progmodes/perl-mode.el: Add support for indented here docs

* lisp/progmodes/perl-mode.el (perl-syntax-propertize-function):
Recognize the new <<~ syntax for indented here docs.
(perl-syntax-propertize-special-constructs): Adjust search of the
end of here docs accordingly.

* test/manual/indent/perl.perl: Add test for indented here docs.

7 years ago(loadhist-unload-element): Move ERT and cl-generic methods
Stefan Monnier [Mon, 24 Jul 2017 19:58:30 +0000 (15:58 -0400)]
(loadhist-unload-element): Move ERT and cl-generic methods

* lisp/loadhist.el (loadhist-unload-element): Don't define cl-generic
and ert methods here.
(loadhist-unload-element) <(head define-type)>: Remove unused var `slots'.

* lisp/emacs-lisp/cl-generic.el (loadhist-unload-element): Define
unload method for cl-defmethod.
(cl-generic-ensure-function): Remove redundant `defalias'.

* lisp/emacs-lisp/ert.el (ert-set-test): Move the current-load-list
setting here...
(ert-deftest): ...from here.
(loadhist-unload-element): Define unload method for ert-deftest.

7 years agoFix Bug#27371
Michael Albinus [Mon, 24 Jul 2017 17:38:17 +0000 (19:38 +0200)]
Fix Bug#27371

* lisp/loadhist.el (loadhist-unload-element): Declare for
different entry types of `load-history'.
(loadhist--restore-autoload): New variable.
(loadhist--unload-function): New defun.
(unload-feature): Use `loadhist-unload-element'.  Recommended by
Stefan Monnier.  (Bug#27371)

* test/lisp/net/tramp-tests.el (tramp-test39-unload):
Check, that the `tramp-file-name' structure has been unloaded.

7 years agoEnsure that we parse images right in shr.el
Grégoire Jadi [Mon, 24 Jul 2017 15:29:28 +0000 (17:29 +0200)]
Ensure that we parse images right in shr.el

* lisp/net/shr.el (shr-image-fetched): Go back to the
beginning of the buffer before trying to parse the image
fetched.

7 years agoUpdate .gitignore for Valgrind and no Automake
Paul Eggert [Mon, 24 Jul 2017 05:40:21 +0000 (22:40 -0700)]
Update .gitignore for Valgrind and no Automake

* .gitignore: Remove .deps/ since we no longer use Automake.
Add vgcore.*[0-9], for debugging Emacs with Valgrind+GDB.

7 years agoMerge from gnulib
Paul Eggert [Mon, 24 Jul 2017 05:21:38 +0000 (22:21 -0700)]
Merge from gnulib

This incorporates:
2017-07-23 Rename module 'strftime' to 'nstrftime'
* admin/merge-gnulib (GNULIB_MODULES): Add nstrftime, remove strftime.
* build-aux/config.guess: Copy from gnulib.
* lib/nstrftime.c: Rename from lib/strftime.c.
* m4/nstrftime.m4: Rename from m4/strftime.m4.
* lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.

7 years ago; Don't keep temporary buffers alive after a dired test
Tino Calancha [Mon, 24 Jul 2017 02:58:35 +0000 (11:58 +0900)]
; Don't keep temporary buffers alive after a dired test

* test/lisp/dired-tests.el (dired-test-bug22694)
(dired-test-bug25609, dired-test-bug27243)
Delete all temporary dired buffers at the end.

7 years agoAdd 'rx' pattern for pcase.
Philipp Stephani [Thu, 20 Jul 2017 19:36:18 +0000 (21:36 +0200)]
Add 'rx' pattern for pcase.

* lisp/emacs-lisp/rx.el (rx): New pcase macro.
* test/lisp/emacs-lisp/rx-tests.el (rx-pcase): Add unit test.

7 years agoUse a named function for global minor mode turn-on argument
Mark Oteiza [Sun, 23 Jul 2017 19:41:51 +0000 (15:41 -0400)]
Use a named function for global minor mode turn-on argument

* lisp/display-line-numbers.el (turn-on-display-line-numbers-mode):
New function.
(global-display-line-numbers-mode): Use it.

7 years agoEnable GUI Emacs without 'make install' on macOS (Bug #27645)
Charles A. Roelli [Mon, 10 Jul 2017 19:08:14 +0000 (21:08 +0200)]
Enable GUI Emacs without 'make install' on macOS (Bug #27645)

* nextstep/INSTALL: Correct it, and mention that Emacs can be run
from 'src/emacs'.

* src/nsterm.m (applicationDidFinishLaunching:): When Emacs is
launched outside of a macOS application bundle, change its
activation policy from the default 'prohibited' to 'regular'.

; * etc/NEWS: Mention the change on macOS.

7 years agoConvert CC Mode's c-found-types from an obarray to a hash table.
Alan Mackenzie [Sun, 23 Jul 2017 13:48:36 +0000 (13:48 +0000)]
Convert CC Mode's c-found-types from an obarray to a hash table.

* lisp/progmodes/cc-engine.el (c-clear-found-types): create a hash table
rather than an obarray.
(c-copy-found-types): Remove.
(c-add-type, c-unfind-type, c-check-type, c-list-found-types): Amend to use
the new hash table.
(c-forward-<>-arglist): Use copy-hash-table rather than c-copy-found-types.

7 years agoFix image/svg+xml display in shr
Lars Ingebrigtsen [Sun, 23 Jul 2017 13:22:48 +0000 (15:22 +0200)]
Fix image/svg+xml display in shr

* lisp/net/shr.el (shr-put-image): Display svg images as svg
(bug#27799).  I suspect the previous change was checked in by
accident in conjuction with some other svg changes.

7 years ago* lisp/display-line-numbers.el (display-line-numbers-type): Autoload it.
Michael Albinus [Sun, 23 Jul 2017 07:28:35 +0000 (09:28 +0200)]
* lisp/display-line-numbers.el (display-line-numbers-type): Autoload it.

7 years agoDon't automatically enable Gconf if Gsettings was found
Glenn Morris [Sun, 23 Jul 2017 01:43:28 +0000 (18:43 -0700)]
Don't automatically enable Gconf if Gsettings was found

* configure.ac (HAVE_GCONF) [HAVE_GSETTINGS]:
Don't test for Gconf unless specifically requested.
Gconf was deprecated in favor of Gsettings several years ago.

7 years ago* configure.ac (MODULES_SUFFIX): Always give it a value.
Glenn Morris [Sun, 23 Jul 2017 01:36:22 +0000 (18:36 -0700)]
* configure.ac (MODULES_SUFFIX): Always give it a value.

This prevents a Makefile thinko like "rm *${MODULE_SUFFIX}".

7 years ago* doc/emacs/frames.texi (Fonts): Mention Gsettings.
Glenn Morris [Sun, 23 Jul 2017 01:28:46 +0000 (18:28 -0700)]
* doc/emacs/frames.texi (Fonts): Mention Gsettings.

7 years agoAdd line numbers display to the Options menu
Michael Albinus [Sat, 22 Jul 2017 18:24:24 +0000 (20:24 +0200)]
Add line numbers display to the Options menu

* lisp/menu-bar.el (toggle-display-line-numbers): Remove.
(menu-bar-display-line-numbers-mode): New defun.
(menu-bar-showhide-line-numbers-menu): New defvar.
(menu-bar-showhide-menu): Use `menu-bar-showhide-line-numbers-menu'

7 years ago; * CONTRIBUTE: Rearrange sections into a more logical order.
Eli Zaretskii [Sat, 22 Jul 2017 15:51:18 +0000 (18:51 +0300)]
; * CONTRIBUTE: Rearrange sections into a more logical order.

7 years agoSignal error for symbol names with strange quotes (Bug#2967)
Noam Postavsky [Wed, 7 Jun 2017 23:59:09 +0000 (19:59 -0400)]
Signal error for symbol names with strange quotes (Bug#2967)

* src/lread.c (read1): Signal an error when a symbol starts with a
non-escaped quote-like character.
* test/src/lread-tests.el (lread-tests--funny-quote-symbols): New
test.
* etc/NEWS: Announce change.

7 years agoRevert "Let delete-selection-mode work with popup-menu commands (Bug#27569)"
Noam Postavsky [Sat, 22 Jul 2017 12:07:37 +0000 (08:07 -0400)]
Revert "Let delete-selection-mode work with popup-menu commands (Bug#27569)"

It turns out that this change is not needed, and it leaves several
command loops settings not done.

https://lists.gnu.org/archive/html/emacs-devel/2017-07/msg00757.html
https://lists.gnu.org/archive/html/emacs-devel/2017-07/msg00840.html

7 years agoAdd a minor mode interface for display-line-numbers
Alexander Gramiak [Sat, 22 Jul 2017 09:16:08 +0000 (12:16 +0300)]
Add a minor mode interface for display-line-numbers

* lisp/cus-start.el: Use the new display-line-numbers group.
* lisp/display-line-numbers.el: New file.

* doc/emacs/custom.texi (Init Rebinding): Re-add entry that used to
belong to linum-mode.
* doc/emacs/modes.texi (Minor Modes): Summarize the mode.
* etc/NEWS: Document display-line-numbers-mode and its customization
variables, and mention that display-line-numbers-width is
buffer-local.

* src/xdisp.c (syms_of_xdisp) <display-line-numbers-width>: Fix a
typo.

7 years agoSupport indented HERE-DOCs in cperl-mode
vividsnow [Sat, 22 Jul 2017 09:07:55 +0000 (12:07 +0300)]
Support indented HERE-DOCs in cperl-mode

* lisp/progmodes/cperl-mode.el (cperl-find-pods-heres): Support
indented here-docs.  (Bug#27254) (Bug#27697)

Copyright-paperwork-exempt: yes

7 years agoDocument the support for "scrollBar" X resource
Eli Zaretskii [Sat, 22 Jul 2017 09:02:16 +0000 (12:02 +0300)]
Document the support for "scrollBar" X resource

* doc/emacs/xresources.texi (Table of Resources): Document the new
'scrollBar' setting.
* etc/NEWS: Document the new 'scrollBar' setting.

7 years agoAdd 'scroll-bar-mode' to settings in 'x-apply-session-resources'
Matthew Bauer [Sat, 22 Jul 2017 08:53:58 +0000 (11:53 +0300)]
Add 'scroll-bar-mode' to settings in 'x-apply-session-resources'

* lisp/startup.el (x-apply-session-resources): Add scroll-bar-mode
settings.

Copyright-paperwork-exempt: yes

7 years agoUpdate ld-script mode (bug#27629)
Alexander Kuleshov [Sat, 22 Jul 2017 08:47:33 +0000 (11:47 +0300)]
Update ld-script mode (bug#27629)

* lisp/progmodes/ld-script.el: (ld-script-keywords): New commands
NOCROSSREFS_TO and HIDDEN added.  Fix documentation sections
numbers for PROVIDE/PROVIDE_HIDDEN commands.
(ld-script-builtins): New builtin function LOG2CEIL added.

7 years agoIndex 'rectangle' in the ELisp manual
Eli Zaretskii [Sat, 22 Jul 2017 08:41:09 +0000 (11:41 +0300)]
Index 'rectangle' in the ELisp manual

* doc/lispref/text.texi (Registers): Index the "rectangle" value.
(Bug#27541)

7 years ago* lisp/subr.el (add-to-history): Doc fix. (Bug#27494)
Eli Zaretskii [Sat, 22 Jul 2017 08:34:55 +0000 (11:34 +0300)]
* lisp/subr.el (add-to-history): Doc fix.  (Bug#27494)

7 years agoDoc fixes for kmacro.el functions
Eli Zaretskii [Sat, 22 Jul 2017 08:24:05 +0000 (11:24 +0300)]
Doc fixes for kmacro.el functions

* lisp/kmacro.el (kmacro-start-macro, kmacro-call-macro)
(kmacro-end-and-call-macro): Don't use "permanent name", as that
could be misinterpreted.  (Bug#27492)

7 years agoElDoc: add docstrings and minor refactoring
Charles A. Roelli [Sat, 22 Jul 2017 08:09:36 +0000 (11:09 +0300)]
ElDoc: add docstrings and minor refactoring

* lisp/emacs-lisp/eldoc.el (eldoc-edit-message-commands): Add
docstring.
(turn-on-eldoc-mode): Fix capitalization.
(eldoc--supported-p): Add docstring.
(eldoc-schedule-timer): Add docstring and use
'eldoc--supported-p'.
(eldoc-message): Add docstring and make calling convention
clearer.
(eldoc--message-command-p):
(eldoc-pre-command-refresh-echo-area):
(eldoc-display-message-p):
(eldoc-display-message-no-interference-p):
(eldoc-print-current-symbol-info):
(eldoc-docstring-format-sym-doc):
(eldoc-add-command, eldoc-add-command-completions):
(eldoc-remove-command, eldoc-remove-command-completions):
Add docstring.  (Bug#27230)

7 years agoMention 'C-M-i' as key binding for 'ispell-complete-word'
Fabrice Bauzac [Sat, 22 Jul 2017 07:56:26 +0000 (10:56 +0300)]
Mention 'C-M-i' as key binding for 'ispell-complete-word'

* doc/emacs/fixit.texi (Spelling): ispell-complete-word
can also be invoked by C-M-i.  (Bug#27349)

Copyright-paperwork-exempt: yes

7 years ago; * doc/emacs/search.texi (Word Search): Update for changes in bug#27341.
Eli Zaretskii [Sat, 22 Jul 2017 07:52:52 +0000 (10:52 +0300)]
; * doc/emacs/search.texi (Word Search): Update for changes in bug#27341.

7 years agoFix the eww-search-words description in the Emacs manual
Fabrice Bauzac [Sat, 22 Jul 2017 07:43:11 +0000 (10:43 +0300)]
Fix the eww-search-words description in the Emacs manual

* doc/emacs/search.texi (Word Search):
Include the key binding for eww-search-words in the manual.
Fix the spelling of the 'eww-search-words' command.

Copyright-paperwork-exempt: yes

7 years agoIntroduce defcustom 'executable-prefix-env'
Andrew L. Moore [Sat, 22 Jul 2017 07:34:18 +0000 (10:34 +0300)]
Introduce defcustom 'executable-prefix-env'

* lisp/progmodes/executable.el (executable-prefix): Update the doc
string.
(executable-prefix-env): New defcustom.
(executable-set-magic): Use executable-prefix-env.

* etc/NEWS: Document the new variable.

7 years ago* test/lisp/ibuffer-tests.el: Delete temporary files.
Glenn Morris [Sat, 22 Jul 2017 01:22:49 +0000 (21:22 -0400)]
* test/lisp/ibuffer-tests.el: Delete temporary files.

7 years agoFurther attempt to avoid hang in network-stream-tests
Glenn Morris [Fri, 21 Jul 2017 18:01:12 +0000 (14:01 -0400)]
Further attempt to avoid hang in network-stream-tests

* test/lisp/net/network-stream-tests.el (connect-to-tls-ipv6-nowait):
Limit the time we wait for the external process.

7 years agoStop skipping many ibuffer tests by default
Glenn Morris [Fri, 21 Jul 2017 17:49:37 +0000 (13:49 -0400)]
Stop skipping many ibuffer tests by default

* test/lisp/ibuffer-tests.el (ibuffer-0autoload):
Rename so it sorts first.
(ibuffer-save-filters, ibuffer-filter-inclusion-1)
(ibuffer-filter-inclusion-2, ibuffer-filter-inclusion-3)
(ibuffer-filter-inclusion-4, ibuffer-filter-inclusion-5)
(ibuffer-filter-inclusion-6, ibuffer-filter-inclusion-7)
(ibuffer-filter-inclusion-8, ibuffer-decompose-filter)
(ibuffer-and-filter, ibuffer-or-filter, ibuffer-format-qualifier)
(ibuffer-unary-operand): Require ibuf-ext so tests not skipped.

7 years agoUse lexical-binding in todo-mode.el
Stefan Monnier [Fri, 21 Jul 2017 16:54:07 +0000 (18:54 +0200)]
Use lexical-binding in todo-mode.el

Adjust code accordingly and make various minor improvements.

* lisp/calendar/todo-mode.el: Enable lexical-binding.
(dayname, monthname, day, month, year): Make forward defvars
of these keywords from macros defined in calendar.el; wrap
them in with-no-warnings.
(todo-files, todo-files-function, todo-date-pattern)
(todo-mode-line-function, todo-show, todo-forward-category)
(todo-edit-item--header, todo-set-category-number)
(todo-adjusted-category-label-length)
(todo-total-item-counts, todo-filter-items)
(todo-print-buffer-function, todo-convert-legacy-date-time)
(todo-category-number, todo-category-completions)
(todo-read-file-name, todo-read-category)
(todo-validate-name, todo-read-date)
(todo-set-show-current-file, todo-modes-set-1)
(todo-modes-set-2, todo-modes-set-3, todo-mode):
Use #' instead of ' to quote functions.
(todo-files): Use \' instead of $ in regexp.
(todo--files-type-list): New function.
(todo-default-todo-file, todo-category-completions-files)
(todo-filter-files, todo-multiple-filter-files)
(todo-reevaluate-default-file-defcustom)
(todo-reevaluate-category-completions-files-defcustom)
(todo-reevaluate-filter-files-defcustom): Use it.
(todo-show, todo-rename-file, todo-move-category)
(todo-edit-item--text, todo-edit-quit, todo-edit-item--header)
(todo-item-undone, todo-unarchive-items, todo-search)
(todo-filter-items, todo-filter-items-1, todo-find-item)
(todo-category-select, todo-read-date)
(todo-nondiary-marker-matcher, todo-date-string-matcher)
(todo-diary-expired-matcher, todo-convert-legacy-files)
(todo-read-category): Reformat to avoid code hiding behind a
more deeply embedded element.
(todo-forward-category, todo-set-category-number):
Use 'funcall' instead of 'apply'.
(todo-toggle-mark-item, todo-edit-item--diary-inclusion)
(todo-edit-category-diary-inclusion)
(todo-insert-sort-button, todo-insert-category-line)
(todo-multiple-filter-files): Mark unused local variables.
(todo-edit-item--header, todo-move-item, todo-print-buffer)
(todo-edit-item--header, todo-move-item, todo-check-file)
(todo-edit-item--next-key): Remove unused local variables.
(todo-insert-sort-button, todo-insert-category-line):
Use a closure instead of a backquoted lambda.
(todo-update-categories-display, todo-print-buffer): Simplify code.
(todo-print-buffer-function): Document calling convention.
(todo-category-completions): Use cl-pushnew instead of add-to-list.
(todo-mode-map, todo-archive-mode-map)
(todo-categories-mode-map, todo-filtered-items-mode-map):
Remove superfluous call of suppress-keymap, since it's already
in the parent special-mode-map.

7 years agodired: Revert buffer when DIRNAME is a cons
Tino Calancha [Fri, 21 Jul 2017 04:32:48 +0000 (13:32 +0900)]
dired: Revert buffer when DIRNAME is a cons

* lisp/dired.el (dired-internal-noselect): Revert buffer if DIR-OR-LIST
is a cons, or dired-directory is a cons and DIR-OR-LIST a string (Bug#7131).
Update the comments.
* test/lisp/dired-tests.el (dired-test-bug7131): Test should pass.

7 years ago; * etc/NEWS: Fix format of an entry.
Tino Calancha [Fri, 21 Jul 2017 04:23:38 +0000 (13:23 +0900)]
; * etc/NEWS: Fix format of an entry.

7 years agoHandle when dired-directory is a cons in some Dired functions
Tino Calancha [Fri, 21 Jul 2017 04:17:14 +0000 (13:17 +0900)]
Handle when dired-directory is a cons in some Dired functions

* lisp/dired-aux.el (dired-rename-subdir-1)
* lisp/dired-x.el (dired-mark-omitted):
Handle when dired-directory is a cons.

7 years agoMake eshell-next-prompt more reliable (Bug#27405)
Noam Postavsky [Wed, 12 Jul 2017 02:11:19 +0000 (22:11 -0400)]
Make eshell-next-prompt more reliable (Bug#27405)

* lisp/eshell/em-prompt.el (eshell-next-prompt): Search for
`eshell-prompt-regexp' (and `read-only' text-property if
`eshell-highlight-prompt' is set) rather than trying to use
`forward-paragraph'.
(eshell-previous-prompt): Don't count prompt on current line.

7 years agoSimplify recent gnutls.c changes
Paul Eggert [Thu, 20 Jul 2017 23:21:57 +0000 (16:21 -0700)]
Simplify recent gnutls.c changes

* src/gnutls.c (clear_storage) [HAVE_GNUTLS3_AEAD]: Remove.
All uses replaced by calls to explicit_bzero; that’s clear enough.
(gnutls_symmetric_aead) [HAVE_GNUTLS3_AEAD]: Simplify by
coalescing duplicate actions.  There is no need to invoke
SAFE_FREE before calling ‘error’.

7 years ago; Spelling fixes
Paul Eggert [Thu, 20 Jul 2017 22:40:48 +0000 (15:40 -0700)]
; Spelling fixes

7 years agoMerge branch 'master' of git.sv.gnu.org:/srv/git/emacs
Michael Albinus [Thu, 20 Jul 2017 18:28:17 +0000 (20:28 +0200)]
Merge branch 'master' of git.sv.gnu.org:/srv/git/emacs

7 years agoStylistic changes in tramp-cache.el
Michael Albinus [Thu, 20 Jul 2017 18:27:55 +0000 (20:27 +0200)]
Stylistic changes in tramp-cache.el

* test/lisp/net/tramp-cache.el (tramp-get-file-property)
(tramp-set-file-property): Use `bound-and-true-p'.  Add
counter variables to `tramp-cache-unload-hook'.

7 years ago* admin/notes/hydra: Small updates.
Glenn Morris [Thu, 20 Jul 2017 18:00:27 +0000 (14:00 -0400)]
* admin/notes/hydra: Small updates.

7 years agoMake tramp unloading handle debug counter variables
Glenn Morris [Thu, 20 Jul 2017 17:46:52 +0000 (13:46 -0400)]
Make tramp unloading handle debug counter variables

* lisp/net/tramp-cache.el (tramp-get-file-property)
(tramp-set-file-property): Add counter variables to tramp-unload-hook.

7 years agoFix hscrolling calculations when display-line-numbers is set
Eli Zaretskii [Thu, 20 Jul 2017 13:25:11 +0000 (16:25 +0300)]
Fix hscrolling calculations when display-line-numbers is set

* src/xdisp.c (move_it_in_display_line_to): Account for line
numbers in hscrolled lines.  (Bug#27756)

7 years agoFix the bogus change made 13 years ago (bug#27084)
Katsumi Yamaoka [Thu, 20 Jul 2017 07:16:48 +0000 (07:16 +0000)]
Fix the bogus change made 13 years ago (bug#27084)

* lisp/gnus/gnus-sum.el (gnus-summary-toggle-header):
Fix the way to test if there is no visible header (bug#27084).

7 years agoUse grep's --null option (Bug#6843)
Noam Postavsky [Wed, 14 Sep 2016 00:48:09 +0000 (20:48 -0400)]
Use grep's --null option (Bug#6843)

* lisp/progmodes/grep.el (grep-use-null-filename-separator): New option.
(grep--regexp-alist-column, grep--regexp-alist-bin-matcher)
(grep-with-null-regexp-alist, grep-fallback-regexp-alist): New
constants, replacing `grep-regexp-alist'.
(grep-regex-alist): Mark the variable obsolete, add a new function of
the same name to replace it.
(grep-compute-defaults): Compute default for
`grep-use-null-filename-separator'.
(grep-mode): Set compilation-error-regexp-alist (buffer locally) to the
value of `grep-with-null-regexp-alist' or `grep-fallback-regexp-alist'
according to `grep-use-null-filename-separator'.
* lisp/progmodes/xref.el (xref-collect-matches): Call
`grep-regex-alist' instead of the obsolete variable.  Don't hardcode
grep-regexp-alist match groups.
* etc/NEWS: Announce new use of --null.  Move 'grep-save-buffers'
item under "Grep" heading as well.

7 years ago* src/gnutls.c (clear_storage): Define only if needed.
Philipp Stephani [Wed, 19 Jul 2017 19:21:40 +0000 (21:21 +0200)]
* src/gnutls.c (clear_storage): Define only if needed.

7 years agoAdjust todo-quit to recent change in dired
Stephen Berman [Wed, 19 Jul 2017 13:41:59 +0000 (15:41 +0200)]
Adjust todo-quit to recent change in dired

* lisp/calendar/todo-mode.el (todo-quit): Use quit-window instead of
bury-buffer to exit todo-mode.  This restores the desired behavior
of not immediately returning to the exited todo-mode buffer on
quitting another buffer, which a dired bug fix had changed (see
http://lists.gnu.org/archive/html/emacs-devel/2017-07/msg00739.html).