1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-04 19:10:37 -08:00
Commit graph

135763 commits

Author SHA1 Message Date
Alexander Gramiak
b68405405e Introduce new defcustom for terminal CUA rectangle commands
This allows a user to set a non-meta modifier for their terminal
should his/her terminal support it. See bug#35058 for background on
this change.

* lisp/emulation/cua-base.el (cua-rectangle-terminal-modifier-key):
New defcustom.

* lisp/emulation/cua-base.el (cua--shift-control-x-prefix): Use new
defcustom.
2019-04-06 22:43:59 -06:00
Alexander Gramiak
cffc04c48d Define and use new procedure display-symbol-keys-p
* lisp/frame.el (display-symbol-keys-p): Define.

* lisp/simple.el (normal-erase-is-backspace-setup-frame): Use eq
instead of memq.
(normal-erase-is-backspace-mode): Use display-symbol-keys-p.
2019-04-06 22:43:59 -06:00
Alexander Gramiak
c6ea522de6 Define and use new alias display-blink-cursor-p
display-graphic-p is not used in this case because it may be possible
in the future for terminals to allow control over cursor blinking. For
details, see bug#35058.

* lisp/frame.el (blink-cursor-mode): Use display-blink-cursor-p.
2019-04-06 22:43:59 -06:00
Alexander Gramiak
8f6e479845 Use display-graphic-p and display-multi-frame-p in more cases
* lisp/disp-table.el:
* lisp/faces.el:
* lisp/frame.el:
* lisp/info.el (Info-fontify-node):
* lisp/window.el (handle-select-window): Use display-graphic-p and
  display-multi-frame-p instead of explicit memq calls.
