Commit graph

142686 commits

Author SHA1 Message Date
Andrea Corallo
907618b3b5 Merge remote-tracking branch 'savahnna/master' into HEAD 2020-07-15 23:13:59 +02:00
Andrea Corallo
2c2cc21f1b Add a testcase for bug#42360
* test/src/comp-tests.el (comp-test-42360): New testcase.

	* test/src/comp-test-funcs.el (comp-test-42360-f): New function.
2020-07-15 23:13:36 +02:00
Andrea Corallo
82169a3d97 * Fix bug#42360
* src/comp.c (compile_function): Allocate function frame as array
	if non local exits are present to retain correct Elisp semantic.
	(emit_limple_call_ref): Directly use the frame array for ref calls
	to have GCC spills into it before calling.
2020-07-15 22:40:30 +02:00
Tassilo Horn
85eaa8373b ;Fix eldoc regression bug#42365 2020-07-15 18:58:57 +02:00
Jonas Bernoulli
58bec884d5 * lisp/epa.el (epa-show-key): New command.
Users can move in `epa-key-list-mode' buffers using either
`next-line'/`previous-line' or `widget-forward'/`widget-backward'.
When using the first set of commands, then the cursor stays in the
current column and that normally is the first column.  The key
widgets do not begin until the third character of their respective
lines.

All `epa' commands work regardless of whether the cursor is on the
widget or before them.  The `epa-show-key' command did not exist until
now because the `widget-button-press' already performs its task.  But
because the widgets don't span complete lines we actually need this
command too.
2020-07-15 18:06:04 +02:00
Jonas Bernoulli
8c60347780 epa-key-list-mode-map: Use widget-keymap as parent keymap
Normally when one keymap is to be treated as the parent of another,
then that relationship is setup once at the time when the child is
being defined, i.e. at birth.  For some reason, this was not done
here; instead `widget-keymap' is set as `epa-key-list-mode-map'
parent every time the former is setup to be used as the local map.

This appears to be a mistake.  A few other keymaps use `widget-keymap'
as their parent and in those cases the relationship is established
just once. `epa-key-list-mode-map' is the only exception and because
there is absolutely no indication that that is justified, we remove
this inconsistency.

* lisp/epa.el (epa-key-list-mode-map): Set the parent of this keymap
while defining it.
* lisp/epa.el (epa--list-keys): Do not set the parent of the local
keymap here.
2020-07-15 18:06:04 +02:00
Jonas Bernoulli
9f82622d33 Cosmetic changes to epa libraries
These changes make the code more readable.

* lisp/epa-dired.el (epa-dired-do-decrypt, epa-dired-do-verify)
(epa-dired-do-sign, epa-dired-do-encrypt): Use dolist instead
of while.
* lisp/epa-file.el (epa-file-passphrase-callback-function):
Set just one variable per setq call.
2020-07-15 18:06:04 +02:00
Jonas Bernoulli
e78c15acf6 Drop unnecessary backward compatibility aliases
We can assume that `encode-coding-string' and `decode-coding-string'
are available; they were added in 1997.

