Commit graph

64251 commits

Author SHA1 Message Date
Stefan Monnier
f6bdbdf1f5 (completion-lisp-mode-hook): Use completion-separator-chars
* lisp/completion.el (completion-lisp-mode-hook):
Use completion-separator-chars rather than local key binding.
2015-04-13 10:35:15 -04:00
Fabián Ezequiel Gallina
659609d182 python.el: Keep symmetry on sexp navigation with parens
Fixes: debbugs:19954

* lisp/progmodes/python.el
(python-nav--forward-sexp): Add argument skip-parens-p.
(python-nav-forward-sexp, python-nav-backward-sexp)
(python-nav-forward-sexp-safe)
(python-nav-backward-sexp-safe): Use it.

* test/automated/python-tests.el
(python-nav-forward-sexp-1): Fix test.
2015-04-12 22:43:44 -03:00
João Távora
ed28ca4c24 Don't use `setq-local' in Gnus code
This might break upstream builds with older Emacsen

* lisp/gnus/message.el (message-mode): Use `set' and
`make-local-variable' instead of `setq-local'.
2015-04-12 23:25:09 +01:00
Artur Malabarba
e99d8cb25d * lisp/emacs-lisp/package.el: Improve transaction y-or-n prompt
(package-menu--prompt-transaction-p): Prompt for "Delete" first,
"Upgrade" last, and use capitalized instead of all-caps.
2015-04-12 16:16:06 +01:00
Artur Malabarba
5aa0dfe4b7 * lisp/emacs-lisp/package.el: Completely silence async operations
(package--make-autoloads-and-stuff): Silence autoloads.

(package--save-selected-packages): New function, silences
`customize-save-variable'.
(package--user-selected-p, package-install-from-buffer)
(package-delete, package-install): Use it.

(package-install-from-archive)
(package-menu--perform-transaction): Silence.

(package-menu-execute): Feedback when operation starts.
2015-04-12 16:16:06 +01:00
Artur Malabarba
dfdd7e1944 Use delay-mode-hooks when visiting the init-file
* lisp/emacs-lisp/package.el (package--ensure-init-file):
delay-mode-hooks

* lisp/cus-edit.el (custom-save-all): delay-mode-hooks
2015-04-12 16:16:06 +01:00
Artur Malabarba
5fb807efcd * lisp/files.el: Only message when saving if save-silently is nil
(save-silently): New variable.
(files--message): New function.

(find-file-noselect, save-buffer, basic-save-buffer)
(basic-save-buffer-2, save-some-buffers, not-modified)
(append-to-file): Use them.
2015-04-12 16:16:05 +01:00
Johan Bockgård
2e47de365b Support debug declarations in pcase macros
* lisp/emacs-lisp/pcase.el (pcase-MACRO): New edebug spec.
(pcase-UPAT): Use it.  Remove "`".
(pcase--edebug-match-macro): New function.
(pcase-defmacro): Support debug declarations.