2019-04-06 22:43:59 -06:00
Basil L. Contovounesios
08235af38c Distinguish buttons from widgets (bug#34506)
* lisp/button.el (button-at):
* lisp/wid-edit.el (widget-at): Avoid returning a false positive
when looking for a button and finding a widget, or vice versa.
* test/lisp/button-tests.el:
* test/lisp/wid-edit-tests.el: New files.
2019-04-07 03:56:27 +01:00
Stefan Monnier
43f4c7ddd2 * src/buffer.c (Fget_buffer_create): Apply booleans's eta-reduction 2019-04-06 18:54:31 -04:00
Stefan Monnier
7e4d4c069c * lisp/subr.el (setq-default): Fix thinko
Reported by Johan Bockgård <bojohan+news@gnu.org>
2019-04-06 18:44:24 -04:00
Glenn Morris
19919e0f32 * doc/misc/tramp.texi (Remote processes): '.' or ',' must follow xref. 2019-04-06 12:57:44 -07:00
Eli Zaretskii
91018cec01 Encode the FILENAME argument of 'file-locked-p'
* src/filelock.c (Ffile_locked_p): Encode the file name,
before passing it to system APIs.  (Bug#35171)
2019-04-06 17:53:30 +03:00
Basil L. Contovounesios
7dc0a06959 Don't leave inhibit_buffer_hooks uninitialized
* src/buffer.c (Fget_buffer_create): Explicitly initialize
inhibit_buffer_hooks. (bug#34847)
2019-04-06 14:35:04 +01:00
Eli Zaretskii
47aae7cfe1 ; * src/w32fns.c (Fw32_read_registry): Doc fix. 2019-04-06 16:16:32 +03:00
Michael Albinus
bcc6468b39 Fix Bug#34847
* lisp/autorevert.el (auto-revert-remove-current-buffer):
Add optional argument BUFFER.
(auto-revert-notify-rm-watch): Remove local hook.
(auto-revert-buffers): Check `buffer-live-p' in time.  (Bug#34847)
2019-04-06 11:36:34 +02:00
Alex Branham
10cd65878c
Update documentation for indent-relative functions
* lisp/indent.el (indent-relative): Document what happens when there
  is no previous nonblank line.
* doc/lispref/text.texi (Relative Indent): Document
  indent-relative-first-indent-point instead of obsolete
  indent-relative-maybe. Fix documentation of which argument from
  'indent-relative' is used.

Bug#34858
2019-04-05 19:48:21 -05:00
Michał Krzywkowski
01dc2da75b Small elide-head.el update
* lisp/elide-head.el (elide-head-headers-to-hide):
Also match https for GPL.  (Bug#34919)
2019-04-05 20:33:07 -04:00
Glenn Morris
652f5d4922 * doc/emacs/emacs.texi (Acknowledgments): Remove duplicate. 2019-04-05 17:03:04 -07:00
Michael Albinus
f2d2227359 Adapt tramp-tests.el
* test/lisp/net/tramp-tests.el (tramp-test30-make-process):
Instrument test.  Adapt check string.
(tramp-test34-explicit-shell-file-name)
(tramp-test43-asynchronous-requests): Skip tests for tramp-adb
with older Emacsen.
2019-04-05 13:27:06 +02:00
Konstantin Kharlamov
051533c6fa Minor cleanup in widget.c
* src/widget.c (update_wm_hints): Remove variables that are
always zero, and simplify all expressions which used them.
(Bug#35062)
2019-04-05 10:15:46 +03:00
Konstantin Kharlamov
3187efe713 Minor cleanup in gtkutil.c
* src/gtkutil.c (x_wm_set_size_hint): Remove variables that
are always zero, and simplify all expressions which used
them.  (Bug#35062)
2019-04-05 10:01:58 +03:00
Katsumi Yamaoka
9da8f22de0 Make `move article' work again (bug#33653)
* lisp/gnus/gnus-sum.el (gnus-summary-move-article): Back to while loop
m dolist that blocks nov and active from saving (bug#33653).
2019-04-05 04:25:06 +00:00
Glenn Morris
a68c968632 ; Fix copyright years 2019-04-04 20:41:02 -04:00
Troy Hinckley
905f619519 Don't check comp-buffer-name-function in derived mode (Bug#34956)
* lisp/progmodes/compile.el (define-compilation-mode): Remove
'compilation-buffer-name-function' from the list of overridden
variables to ensure that it is not mistaken for a variable that can be
major mode specific.  'compilation-buffer-name-function' is used
before the major mode is loaded, therefore overriding it here is
ineffectual.  Also, the function 'compilation-start' takes an optional
argument name-function, so there is already a mechanism to override
it.
2019-04-04 19:39:42 -04:00
Basil L. Contovounesios
690c678fb6 Fix comment-empty-lines docstring (bug#35152)
* lisp/newcomment.el (comment-empty-lines): Consistently use US
commas in docstring.  Fix indentation of and typo in custom :type.
2019-04-04 23:41:02 +01:00
Stefan Monnier
d63aa2f3e5 * lisp/progmodes/compile.el (compilation-error-regexp-alist): Typo
Reported by Kévin Le Gouguec <kevin.legouguec@gmail.com>
2019-04-04 16:27:29 -04:00
Stefan Monnier
81f64da220 * lisp/desktop.el (desktop--v2s): Add case for defstructs (bug#35131) 2019-04-04 13:46:30 -04:00
Michael Albinus
18c02f7e07 * test/lisp/net/tramp-tests.el (tramp-test43-asynchronous-requests):
Make it fit for tramp-adb.  Apply better check in process filter.
2019-04-04 13:41:53 +02:00
Mauro Aranda
5e55b1b829 Avoid recursive load of eshell
* lisp/eshell/eshell.el: Provide eshell before requiring esh-mode to
avoid a recursive load when esh-mode requires esh-module (which in
turn requires eshell).  (Bug #34954)
The double loading can be noticed by entries in 'eshell-load-hook' or
forms passed to (with-eval-after-load 'eshell ...).
2019-04-03 22:47:10 -04:00
Mauro Aranda
64925714ef Fix repeated 'custom-add-option' in esh-mode.el (Bug#34993)
* lisp/eshell/esh-mode.el: Call 'custom-add-option' with the right
argument.
2019-04-03 22:41:39 -04:00
Michael Albinus
8147d3c27c Work on asynchronous processes for tramp-adb.el
* lisp/net/tramp-adb.el (tramp-adb-handle-make-process):
Simplify.  Remove echoed first line.
(tramp-adb-send-command): Add NEVEROPEN and NOOUTPUT.

* lisp/net/tramp-sh.el (tramp-process-sentinel): Remove.
(tramp-sh-handle-make-process): Simplify.

* lisp/net/tramp.el (tramp-process-sentinel): New defun, taken from
tramp-sh.el.  Delete trailing shell prompt.

* test/lisp/net/tramp-tests.el (tramp-test29-start-file-process)
(tramp-test30-make-process): Run also for tramp-adb.
(tramp-test32-shell-command): Remove tramp-adb restrictions.
(tramp-test34-explicit-shell-file-name): Rework.  Remove :unstable tag.
2019-04-03 21:36:40 +02:00
Glenn Morris
ce9490cb31 * test/lisp/progmodes/flymake-tests.el (different-diagnostic-types):
Expect failure on hydra.nixos.
2019-04-03 15:20:50 -04:00
Eli Zaretskii
2bcf0f097c Improve commentary in 'field_relpos'
* src/pdumper.c (PDUMPER_MAX_OBJECT_SIZE): New macro.
(field_relpos): Use PDUMPER_MAX_OBJECT_SIZE, and comment on
why we require that relpos be not too large.
2019-04-03 20:41:47 +03:00
Eli Zaretskii
b29b79efd9 Restore process-environment after portable dumping
* src/pdumper.c (struct dump_context): New member
old_process_environment.
(Fdump_emacs_portable): Record the original value of
process-environment.
(dump_unwind_cleanup): Restore the original values of
process-environment and post-gc-hook.
2019-04-03 20:30:23 +03:00
Stephen Leake
9df0b8d166 Fix bug in gud-gdb-marker-filter: first marker does not start with \n 2019-04-03 10:25:45 -07:00
Basil L. Contovounesios
0e468a6204 Avoid using obsolete indent-relative-maybe
* lisp/electric.el (electric-indent-functions-without-reindent):
* lisp/indent.el (indent-according-to-mode): Check for
indent-relative-first-indent-point in addition to its obsolete alias
indent-relative-maybe.
* lisp/obsolete/vi.el (vi-com-map): Use
indent-relative-first-indent-point in place of its obsolete alias
indent-relative-maybe.
2019-04-03 17:55:40 +01:00
Stefan Monnier
32e19b2bae * lisp/progmodes/compile.el: Use non-nil values for *-function
(compilation-parse-errors-filename-function,compilation-exit-message-function)
(compilation-process-setup-function, compilation-buffer-name-function):
Give them non-nil default values.
(compilation-buffer-name): Restructure slightly.
(compilation--default-buffer-name): New function, extracted from it.
Use `name-of-mode` instead of `mode-command` to check if the current
buffer is already in the appropriate mode.
2019-04-03 11:24:12 -04:00
Stefan Monnier
3062f81dbf * lisp/progmodes/compile.el: Allow 'line' functions in error-regexp-alist
(compilation-error-properties): Allow 'line' and 'end-line' to be functions,
like 'col' and 'end-col'.
(compilation-error-regexp-alist): Document this.
(compilation-parse-errors): Drop support for old undocumented feature
where 'line' was a function of 2 arguments.
(compilation--compat-error-properties): Delete function.
2019-04-03 10:58:36 -04:00
Glenn Morris
39c0795ef2 ; Copyright years and license copyedits 2019-04-02 21:40:56 -07:00
Noam Postavsky
b36913d803 Allow partial decompression (Bug#33133)
* src/decompress.c (Fzlib_decompress_region): Add optional
ALLOW-PARTIAL parameter.
* lisp/url/url-http.el (url-handle-content-transfer-encoding): Use it.
* doc/lispref/text.texi (Decompression): Document it.
* etc/NEWS: Announce it.
2019-04-02 22:02:32 -04:00
Basil L. Contovounesios
2bd3e48404 * lisp/gnus/gnus-dup.el: Use lexical-binding
(gnus-dup-list-dirty): Add docstring.
(gnus-dup-open): Allocate gnus-dup-hashtb more conservatively now
that it is no longer an obarray.
(gnus-dup-enter-articles): Fix off-by-one error.
(gnus-dup-suppress-articles): DRY.

For discussion, see thread starting at:
https://lists.gnu.org/archive/html/emacs-devel/2019-03/msg00974.html
2019-04-03 02:55:41 +01:00
Wilson Snyder
e25e7d812f Fix verilog-mode vmm statements and AUTOINPUTREG ignores.
* lisp/progmodes/verilog-mode.el (verilog-vmm-statement-re):
Fix vmm statement regexps. Reported by Mattias Engdegard.
(verilog-auto-reg-input)
(verilog-auto-reg-input-assigned-ignore-regexp): For AUTOINPUTREG,
allow ignoring assignments with new
`verilog-auto-reg-input-assigned-ignore-regexp' variable, bug1401.
Reported by David Rogoff.
2019-04-02 20:05:16 -04:00
Paul Eggert
f9ff60e0d7 Improve regexp advice again, and unchain ranges
* doc/lispref/searching.texi (Regexp Special):
Mention char classes earlier, in a more-logical place.
Advise sticking to ASCII letters and digits in ranges.
Reword negative advice to make it clearer that it’s negative.
* lisp/files.el (make-auto-save-file-name):
* lisp/gnus/message.el (message-mailer-swallows-blank-line):
* lisp/gnus/nndoc.el (nndoc-lanl-gov-announce-type-p)
(nndoc-generate-lanl-gov-head):
* lisp/org/org-eshell.el (org-eshell-open):
* lisp/org/org.el (org-deadline-time-hour-regexp)
(org-scheduled-time-hour-regexp):
* lisp/progmodes/bat-mode.el (bat-font-lock-keywords):
* lisp/progmodes/bug-reference.el (bug-reference-bug-regexp):
* lisp/textmodes/less-css-mode.el (less-css-font-lock-keywords):
* lisp/vc/vc-cvs.el (vc-cvs-valid-symbolic-tag-name-p):
* lisp/vc/vc-svn.el (vc-svn-valid-symbolic-tag-name-p):
Avoid attempts to chain ranges, as this can be confusing.
For example, instead of [0-9-_.], use [0-9_.-].
2019-04-02 15:01:34 -07:00
Eli Zaretskii
bb669166ba Fix documentation of last change
* doc/misc/cl.texi (Structures): Document :noinline.

* etc/NEWS: Mark the entry for :noinline as documented.
2019-04-02 20:08:08 +03:00
Stefan Monnier
144b2243b7 * lisp/emacs-lisp/cl-macs.el: Don't always inline struct functions
(cl--struct-inline): New var.
(cl-defstruct): Obey it along with a new :noinline keyword argument.
2019-04-02 12:24:52 -04:00
Stefan Monnier
84616144ca * lisp/subr.el (prog2): Define as a macro
* src/eval.c (Fprog2): Delete function.
(syms_of_eval): Don't register it.

* lisp/emacs-lisp/byte-opt.el (byte-optimize-form-code-walker):
* lisp/emacs-lisp/generator.el (cps--transform-1): Remove `prog2` case.

* lisp/emacs-lisp/bytecomp.el (prog2): Remove handlers.
(byte-compile-prog2): Delete.

* lisp/emacs-lisp/lisp-mode.el (prog2): Remove property.
2019-04-02 10:04:44 -04:00
Michael Albinus
3e8f9482fe Suppress timers in tramp-send-string
* lisp/net/tramp.el (tramp-send-string): Suppress timers.  Use
`with-local-quit'.
2019-04-02 15:17:17 +02:00
Michael Albinus
52e3d3d4c4 Give example for configuration in tramp.texi
* doc/misc/tramp.texi (Configuration): Explain how to call Tramp
configuration functions in the init file.
2019-04-02 10:48:39 +02:00
Paul Eggert
076ed98ff6 More regexp advice and clarifications
* doc/lispref/searching.texi (Regexp Special): Simplify style
advice for order of ], ^, and - in character alternatives.
Stick with saying that it’s not a good idea to put ‘-’ after a
range.  Remove the special case about raw 8-bit bytes and
unibyte characters, as this documentation is confusing and
seems to be incorrect in some cases.  Say that z-a is the
preferred style for reversed ranges, since it’s clearer and is
typically what’s used in practice.  Mention some bad styles:
duplicates in character alternatives, ranges that denote <=3
characters, and ‘-’ as the first character.
2019-04-02 00:18:28 -07:00
Paul Eggert
f81ec28f4f Merge from origin/emacs-26
0924b27bca Say which regexp ranges should be avoided

# Conflicts:
#	doc/lispref/searching.texi
2019-04-01 23:43:57 -07:00
Paul Eggert
f5d3449612 ; Merge from origin/emacs-26
The following commit was skipped:

297a141ca3 ; * lisp/ldefs-boot.el: Update.
2019-04-01 23:40:21 -07:00
Eric Abrahamsen
03ceee0e64 Refactor Gnus group name extraction in group completing read
* lisp/gnus/gnus-group.el (gnus-group-completing-read): Only do the
  unibyte check once; make sure it applies to hash table keys as
  well.
2019-04-01 12:41:36 -07:00
Paul Eggert
74b63d27a6 Make struct Lisp_Objfwd etc. objects read-only
Initialize these objects statically, and make them constants.
This is a bit safer and more efficient.
* src/data.c (XBOOLFWD, XKBOARD_OBJFWD, XFIXNUMFWD, XOBJFWD):
* src/lisp.h (XBUFFER_OBJFWD):
Return a pointer-to-const instead of an unrestricted pointer.
(lispfwd): fwdptr is now a pointer-to-const instead of an
unrestricted pointer.  All uses changed.
(SET_SYMBOL_FWD): Accept pointer-to-const instead of an
unrestricted pointer.
(DEFVAR_LISP, DEFVAR_LISP_NOPRO, DEFVAR_BOOL, DEFVAR_INT)
(DEFVAR_KBOARD): Initialize static structures statically
instead of dynamically, and make them const.
* src/lread.c (defvar_int, defvar_bool, defvar_lisp_nopro)
(defvar_lisp, defvar_kboard): Accept pointer-to-const instead
of an unrestricted pointer; it’s now the caller’s
responsibility to initialize the pointed-to storage.  No need
for a separate address argument any more.  All callers
changed.
2019-04-01 12:02:37 -07:00