* lisp/epa-file.el (epa-file--encode-coding-string)
(epa-file--decode-coding-string): Remove aliases for
encode-coding-string and decode-coding-string.
* lisp/epa-file.el (epa-file-write-region): Use encode-coding-string
instead of removed epa-file--encode-coding-string.
2020-07-15 18:06:04 +02:00
Jonas Bernoulli
0e2af5cc37 Improve and add doc-strings
* lisp/epa-file.el (epa-file-select-keys):
lisp/epa-hook.el (epa-file-name-regexp):
lisp/epa.el (epa-exit-buffer): Improve doc-string.
* lisp/epa-hook.el (epa-file-name-regexp-update): Add doc-string.
2020-07-15 18:06:03 +02:00
Jonas Bernoulli
da6edafcb1 * lisp/epg-config.el (epg-config--make-gpg-configuration): Fix indentation. 2020-07-15 18:06:03 +02:00
Jonas Bernoulli
bb6fe683a2 Add all epa faces to epa-faces Custom group
`epa-validity-face-alist' isn't actually a face but belongs
in that group anyway.

* lisp/epa.el (epa-field-name, epa-field-body)
(epa-validity-face-alist): Add to epa-faces Custom group.
2020-07-15 18:06:03 +02:00
Jonas Bernoulli
c2ef4a13c0 * lisp/epa.el (epa-faces): Move definition.
Previously option `epa-mail-aliases' was the only option that was
defined right after the group `epa-faces' and right before all the
faces.  Now it is defined with all the other options and thus before
the definition of the `epa-faces' group, which it does not belong to.
2020-07-15 18:06:03 +02:00
Andrea Corallo
4c46f8bac0 * Add a simple major mode for coloring LIMPLE in the log buffer
* lisp/emacs-lisp/comp.el (comp-limple-lock-keywords): New const.
	(comp-limple-mode): New major mode.
	(comp-log-to-buffer): Enable `comp-limple-mode' in the log buffer.
2020-07-15 09:34:16 +02:00
Juri Linkov
363f1d4d5e Improve display of composed character names in "C-u C-x =" on GUI frames
* lisp/descr-text.el (describe-char): On GUI frames, display the
Unicode names of really composed characters only (Bug#42256)
2020-07-15 02:19:49 +03:00
Basil L. Contovounesios
36e6019034 Consistently stylize eldoc as ElDoc in more prose
This fixes new occurrences of "Eldoc" since emacs-27.

* doc/lispref/modes.texi (Major Mode Conventions):
* etc/NEWS:
* lisp/descr-text.el (describe-char-eldoc):
* lisp/emacs-lisp/eldoc.el (eldoc-echo-area-use-multiline-p)
(eldoc-prefer-doc-buffer, eldoc--documentation-strategy-defcustom):
Consistently capitalize eldoc as ElDoc rather than Eldoc in
documentation and commentary.
2020-07-14 13:49:34 +01:00
Juri Linkov
7b0216fbc0 Improve documentation of "C-u C-x ="
* doc/emacs/mule.texi (International Chars): Update the
composition information displayed by "C-u C-x =".  (Bug#42256)
2020-07-14 03:12:06 +03:00
Andrea Corallo
5be335e6b5 Merge remote-tracking branch 'savahnna/master' into HEAD 2020-07-13 15:13:46 +02:00
Andrea Corallo
eb091c8647 * Rename comp-propagate' into fw-prop'
* lisp/emacs-lisp/comp.el (comp-passes): Rename `comp-propagate'
	-> `comp-fwprop'.
	(comp-fwprop-prologue): Rename from `comp-propagate-prologue'.
	(comp-fwprop-insn): Rename from `comp-fwprop-insn'.
	(comp-propagate*): Rename from `comp-propagate*' and update.
	(comp-fwprop): Rename from `comp-propagate' and update.
2020-07-13 14:44:29 +02:00
Andrea Corallo
36c289ec8b * Clean-up now unnecessary backward propagation in comp.el
* lisp/emacs-lisp/comp.el (comp-passes): Invoke 'comp-propagate'
	instead of 'comp-propagate-alloc'.
	(comp-mvar): Remove unnecessary `array-idx' slot.
	(comp-propagate-prologue): Remove.
	(comp-propagate-prologue): Remove `backward' parameter and
	backward propagation logic.
	(comp-propagate1): Remove and move logic into `comp-propagate'.
	(comp-propagate-alloc): Remove pass.
2020-07-13 14:40:07 +02:00
Andrea Corallo
527b697b2a * Rework frame allocation strategy
All frame slots are now simple automatic variables given the array
allocation and fill is done in 'emit_limple_call_ref'.

	* src/comp.c (comp_t): Remove 'f_frame' 'arrays' slots, add
	'frame'.
	(emit_mvar_lval): Simplify to make use of 'comp.frame'.
	(compile_function): Clean-up and add comp.frame initialization.
2020-07-13 14:34:45 +02:00
Andrea Corallo
c389feede5 * Rework the backend to allocate arument arrays for call by references
* src/comp.c (comp_t): Add 'zero' field.
	(emit_limple_call_ref): Allocate an array to host the parametes
	and generate the code moving values into.
	(Fcomp__init_ctxt): Initialize comp.zero.