* lisp/emacs-lisp/cl-macs.el (cl-struct) <pcase-defmacro>:
* lisp/emacs-lisp/eieio.el (eieio) <pcase-defmacro>:
* lisp/emacs-lisp/pcase.el (\`): <pcase-defmacro>: Add debug declaration.
2015-04-12 16:26:52 +02:00
Johan Bockgård
66a53da5f0 pcase.el: Edebug support for `app' and vector patterns
* lisp/emacs-lisp/pcase.el (pcase-FUN): New edebug spec.
(pcase-UPAT): Use it. Support `app' patterns.
(pcase-QPAT): Support vector patterns.
2015-04-12 16:26:51 +02:00
Johan Bockgård
b62d7956be edebug.el: Disambiguate vector specifications
* lisp/emacs-lisp/edebug.el (edebug-match-list): Always treat
`(vector ...)' as a vector specification, not as a sublist.
2015-04-12 16:26:51 +02:00
Johan Bockgård
f4dbec453d (gnus-summary-refer-thread): Don't clobber unread articles
This fixes a bug where `A T' causes "random" articles to become marked
as read.

* lisp/gnus/gnus-sum.el (gnus-summary-refer-thread): Make sure
gnus-newsgroup-unreads remains sorted.
2015-04-12 16:13:08 +02:00
Johan Bockgård
bda8469be5 mouse-sel.el: Fix mouse-sel-get-selection-function
* lisp/obsolete/mouse-sel.el (mouse-sel-get-selection-function):
Use gui--last-selected-text-primary instead of no longer existing
gui-last-selected-text.
2015-04-12 15:55:32 +02:00
Johan Bockgård
a77540e774 * lisp/rect.el (delete-whitespace-rectangle-line): Don't cross EOL. 2015-04-12 15:50:02 +02:00
Johan Bockgård
a3d11ecb83 * lisp/net/nsm.el (nsm-query-user): Use cursor-in-echo-area. 2015-04-12 15:37:50 +02:00
Artur Malabarba
d0fcb21254 * lisp/emacs-lisp/package.el (list-packages): Avoid redundant generate 2015-04-12 13:47:58 +01:00
Artur Malabarba
d06eeb85e0 * lisp/emacs-lisp/package.el (list-packages): Call refresh in right buffer 2015-04-12 13:45:30 +01:00
Artur Malabarba
9a7ddde977 * lisp/emacs-lisp/bytecomp.el: Silence noninteractive compilations
(byte-compile--interactive): New var.
(byte-compile--message): New function.
(byte-compile-log-1, byte-force-recompile)
(byte-recompile-directory, byte-recompile-file)
(byte-compile-file, compile-defun)
(byte-compile-file-form-defmumble, byte-compile)
(byte-compile-file-form-defalias, display-call-tree): Use it.
2015-04-12 13:45:30 +01:00
Artur Malabarba
ad36067a1e * lisp/files.el: Don't message when nothing happened
(save-some-buffers, basic-save-buffer): Before messaging to say
"nothing was saved" check if (called-interactively-p 'any).
2015-04-12 13:45:30 +01:00
João Távora
25449e7296 Summary: Improve sexp-based movement in message-mode
Works by giving citations and smileys a different syntax.  This helps
modes like `show-paren-mode', `electric-pair-mode', and C-M-*
sexp-based movement.

* lisp/gnus/message.el (message--syntax-propertize): New function.
(message-mode): Set syntax-related vars.
(message-smileys): New variable.

* test/automated/message-mode-tests.el: New file
2015-04-12 13:29:05 +01:00
Artur Malabarba
3ba6b3a9c1 Speed up byte-compilation and autoload generation by avoiding mode-hooks
This prevents emacs-lisp-mode-hook from being run everytime an
autoload file is generated, which can account for a fraction of
package installation time depending on the hooks the user has
configured.

* lisp/emacs-lisp/bytecomp.el (byte-compile-file): Use delay-mode-hooks.

* lisp/emacs-lisp/autoload.el (autoload-find-file)
(autoload-find-generated-file): Use delay-mode-hooks.
2015-04-12 03:57:59 +01:00
Artur Malabarba
50ddc67739 * lisp/emacs-lisp/package.el: Improve `package-menu-refresh'
(package-menu-refresh): Respect async and do new package checking.
(list-packages): Use `package-menu-refresh' instead of repeating code.
2015-04-12 03:57:58 +01:00
Artur Malabarba
6f87b180dd * lisp/emacs-lisp/package.el: Improve package-menu-quick-help
(package--quick-help-keys): New variable.
(package--prettify-quick-help-key): New function.
(package-menu-quick-help): Use it.
2015-04-12 03:09:50 +01:00
Artur Malabarba
357edb4e89 * lisp/emacs-lisp/package.el: Fix initially wrong compat table
(package--build-compatibility-table): require finder
2015-04-12 02:33:29 +01:00
Artur Malabarba
ba273b6185 * lisp/emacs-lisp/package.el: Silence async operations
(package--silence): New variable.
(package--message): New function.

(package-import-keyring, package-refresh-contents)
(package-compute-transaction, package-install, package-delete)
(package-menu--perform-transaction, package-menu-execute): Use it.
2015-04-12 01:52:43 +01:00
Daiki Ueno
ccade56fbe Utilize `make-process' in epg.el
* lisp/epg.el (epg-error-output): Abolish.
(epg-context): New slot `error-buffer'.
(epg--start): Use `make-process' and `make-pipe-process'.
(epg--process-filter): Remove code separating stderr from stdout.
(epg-wait-for-completion): Simplify `error-output' handling.
(epg-reset): Dispose error buffer.
2015-04-12 07:00:41 +09:00
Chris Zheng
dc79845aac Support GnuTLS v3.4 and later on MS-Windows
* src/gnutls.c (syms_of_gnutls) <libgnutls-version>: New DEFSYM.
* lisp/term/w32-win.el (dynamic-library-alist): Determine which
GnuTLS DLL to load according to value of libgnutls-version.

Fixes: bug#20294

Copyright-paperwork-exempt: yes
2015-04-11 18:06:52 +03:00
Dmitry Gutov
878058df46 Extract ChangeLog entries when committing a directory
* lisp/vc/vc-dispatcher.el (vc-log-edit): Update FIXME comment.

* lisp/vc/log-edit.el (log-edit-changelog-insert-entries):
Add a FIXME comment.
(log-edit-changelog-entries): Extract from
`log-edit-changelog-entries', handle FILE being a directory
(http://lists.gnu.org/archive/html/emacs-devel/2015-04/msg00555.html).
2015-04-11 07:09:56 +03:00
Daiki Ueno
f55ea05bdf Add facility to collect stderr of async subprocess
* src/w32.h (register_aux_fd): New function declaration.
* src/w32.c (register_aux_fd): New function.
* src/process.h (struct Lisp_Process): New member stderrproc.
* src/process.c (PIPECONN_P): New macro.
(PIPECONN1_P): New macro.
(Fdelete_process, Fprocess_status, Fset_process_buffer)
(Fset_process_filter, Fset_process_sentinel, Fstop_process)
(Fcontinue_process): Handle pipe process specially.
(create_process): Respect p->stderrproc.
(Fmake_pipe_process): New function.
(Fmake_process): Add new keyword argument :stderr.
(wait_reading_process_output): Specially handle a pipe process when
it gets an EOF.
(syms_of_process): Register Qpipe and Smake_pipe_process.

* doc/lispref/processes.texi (Asynchronous Processes): Document
`make-pipe-process' and `:stderr' keyword of `make-process'.

* lisp/subr.el (start-process): Suggest to use `make-process' handle
standard error separately.

* test/automated/process-tests.el (process-test-stderr-buffer)
(process-test-stderr-filter): New tests.

* etc/NEWS: Mention new process type `pipe' and its usage with the
`:stderr' keyword of `make-process'.
2015-04-11 07:59:27 +09:00
Stefan Monnier
3638632f0b * abbrev.el (define-abbrev-table): Refine last change. 2015-04-10 02:47:44 -04:00
Stefan Monnier
26f8a38497 cl-lib.el: Partial revert of "2015-04-05 Rationalize c[ad]+r"
* lisp/emacs-lisp/cl-lib.el: Partial revert of "2015-04-05 Rationalize
use of c[ad]+r", so as to keep the "cl-" prefix on all
cl-lib definitions.
2015-04-10 01:50:22 -04:00
Stefan Monnier
5194890891 * vhdl-mode.el (vhdl-prepare-search-2): Use inhibit-point-motion-hooks 2015-04-10 00:20:54 -04:00
Stefan Monnier
ee7df9f0c8 * lisp/cedet/semantic: Remove some dead code
* lisp/cedet/semantic/util-modes.el
(semantic-stickyfunc-header-line-format): Emacs<22 is not supported
any more.
* lisp/cedet/semantic/fw.el (semantic-buffer-local-value): Emacs<21 is
not supported any more.
(semantic-safe): Use `declare'.
* lisp/cedet/semantic/decorate.el (semantic-set-tag-intangible)
(semantic-tag-intangible-p): Remove unused functions.
* lisp/cedet/semantic/complete.el (semantic-displayor-window-edges):
Remove unused function.
2015-04-10 00:17:19 -04:00
Stefan Monnier
d58759a99a * lisp/gnus/gnus-art.el (gnus-hidden-properties): Simplify.
(gnus-article-hide-text, gnus-article-unhide-text)
(gnus-article-unhide-text-type): Remove special handling of
`intangible' since that property is not used any more.
(gnus-article-treat-body-boundary): Use gnus-hidden-properties.
2015-04-10 00:11:04 -04:00
Jay Belanger
36c0acaedd Merge branch 'master' of git.sv.gnu.org:/srv/git/emacs 2015-04-09 19:07:15 -05:00
Dmitry Gutov
0679159c41 Use the VC root in `log-edit-listfun'
* lisp/vc/vc-dispatcher.el (vc-log-edit): Use the VC root in
`log-edit-listfun'.
2015-04-10 03:54:55 +03:00
Jay Belanger
e368697ce3 Fix description of Unix time, mention new function.
* lisp/calc/calc-forms.el (calcFunc-unixtime): Fix adjustment for
Unix time.
* doc/misc/calc.texi (Date Forms): Fix description of Unix time.
(Basic Operations on Units): Mention `calc-convert-exact-units'.
2015-04-09 19:03:19 -05:00
Artur Malabarba
c1daad42c6 * lisp/emacs-lisp/package.el: Use mode-line-process for notification 2015-04-10 00:47:05 +01:00
Dmitry Gutov
2957dd6859 (log-edit-insert-changelog-entries): Don't add newline after the last entry
* lisp/vc/log-edit.el (log-edit-insert-changelog-entries):
Don't add newline after the last entry.
2015-04-10 02:26:58 +03:00
Simen Heggestøyl
e597344849 css-mode.el: Add "not" pseudo-class
Fixes: debbugs:20267

* textmodes/css-mode.el (css-pseudo-class-ids): Add "not" to list
of CSS pseudo-classes.
2015-04-09 21:01:02 +02:00
Boruch Baum
62e7506081 * lisp/bookmark.el (bookmark-bmenu-goto-bookmark): Don't inf-loop.
Fixes: debbugs:20212
2015-04-09 11:07:15 -04:00
Stefan Monnier
beaab89896 Stop messing with the EMACS env var
Fixes: debbugs:20202

* lisp/net/tramp-sh.el (tramp-remote-process-environment):
* lisp/comint.el (comint-exec-1):
* lisp/term.el (term-exec-1): Don't set EMACS envvar.
* lisp/progmodes/compile.el (compilation-start): Same and bring
INSIDE_EMACS's format in line with other users.
2015-04-09 11:01:04 -04:00
Stefan Monnier
6083965958 css-mode.el (css-smie-rules): Fix indentation after complex selectors
Fixes: debbugs:20282

* lisp/textmodes/css-mode.el (css-smie-rules): Don't get confused by
inner structure of selectors.
2015-04-09 10:51:23 -04:00
Fabián Ezequiel Gallina
c9415ccbf8 python.el: Indent docstring lines to base-indent
Fixes: debbugs:19595

Thanks to immerrr <immerrr@gmail.com> for reporting and providing
an initial patch.

* lisp/progmodes/python.el
(python-indent-context): Add :inside-docstring context.
(python-indent--calculate-indentation): Handle :inside-docstring.
(python-indent-region): Re-indent docstrings.

* test/automated/python-tests.el (python-indent-region-5)
(python-indent-inside-string-2): Fix tests.
2015-04-09 01:41:55 -03:00
Fabián Ezequiel Gallina
911ed2eba4 python.el: Increase native completion robustness
Fixes: debbugs:19755

Thanks to Carlos Pita <carlosjosepita@gmail.com> for reporting
this and providing useful ideas.

* lisp/progmodes/python.el
(python-shell-completion-native-output-timeout): Increase value.
(python-shell-completion-native-try-output-timeout): New var.
(python-shell-completion-native-try): Use it.
(python-shell-completion-native-setup): New readline setup avoids
polluting current context, ensures output when no-completions are
available and includes output end marker.
(python-shell-completion-native-get-completions): Trigger with one
tab only.  Call accept-process-output until output end is found or
python-shell-completion-native-output-timeout is exceeded.
2015-04-09 00:53:18 -03:00
Samer Masterson
c44f5b046b * lisp/eshell: Make backslash a no-op in front of normal chars
Fixes: debbugs:8531

* lisp/eshell/esh-arg.el (eshell-parse-argument-hook): Update comment.
(eshell-parse-backslash): Return escaped character after backslash
if it is special.  Otherwise, if the backslash is not in a quoted
string, ignore the backslash and return the character after; if
the backslash is in a quoted string, return the backslash and the
character after.

* test/automated/eshell.el (eshell-test/escape-nonspecial)
(eshell-test/escape-nonspecial-unicode)
(eshell-test/escape-nonspecial-quoted)
(eshell-test/escape-special-quoted): Add tests for new
`eshell-parse-backslash' behavior.
2015-04-08 22:31:51 -04:00
Gustav Hållberg
3d78c5578c (diff-hunk-file-names): Don't require a TAB after the file name
Fixes: debbugs:20276
2015-04-08 21:47:50 -04:00
Gustav Hållberg
0ae9ae36f0 (diff-hunk-file-names): Don't require a TAB after the file name
* lisp/vc/diff-mode.el (diff-hunk-file-names): Don't require a TAB
after the file name (bug#20276).
2015-04-08 21:46:28 -04:00
Stefan Monnier
215e5bf0cf (eieio-copy-parents-into-subclass): Fix inheritance of initargs
Fixes: debbugs:20270

* lisp/emacs-lisp/eieio-core.el (eieio-copy-parents-into-subclass):
Fix inheritance of initargs.
2015-04-08 17:23:50 -04:00
Artur Malabarba
a480a51f24 * lisp/emacs-lisp/package.el (package-menu-mode): Mode-line notification
while dowloading information.
2015-04-08 19:27:45 +01:00
Artur Malabarba
0465c9dd42 * lisp/emacs-lisp/package.el: More conservative `ensure-init-file'
(package--ensure-init-file): Check file contents before visiting.
(package-initialize): Call it.
(package-install-from-buffer, package-install): Don't call it.
2015-04-08 19:18:30 +01:00