Commit graph

77351 commits

Author SHA1 Message Date
Lars Ingebrigtsen
4ad3402fb3 Remove mention of `edebug-on-signal' from a doc string
* lisp/emacs-lisp/edebug.el (edebug-mode): Don't mention
non-existent user option (bug#44577).
2020-11-12 13:39:40 +01:00
Lars Ingebrigtsen
b21015c9c2 Clarify project-find-file doc string
* lisp/progmodes/project.el (project-find-file): Don't say
anything about recognizing file names, as that may lead the user
to think that it'll check whether the string at point is an
existing file (bug#44588).
2020-11-12 13:36:19 +01:00
Juri Linkov
1ac47aac08 Add help-form to the cache key in read-char-from-minibuffer 2020-11-12 09:38:21 +02:00
Stefan Kangas
4e94267042 Remove redundant installation instructions
* lisp/net/newsticker.el:
* lisp/net/sieve-mode.el:
* lisp/play/bubbles.el:
* lisp/play/handwrite.el:
* lisp/progmodes/python.el:
* lisp/progmodes/ruby-mode.el:
* lisp/whitespace.el: Remove redundant installation instructions.
These packages are distributed with Emacs and/or GNU ELPA.
* lisp/calendar/timeclock.el:
* lisp/ehelp.el:
* lisp/emacs-lisp/checkdoc.el:
* lisp/filesets.el:
* lisp/mail/reporter.el:
* lisp/net/rfc2104.el:
* lisp/net/webjump.el:
* lisp/pixel-scroll.el: Remove redundant recommendation to call
require before using autoloaded functions.
* lisp/tar-mode.el: Remove reference to package uncompress, removed in
Emacs 23.
2020-11-12 03:12:35 +01:00
Stefan Kangas
af3edb3be9 * lisp/progmodes/ruby-mode.el (auto-mode-alist): Add Brewfile. 2020-11-12 02:58:02 +01:00
Juri Linkov
73536ffecb Use cache with help-char in read-char-from-minibuffer unless help-form is nil 2020-11-12 03:38:44 +02:00
Juri Linkov
17894ef565 In dired-query use read-char-from-minibuffer with bound help-char (bug#42708)
* lisp/dired-aux.el (dired-query): Replace read-char-choice call
with read-char-from-minibuffer.

* lisp/subr.el (read-char-choice): Restore the previous version
that uses read-key.
(read-char-from-minibuffer): Bind help-char to help-form-show
when help-form is non-nil.
2020-11-11 21:18:31 +02:00
Eric Abrahamsen
3e07b871c4 Remove unused "internal" gnus-search variables
* lisp/gnus/gnus-search.el (gnus-search-memo-query,
gnus-search-memo-server): No longer needed.
2020-11-11 10:36:51 -08:00
Eric Abrahamsen
d22a914c79 Fix defgeneric name of gnus-search-index(ed)-extract
* lisp/gnus/gnus-search.el (gnus-search-indexed-extract): Had the
wrong name on the generic.
2020-11-11 10:35:20 -08:00
Dario Gjorgjevski
e7b4f465e8 Fix python-font-lock-keywords-maximum-decoration performance regression
* lisp/progmodes/python.el
(python-font-lock-keywords-maximum-decoration): `symbol-name'
should not be quantified by a `+' as it is redundant and performs
very badly (bug#44572).
2020-11-11 12:27:59 +01:00
Lars Ingebrigtsen
daecf6d210 Remove mention of global-cedet-m3-minor-mode
* lisp/cedet/semantic.el (semantic-submode-list):
(semantic-default-submodes): Remove mention of
global-cedet-m3-minor-mode, which no longer exists, apparently
(bug#44565).
2020-11-11 10:59:47 +01:00
Dario Gjorgjevski
296e4dd15e Fix font lock of assignments with type hints in Python
* lisp/progmodes/python.el
(python-font-lock-keywords-maximum-decoration): Fix regular
expressions for font lock of assignments with type hints (bug#44568).

The font lock of assignments with type hints in Python is rather bad.
Consider the following example:

    from typing import Mapping, Tuple, Sequence
    var1: int = 5
    var2: Mapping[int, int] = {10: 1024}
    var3: Mapping[Tuple[int, int], int] = {(2, 5): 32}
    var4: Sequence[Sequence[int]] = [[1], [1, 2], [1, 2, 3]]
    var5: Sequence[Mapping[str, Sequence[str]]] = [
        {
            'red': ['scarlet', 'vermilion', 'ruby'],
            'green': ['emerald green', 'aqua']
        },
        {
            'sword': ['cutlass', 'rapier']
        }
    ]

As things stand right now, only ‘var1’ would be highlighted.  To make
things worse, the ‘Mapping’ type hint of ‘var2’ would also be
highlighted, which is entirely incorrect.

This commit makes all of ‘var1’ through ‘var5’ be highlighted
correctly.
2020-11-11 10:49:04 +01:00
Stefan Monnier
f2bb5747f0 * lisp/server.el: Refactor frame creation functions
(server--create-frame): New function, extracted from
`server-create-dumb-terminal-frame`.
(server-create-window-system-frame, server-create-tty-frame):
(server-create-dumb-terminal-frame): Use it.
2020-11-10 23:26:28 -05:00
Eliza Velasquez
47f33e6cb0 * lisp/server.el: Fix frame creation on dumb terminals (bug#25547)
(server-create-dumb-terminal-frame): New function.
(server-process-filter): Use it.
(server-delete-client): Don't delete tty terminal when it's not
exclusive to this client.
2020-11-10 22:14:03 -05:00
Juri Linkov
79d04ae13f Don't set file name variable in org-element-parse-secondary-string (bug#44524)
* lisp/org/org-element.el (org-element-parse-secondary-string):
Don't set buffer-local variables buffer-file-name and buffer-file-truename
in temporary buffer.
2020-11-10 21:27:37 +02:00
Juri Linkov
b0f6b83357 * lisp/leim/quail/compose.el ("iso-transl"): New input method.
* doc/emacs/basic.texi (Inserting Text):
Mention transient input method "iso-transl".

* lisp/leim/quail/latin-ltx.el: Use same Keywords as in other quail files.
2020-11-10 21:21:18 +02:00
Dmitry Gutov
bce0055265 Clear the vc-state cache when returning nil
* lisp/vc/vc-hg.el (vc-hg-registered):
Clear the vc-state cache when returning nil.
2020-11-10 18:08:13 +02:00
Tom Fitzhenry
b5b0f07b0a Remove extra process call from vc-hg-registered
Prefer vc-state to benefit from its caching (bug#44534)

This same technique is used in vc-git.el,
per commit 2018-06-28 "Remove extra process call from vc-git-find-file-hook"
93c41ce6aa.

* lisp/vc/vc-hg.el (vc-hg-registered): Use vc-state rather than vc-hg-state.
2020-11-10 17:42:54 +02:00
Steven Allen
515791ae8a Only use nbutlast when we actually want to modify the original list
* lisp/net/tramp-gvfs.el (tramp-gvfs-dbus-byte-array-to-string):
Don't modify the byte array.
* lisp/net/tramp-integration.el (tramp-eshell-directory-change):
Don't modify the underlying exec-path.
2020-11-10 10:02:15 +01:00
Andrew G Cohen
ee11a68320 Remove ephemeral group on error or null result
* lisp/gnus/nnselect.el (nnselect-request-group): If an ephemeral
group is empty, there is nothing to see, so remove the group.
(nnselect-run): Catch and return an empty artlist on error.
2020-11-10 08:19:43 +08:00
Alan Mackenzie
ae3904bb5d CC Mode: fix many compiler warnings which would appear with lexical binding
* lisp/progmodes/cc-align.el (three places) prefix langelem with a _.

* lisp/progmodes/cc-{cmds,engine}.el: Remove superfluous local variables.

* lisp/progmodes/cc-defs.el (c-will-be-unescaped): Remove unused parameter
end.
* lisp/progmodes/cc-engine.el (c-looking-at-decl-block): Remove unused
parameter containing-sexp.
(c-looking-at-special-brace-list); Remove unused parameter lim.
(c-add-class-syntax): Remove unused parameter paren-state.
2020-11-09 21:19:19 +00:00
Brian Leung
916eb895d1 shortdoc: prefer seq-contains-p over seq-contains
* lisp/emacs-lisp/shortdoc.el (sequence): use seq-contains-p instead
of seq-contains, which is obsolete as of 27.1.  (Bug#44536)

Copyright-paperwork-exempt: yes
2020-11-09 21:19:10 +01:00
Stefan Kangas
95c04675ab Simplify getting value of text-quoting-style (Bug#44471)
* src/doc.c (text_quoting_style): Remove function by merging it...
(Ftext_quoting_style): ...here.  Rename from Fget_quoting_style.
(syms_of_doc): Update defsubr for Ftext_quoting_style.
* src/lisp.h (enum text_quoting_style): Remove enum.
* src/doprnt.c (doprnt):
* src/editfns.c (styled_format):
* lisp/help.el (substitute-command-keys): Update callers to use
text-quoting-style.
2020-11-09 21:08:28 +01:00
Philipp Stephani
a08320f723 * lisp/disp-table.el (make-glyph-code): Remove obsolete comment. 2020-11-09 18:15:51 +01:00
Mattias Engdegård
575b0681d9 Fix pcase rx form snag with '?' and '??' (bug#44532)
This is a regression from Emacs 26.
Reported by Phillip Stephani.

* lisp/emacs-lisp/rx.el (rx--pcase-transform): Process ? and ?? correctly.
* test/lisp/emacs-lisp/rx-tests.el (rx-pcase): Add test case.
2020-11-09 17:28:37 +01:00
Lars Ingebrigtsen
0d9e2b80d8 Make the SHOW parameter work again in `run-python'
* lisp/progmodes/python.el (run-python): Make the SHOW parameter
work again after the fix for 31398 (bug#44421).
2020-11-09 17:21:56 +01:00
Protesilaos Stavrou
1f0b929430 Use a separate face for expanded log-view bodies
* lisp/vc/log-view.el (log-view-commit-body): Define new face.
(log-view-toggle-entry-display): Implement 'log-view-commit-body'
face (bug#44424).
2020-11-09 17:14:24 +01:00
Lars Ingebrigtsen
391260e46c Clarify Lisp warning about elements following other expressions
* lisp/emacs-lisp/lisp-mode.el (lisp-fdefs): Clarify warning in
help text (bug#44482).
2020-11-09 16:50:51 +01:00
Andrii Kolomoiets
b4ec9cf79c NS: Make s-<left/right> to move to beginning/end of line
* lisp/term/ns-win.el: Bind 's-<left>' to 'move-beginning-of-line';
bind 's-<right>' to 'move-end-of-line'.
* etc/NEWS: Mention new bindings.
2020-11-09 14:49:52 +00:00
Harald Jörg
8dc237270f cperl-mode: Indentation of ')' follows customisation
* lisp/progmodes/cperl-mode.el (cperl-style-alist): Add
cperl-close-paren-offset to the settings for PBP style.

* test/lisp/progmodes/cperl-mode-tests.el (cperl-bug19709):
New test to verify correct indentation of closing parentheses (Bug#19709).

* test/lisp/progmodes/cperl-mode-resources/cperl-bug-19709.pl:
New test case with code from the bug report.

* test/lisp/progmodes/cperl-mode-resources/cperl-indent-styles.pl:
Add a new test clause for cperl-close-paren-offset.
2020-11-09 15:25:47 +01:00
Eric Abrahamsen
795b7da16b Add more protections to gnus-search query parsing
* lisp/gnus/gnus-group.el (gnus-group-make-search-group,
gnus-group-read-ephemeral-search-group): If the query is coming in via
the old 'nnir-query-spec key, we know not to parse it.
* lisp/gnus/gnus-search.el (gnus-search-make-query-string): Check if
the query was sent in as '(query "query"), and not '(query . "query).
(gnus-search-imap-search-keys): Add x-gm-raw to imap search keys.
(gnus-search-prepare-query): If we know this query should be raw,
don't even try parsing it, as it probably won't work.
2020-11-08 16:35:19 -08:00
Juri Linkov
74de386a8a * lisp/progmodes/project.el: Don't truncate the saved project list.
* lisp/progmodes/project.el (project--write-project-list):
Let-bind print-length and print-level to nil to not truncate the
saved project list with unreadable ellipsis.
2020-11-08 21:45:02 +02:00
Eric Abrahamsen
33c7ddd47d Another backwards-compatibility fix for gnus-search
* lisp/gnus/gnus-search.el (gnus-search-server-to-engine): Because of
the way we've set up the obsolete variable alias for
`nnir-method-default-engines', we may end up with its value in
`gnus-search-default-engines'. Make the check for "old style" values
general, so we catch them no matter where they came from.
2020-11-08 08:39:19 -08:00
Dmitry Gutov
dcd20a0c51 Doc fix
* lisp/vc/vc.el (vc-deduce-fileset): Doc fix (bug#44420).
2020-11-08 14:29:11 +02:00
Dmitry Gutov
8dab61958d Mention which exact file is already registered
* lisp/vc/vc.el (vc-register):
Mention which exact file is already registered (bug#44420).
2020-11-08 14:02:55 +02:00
Glenn Morris
33e8116fc2 Merge from origin/emacs-27
f5d7fb3a2d (origin/emacs-27) Fix 'uudecode-decode-region-internal' in...
d4242177da Fix 'send-string-to-terminal' writing very long strings
9da0f4026c * lisp/subr.el (read-char-from-minibuffer): Doc fix.  (Bug...
9899f74e4e Merge branch 'emacs-27' of git.savannah.gnu.org:/srv/git/e...
a6fcba783e Fix documentation of 'windmove-swap-states-default-keybind...
f4acd7a924 Split windows evenly when 'min-margins' parameter was set ...
2020-11-07 09:57:56 -08:00
Glenn Morris
6b63b6669d Merge from origin/emacs-27
53933cdf5c ; * lisp/international/mule.el (define-coding-system): Doc...
e90ffcf759 * src/w32fns.c (Fw32_register_hot_key): Doc fix.  (Bug#44456)
89740e9cb5 Prevent redisplay from moving point behind user's back
5932df7435 Document that the :match function for a widget takes an ex...
1b7ab9d0ac Don't render XML declaration of an HTML document (bug#44348)

# Conflicts:
#	lisp/international/mule.el
2020-11-07 09:57:56 -08:00
Eric Abrahamsen
35d9881809 Various fixes and backward compatibility for gnus-search
* lisp/gnus/gnus-group.el (gnus-group-make-search-group,
gnus-group-read-ephemeral-search-group): Check for and accept the old
nnir-* spec keys.
* lisp/gnus/gnus-search.el (shared-initialize): Use
generate-new-buffer instead of doing it ourselves.
(gnus-search-server-to-engine): Raise an informative error explicitly
if we can't find a search engine, rather than letting it fall through
to something less helpful.
(gnus-search-make-spec): Add `gnus-search--complete-key-data' to
`completion-at-point-functions' locally, not globally.
2020-11-07 09:44:10 -08:00
Stefan Monnier
e8f5657bc7 * lisp/emacs-lisp/lisp-mode.el: Avoid false-positive "hidden arg" in strings
(lisp--match-hidden-arg): Don't misfire in strings and comments.

Reported by: Andrii Kolomoiets <andreyk.mad@gmail.com>
2020-11-07 10:15:22 -05:00
Kazuhiro Ito
f5d7fb3a2d Fix 'uudecode-decode-region-internal' in multibyte buffers
* lisp/mail/uudecode.el (uudecode-decode-region-internal): Fix
inserting the decoded string into a multibyte buffer.  Optimize by
working with characters, not strings.  (Bug#44411)

Copyright-paperwork-exempt: yes
2020-11-07 11:40:52 +02:00
Eli Zaretskii
9da0f4026c * lisp/subr.el (read-char-from-minibuffer): Doc fix. (Bug#44451) 2020-11-07 11:10:36 +02:00
Martin Rudalics
f4acd7a924 Split windows evenly when 'min-margins' parameter was set (Bug#44483)
* lisp/window.el (split-window): Make new window inherit any
'min-margins' parameter from WINDOW so that horizontal splits
reliably produce windows of same width (Bug#44483).
2020-11-07 09:20:14 +01:00
Stefan Kangas
ece1e1da5e Delete outdated comment about C rewrite in apropos.el
Maybe it made sense to rewrite apropos.el in C for speed in 1991, but
today the speed increase would not outweigh the maintenance burden.

* lisp/apropos.el: Delete outdated comment.
2020-11-07 08:26:12 +01:00
Stefan Kangas
29af10afe8 Backport: Fix exiting the finder-commentary buffer
Do not merge to master.

* lisp/finder.el (finder-exit): Fix exiting the finder-commentary
buffer.  (Bug#44384)
(finder-buffer): New defconst.
(finder-list-keywords): Use above new defconst.
2020-11-07 02:20:57 +01:00
Mattias Engdegård
b7b9bbb93d Rectify skip-set argument
* lisp/gnus/gnus-search.el (gnus-search-query-end-of-input):
Remove brackets that don't belong.  Found by relint.
2020-11-06 23:02:29 +01:00
Eli Zaretskii
53933cdf5c ; * lisp/international/mule.el (define-coding-system): Doc fix. 2020-11-06 22:13:50 +02:00
Mattias Engdegård
6e9564f09a Fix javac message parsing column number off-by-one
* lisp/progmodes/compile.el (compilation-error-regexp-alist-alist):
'javac': Column numbers are 1-based by default; remove subtraction and
η-reduce.  Translate regexp to rx (mechanised).
* test/lisp/progmodes/compile-tests.el (compile-tests--test-regexps-data):
Adapt 'javac' test cases to the change.
2020-11-06 17:16:00 +01:00
Mattias Engdegård
aea936562b * lisp/gnus/gnus-search.el (gnus-search-contact-tables): Fix type.
A more precise type is desirable but at it is now correct ('list' is not).
2020-11-06 13:55:33 +01:00
Mattias Engdegård
1b9e159525 Change the default value of gdb-mi-decode-strings to t (bug#44173)
This is likely to be a more commonly wanted default value today.

* lisp/progmodes/gdb-mi.el (gdb-mi-decode-strings): Change default.
* doc/emacs/building.texi (Source Buffers): Update manual.
* etc/NEWS: Announce.
2020-11-06 13:55:32 +01:00
Mauro Aranda
527413fb2f Go back to not using custom-push-theme when enabling a theme
* lisp/custom.el (enable-theme): Relying on custom-push-theme to
handle theme settings and prior user settings was a mistake.  The
theme settings haven't changed between loading the theme and enabling
it, so we don't need all of what custom-push-theme does.  However, we
still need to save a user setting outside of Customize, in order to be
able to get back to it, so do that in enable-theme itself.
2020-11-06 09:34:08 -03:00