2020-07-13 14:32:04 +02:00
Juri Linkov
46a0c115f0 Display "C-u C-x =" composed character names on GUI frames as well
* lisp/descr-text.el (describe-char): On GUI frames, display the
Unicode names of the composed characters like they are displayed
on TTY frames.  (Bug#42256)
2020-07-13 02:33:02 +03:00
Eli Zaretskii
0339325d53 ;* lisp/progmodes/project.el (project-current): Doc fix. 2020-07-12 21:48:39 +03:00
Dmitry Gutov
96173fbfab ; Roll back certain doc changes; clarify what "transient" is 2020-07-12 20:55:23 +03:00
James N. V. Cash
7a712578ed Fix a typo in eldoc.el
* lisp/emacs-lisp/eldoc.el (eldoc-documentation-functions): Fix a
typo.  (Bug#42310)

Copyright-paperwork-exempt: yes
2020-07-12 17:10:32 +03:00
Eli Zaretskii
f5bc508be5 Fix last doc changes in project.el
* lisp/progmodes/project.el (project-find-functions)
(project-current): Add back information which was recently
removed.
2020-07-12 16:57:40 +03:00
João Távora
45d7db6d22 Sort out ElDoc backward compatibility of eldoc-documentation-function
As explained previously, we can't simply make
eldoc-documentation-function an variable alias for
eldoc-documentation-strategy, because ElDoc is pre-loaded in Emacs <
28, where it holds at least one buffer-local binding.  So if eldoc.el
is loaded in those versions, we do the variable alias binding in
reverse.  We do this using a macro
eldoc--documentation-strategy-defcustom to at load time in which
direction to make the variable alias.

* lisp/emacs-lisp/eldoc.el
(eldoc--documentation-strategy-defcustom): Helper macro.
(eldoc-documentation-strategy, eldoc-documentation-function): Use it.
(Version): Bump to 1.5.0
2020-07-12 14:24:05 +01:00
Michael Albinus
7ee32966a9 More Tramp code cleanup
* lisp/net/tramp.el (tramp-process-actions):
* lisp/net/tramp-adb.el (tramp-adb-handle-file-system-info)
(tramp-adb-handle-set-file-times)
(tramp-adb-maybe-open-connection):
* lisp/net/tramp-cmds.el (tramp-rename-files, tramp-rename-these-files)
(tramp-reporter-dump-variable):
* lisp/net/tramp-sh.el (tramp-do-file-attributes-with-stat)
(tramp-sh-handle-file-selinux-context)
(tramp-do-directory-files-and-attributes-with-stat)
(tramp-sh-handle-file-name-all-completions)
(tramp-sh-handle-write-region)
(tramp-sh-handle-file-notify-add-watch)
(tramp-sh-gvfs-monitor-dir-process-filter)
(tramp-sh-inotifywait-process-filter)
(tramp-sh-handle-file-system-info, tramp-find-executable)
(tramp-open-shell, tramp-find-shell):
* lisp/net/tramp-smb.el (tramp-smb-do-file-attributes-with-stat)
(tramp-smb-handle-file-system-info):
* lisp/net/tramp-sudoedit.el (tramp-sudoedit-handle-file-selinux-context)
(tramp-sudoedit-handle-file-system-info): Remove superfluous
`eval-when-compile', `concat' creates the string during byte
compilation.  Reported by Mattias Engdegård <mattiase@acm.org>.

* lisp/net/tramp-adb.el (tramp-adb-prompt): Simplify.
(tramp-adb-send-command):
* lisp/net/tramp-gvfs.el (tramp-gvfs-dbus-string-to-byte-array):
Use `string-match-p'.

* lisp/net/tramp-sh.el (tramp-sunos-unames): New defconst.
(tramp-find-executable, tramp-find-shell, tramp-get-remote-stat): Use it.
2020-07-12 15:02:56 +02:00
Dmitry Gutov
4a467f7591 project-kill-buffers: Update the docstring too
* lisp/progmodes/project.el (project-kill-buffers):
Copy a sentence over from project-switch-to-buffer.
2020-07-12 03:46:37 +03:00
Dmitry Gutov
ebcbd50c53 More docstring updates in project.el
* lisp/progmodes/project.el (project-find-functions)
(project-current, project-switch-to-buffer):
More docstring updates.
2020-07-12 03:39:16 +03:00
Glenn Morris
e6e5ce3561 ; Merge from origin/emacs-27
The following commits were skipped:

bdf716bba1 (origin/emacs-27) Correct 'concat' manual entry (bug#42296)
b1ad0380d2 * doc/misc/flymake.texi (An annotated example backend): Ty...
2020-07-11 09:25:04 -07:00
Glenn Morris
398a268061 Merge from origin/emacs-27
c04b92104c Add commentary in gtkutil.c
6290850dac Consistently stylize eldoc as ElDoc in prose
136e931189 Improve documentation of "C-u C-x ="
1f52771fd3 Mention floating rounding issues
c892ae65b4 Repair global-auto-revert-ignore-modes (bug#42271)
3a446a02fb ; * src/xdisp.c (decode_mode_spec): Fix commentary.
79f381b4a6 One more improvement of left/right-fringe display spec docs
1279bdb072 Another clarification of left/right-fringe display spec

# Conflicts:
#	doc/emacs/programs.texi
2020-07-11 09:25:04 -07:00
Mattias Engdegård
bdf716bba1 Correct 'concat' manual entry (bug#42296)
* doc/lispref/strings.texi (Creating Strings): 'concat' does not
necessarily return a newly allocated string.  This has been the case
at least since 1997 (Emacs 20.3).
2020-07-11 15:15:24 +02:00
Mattias Engdegård
6cc35829e4 Correct 'concat' manual entry (bug#42296)
* doc/lispref/strings.texi (Creating Strings): 'concat' does not
necessarily return a newly allocated string.  This has been the case
at least since 1997 (Emacs 20.3).
2020-07-11 15:13:18 +02:00
Michael Albinus
af4f3a873f Fix multibyte chars of file names in tramp-adb.el
* lisp/net/tramp-adb.el (tramp-adb-execute-adb-command): Revert return
value meaning.  Insert the result into the connection buffer.
(tramp-adb-handle-file-local-copy)
(tramp-adb-handle-write-region, tramp-adb-handle-copy-file)
(tramp-adb-get-device): Adapt calls.
(tramp-adb-send-command): Use "adb shell ..." in case the command
contains multibyte chars.

* test/lisp/net/tramp-tests.el (tramp--test-utf8): Extend test.
2020-07-11 14:46:18 +02:00
Eli Zaretskii
e9e3b6cd22 Merge branch 'master' of git.savannah.gnu.org:/srv/git/emacs 2020-07-11 15:35:43 +03:00
Eli Zaretskii
d8e17a4c4e Another minor improvement of project.el doc strings
* lisp/progmodes/project.el (project-find-functions)
(project-current, project-switch-to-buffer): Doc fix.
(project-current): Rename the argument DIR to DIRECTORY.
2020-07-11 15:33:51 +03:00
Andrea Corallo
b1ad0380d2 * doc/misc/flymake.texi (An annotated example backend): Typo fix. 2020-07-11 11:25:51 +01:00
Andrea Corallo
205abbfb68 * doc/misc/flymake.texi (An annotated example backend): Typo fix. 2020-07-11 11:14:58 +01:00
Eli Zaretskii
c04b92104c Add commentary in gtkutil.c
* src/gtkutil.c: Add a comment regarding the incompatibilities
vis-a-vis GTK.  Suggested by Richard Stallman <rms@gnu.org>.
2020-07-11 12:47:26 +03:00
Dmitry Gutov
86c860f1a1 project-switch-to-buffer: Reword the docstring
* lisp/progmodes/project.el (project-switch-to-buffer):
Reword the docstring, copying the style from project-kill-buffers.
2020-07-11 04:39:58 +03:00
João Távora
1198b03e55 Fix placement of Eldoc docs during eval-expression (bug#42309)
* lisp/emacs-lisp/eldoc.el (eldoc--handle-docs): Rework.
2020-07-10 21:23:33 +01:00
João Távora
c2599632b0 Revert "Fix Eldoc problem when loading on Emacs 26.3"
This reverts commit 9ade7ea7b7.

* lisp/emacs-lisp/eldoc.el (Version): Bump to 1.4.0
2020-07-10 18:12:10 +01:00
Basil L. Contovounesios
6290850dac Consistently stylize eldoc as ElDoc in prose
* doc/emacs/custom.texi (Specifying File Variables):
* doc/emacs/modes.texi (Major Modes):
* doc/emacs/programs.texi (Lisp Doc):
* etc/NEWS.22:
* etc/NEWS.23:
* lisp/progmodes/python.el:
(python-eldoc-function):
* test/lisp/progmodes/python-tests.el: Consistently capitalize eldoc
as ElDoc rather than Eldoc.
2020-07-10 15:22:27 +01:00
Michael Albinus
7caf570662 Tramp code cleanup
* lisp/net/tramp.el (tramp-shell-prompt-pattern)
(tramp-wrong-passwd-regexp, tramp-method-regexp-alist)
(tramp-domain-regexp, tramp-host-regexp, tramp-ipv6-regexp)
(tramp-port-regexp, tramp-debug-outline-regexp)
(tramp-drop-volume-letter, tramp-parse-shostkeys)
(tramp-handle-file-name-case-insensitive-p):
* lisp/net/tramp-adb.el (tramp-adb-send-command-and-check):
* lisp/net/tramp-ftp.el (tramp-ftp-enable-ange-ftp):
* lisp/net/tramp-gvfs.el (tramp-gvfs-monitor-process-filter):
* lisp/net/tramp-sh.el (tramp-display-escape-sequence-regexp)
(tramp-device-escape-sequence-regexp):
* lisp/net/tramp-smb.el (tramp-smb-do-file-attributes-with-stat)
(tramp-smb-handle-set-file-acl, tramp-smb-read-file-entry):
* lisp/net/tramp-sudoedit.el (tramp-sudoedit-handle-file-selinux-context):
Use character classes in regexp.

* lisp/net/tramp-adb.el (tramp-adb-ls-date-year-regexp)
(tramp-adb-ls-date-time-regexp): New defconst.
(tramp-adb-ls-date-regexp, tramp-adb-ls-toolbox-regexp)
(tramp-adb-sh-fix-ls-output): Use them.
(tramp-adb-handle-set-file-times, tramp-adb-maybe-open-connection):
Apply `eval-when-compile' on constant concat data.
(tramp-do-parse-file-attributes-with-ls):
Suppress `signal-hook-function'.
(tramp-adb--gnu-switches-to-ash): Remove unused function.
(tramp-adb-handle-set-file-modes): Qhote argument.
(tramp-adb-maybe-open-connection): Set file property rather than flush.

* lisp/net/tramp-cmds.el (tramp-rename-these-files):
Apply `eval-when-compile' on constant concat data.

* lisp/net/tramp-gvfs.el (tramp-gvfs-file-attributes)
(tramp-gvfs-file-attributes-with-gvfs-ls-regexp): Embed them in
`eval-and-compile'.
(tramp-gvfs-get-directory-attributes): Apply `eval-when-compile'
on constant concat data.
2020-07-10 10:45:14 +02:00
João Távora
62725e87f2 Fix byte compilation warning in Eldoc
* lisp/emacs-lisp/eldoc.el (eldoc-documentation-function): Pass nil as
second argument.
2020-07-10 08:13:15 +01:00
João Távora
9ade7ea7b7 Fix Eldoc problem when loading on Emacs 26.3
When defining the obsolete variable alias for old
eldoc-documentation-function (which now points to the newer
eldoc-documentation-strategy), one gets the error "don't know how to
make a localized vareiable an alias".  I'm not sure, but I suspect
this is because Eldoc is preloaded in Emacs 26.3 and the
eldoc-documentation-function variable is already set locally by some
Elisp buffer.

Uninterning the symbol shortly before defining the alias seems to fix
it.

* lisp/emacs-lisp/eldoc.el (eldoc-documentation-function):
Unintern on load.
(Version): Bump to 1.3.0
2020-07-10 01:47:33 +01:00
Paul Eggert
c86f3fe0d0 Fix out-of-source ‘make check’ emacs-module-tests
Problem reported by Koki Fukuda in:
https://lists.gnu.org/r/emacs-devel/2020-07/msg00169.html
* test/Makefile.in (MODULE_CFLAGS):
Include from the same directories included from in ../src.
* test/src/emacs-module-tests.el (module/describe-function-1):
Strip path to source directory.
2020-07-09 16:38:45 -07:00
Paul Eggert
c8b6006d82 Use Gnulib libgmp module
Instead of doing GMP by hand, use the Gnulib libgmp module.
* .gitignore: Add lib/gmp.h.
* admin/merge-gnulib (GNULIB_MODULES): Add libgmp.
* configure.ac (GMP_LIB, GMP_OBJ): Remove.  Gnulib uses the name
LIB_GMP, so all uses changed.  All uses of GMP_OBJ removed.
(HAVE_GMP): Set this from Gnulib’s variables.
* lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
* lib/mini-gmp-gnulib.c, lib/mini-gmp.c, lib/mini-gmp.h, m4/libgmp.m4:
New files, copied from Gnulib.
* src/bignum.h, test/data/emacs-module/mod-test.c:
Include gmp.h unconditionally.
* src/mini-gmp-emacs.c, src/mini-gmp.c, src/mini-gmp.h:
Remove.  This moves these files from src to lib, and
updates them to the current GMP version.
* test/Makefile.in (GMP_H): New macro.
($(test_module)): Use it to decide whether to compile
mini-gmp-gnulib.c too.
2020-07-09 16:38:45 -07:00
Paul Eggert
501306557c Speed up GCC 10.1 compilation in default Git builds
* configure.ac (nw): GCC 10.1 introduced warnings enabled by -fanalyzer
that slow down compilation considerably.  Generate these warnings only
if --enable-gcc-warnings is explicitly given.  Also, do not bother to
eliminate warnings that Gnulib’s revised manywarnings module no longer
generates.
2020-07-09 16:38:44 -07:00