]> git.eshelyaron.com Git - emacs.git/log
emacs.git
5 years agoRemove special-casing of tagged pointers.
Philipp Stephani [Fri, 19 Apr 2019 20:51:16 +0000 (22:51 +0200)]
Remove special-casing of tagged pointers.

This partially reverts commit
09b2b8a5ce5b542856f93b645db51eb11cf9855a.

* src/alloc.c (mark_maybe_pointer): Remove special-casing of tagged
pointers.  After commit 09d746dad36e4780d379f975a84b1b076da78c50,
modules no longer rely on tagged pointers.

5 years agoRefactoring: Reduce code duplication
Philipp Stephani [Sat, 19 Jan 2019 22:40:35 +0000 (23:40 +0100)]
Refactoring: Reduce code duplication

* src/emacs-module.c (value_storage_contains_p): New function.
(module_free_global_ref, value_to_lisp): Use it.

5 years agoRemove subsumed regexp branches
Mattias Engdegård [Fri, 19 Apr 2019 20:24:35 +0000 (22:24 +0200)]
Remove subsumed regexp branches

* lisp/progmodes/cc-mode.el (c-before-change-check-unbalanced-strings)
(c-after-change-mark-abnormal-strings): Remove `\r' subsumed by `.'.

5 years agoFix Fload dangling pointer
Paul Eggert [Fri, 19 Apr 2019 19:55:18 +0000 (12:55 -0700)]
Fix Fload dangling pointer

* src/lread.c (Fload): Expand decl’s lifetime to match its use.
Bug found by gcc -fsanitize=address.

5 years agoFix comment and tweak eval_sub
Paul Eggert [Fri, 19 Apr 2019 19:52:57 +0000 (12:52 -0700)]
Fix comment and tweak eval_sub

* src/eval.c (eval_sub): Check whether Fassq returns Qnil,
not whether it returns a cons, as NILP is faster than CONSP
nowadays.  Remove incorrect comment “only original_fun and
original_args have values that will be used below”; instead,
move declarations around so that the set of variables with
useful values is obvious.

5 years agoFix dump_map_file on unusual platforms
Paul Eggert [Fri, 19 Apr 2019 19:38:45 +0000 (12:38 -0700)]
Fix dump_map_file on unusual platforms

* src/pdumper.c (dump_map_file): Fix recently-introduced typo
on platforms that support neither POSIX nor MS-Windows VM.

5 years agoMinor lread.c tweaks
Paul Eggert [Fri, 19 Apr 2019 19:08:40 +0000 (12:08 -0700)]
Minor lread.c tweaks

* src/lread.c (load_warn_unescaped_character_literals):
Use AUTO_STRING to help the GC.
(Fload): Use bool for boolean.

5 years agoClear gnus-group-list when the newsrc-hashtb is recreated
Eric Abrahamsen [Fri, 19 Apr 2019 17:23:19 +0000 (10:23 -0700)]
Clear gnus-group-list when the newsrc-hashtb is recreated

* lisp/gnus/gnus-start.el (gnus-make-hashtable-from-newsrc-alist):
  This routine also happens when re-sorting groups; make sure we're
  clearing the group list.

5 years agoMake warning about unescaped character literals more helpful.
Philipp Stephani [Sat, 2 Jun 2018 09:59:02 +0000 (11:59 +0200)]
Make warning about unescaped character literals more helpful.

See Bug#31676.

* lisp/emacs-lisp/byte-run.el
(byte-run--unescaped-character-literals-warning): New defun.

* src/lread.c (load_warn_unescaped_character_literals): Use new defun.
(syms_of_lread): Define symbol for new defun.

* lisp/emacs-lisp/bytecomp.el (byte-compile-from-buffer): Use new
defun.

* test/src/lread-tests.el (lread-tests--unescaped-char-literals):
test/lisp/emacs-lisp/bytecomp-tests.el
(bytecomp-tests--unescaped-char-literals): Adapt unit tests.

5 years agoRefactoring: simplify definition of some internal variables.
Philipp Stephani [Fri, 19 Apr 2019 16:38:19 +0000 (18:38 +0200)]
Refactoring: simplify definition of some internal variables.

In some cases, we never specbind internal objects, so they don't have
to be symbols.  Rather than using DEFSYM/DEFVAR and then uninterning
the symbols, use plain static variables.  Call staticpro for all of
them, to protect them from the garbage collector.

* src/eval.c (syms_of_eval): Use a static variable for
Qcatch_all_memory_full.

* src/emacs-module.c (syms_of_module): Use static variables for
Vmodule_refs_hash, Vmodule_runtimes, and Vmodule_environments.

5 years agoDon't check for group existence in gnus-group-goto-group
Eric Abrahamsen [Fri, 19 Apr 2019 16:07:59 +0000 (09:07 -0700)]
Don't check for group existence in gnus-group-goto-group

* lisp/gnus/gnus-group.el (gnus-group-goto-group): Just look for the
  string.

5 years agoFix regexp branches that subsume other branches
Paul Eggert [Fri, 19 Apr 2019 16:00:04 +0000 (09:00 -0700)]
Fix regexp branches that subsume other branches

Problems reported by Mattias Engdegård in:
https://lists.gnu.org/r/emacs-devel/2019-04/msg00803.html
* lisp/arc-mode.el (archive-rar-summarize):
* lisp/eshell/em-hist.el (eshell-hist-word-designator):
* lisp/info.el (Info-dir-remove-duplicates):
* lisp/international/ja-dic-cnv.el (skkdic-convert-postfix)
(skkdic-convert-prefix, skkdic-collect-okuri-nasi):
* lisp/progmodes/cc-awk.el (c-awk-esc-pair-re):
* lisp/xml.el (xml-att-type-re):
Omit regexp branches that subsume other branches.
* lisp/progmodes/cperl-mode.el (cperl-beautify-regexp-piece):
$ and ^ aren’t simple-codes.

5 years agoFix mail-extr regexp typo with ".".
Paul Eggert [Fri, 19 Apr 2019 15:23:15 +0000 (08:23 -0700)]
Fix mail-extr regexp typo with ".".

Problem reported by Mattias Engdegård in:
https://lists.gnu.org/r/emacs-devel/2019-04/msg00543.html
* lisp/mail/mail-extr.el (mail-extr-telephone-extension-pattern):
Escape the trailing optional period after an abbreviation.

5 years ago* lisp/net/tramp-adb.el (tramp-adb-prompt): Remove repetition of expression
Michael Albinus [Fri, 19 Apr 2019 14:29:44 +0000 (16:29 +0200)]
* lisp/net/tramp-adb.el (tramp-adb-prompt): Remove repetition of expression

matching an empty string.

5 years agoMerge branch 'master' of git.sv.gnu.org:/srv/git/emacs
Michael Albinus [Fri, 19 Apr 2019 14:29:11 +0000 (16:29 +0200)]
Merge branch 'master' of git.sv.gnu.org:/srv/git/emacs

5 years ago; Minor improvement in documentation from recent commit
Eli Zaretskii [Fri, 19 Apr 2019 12:59:49 +0000 (15:59 +0300)]
; Minor improvement in documentation from recent commit

* doc/lispref/processes.texi (Asynchronous Processes): Say
explicitly that it's an error to pass non-nil value for
:stopped when starting a process.  (Bug#30460)

5 years agoDo not handle :stop in tramp-*-handle-make-process
Michael Albinus [Fri, 19 Apr 2019 12:28:20 +0000 (14:28 +0200)]
Do not handle :stop in tramp-*-handle-make-process

* lisp/net/tramp-adb.el (tramp-adb-handle-make-process):
* lisp/net/tramp-sh.el (tramp-sh-handle-make-process): Do not
handle :stop anymore.

5 years ago; Remove instrumentation in tramp-tests
Michael Albinus [Fri, 19 Apr 2019 12:18:59 +0000 (14:18 +0200)]
; Remove instrumentation in tramp-tests

5 years agoRemove :stop key from make-process.
Philipp Stephani [Fri, 19 Apr 2019 11:03:40 +0000 (13:03 +0200)]
Remove :stop key from make-process.

This has never worked and caused issues such as Bug#30460.

* src/process.c (Fmake_process): Don't accept :stop key any more.
(syms_of_process): Define needed symbol 'null'.

* test/src/process-tests.el (make-process/stop): New unit test.

* doc/lispref/processes.texi (Asynchronous Processes): Remove :stop
key from manual.

5 years agoAdapt tramp-test32-shell-command
Michael Albinus [Fri, 19 Apr 2019 09:30:22 +0000 (11:30 +0200)]
Adapt tramp-test32-shell-command

* test/lisp/net/tramp-tests.el (tramp-test32-shell-command):
Check "tput" before running `shell-command-width' test.

5 years agoAdd a new user option 'ido-big-directories'.
Philipp Stephani [Fri, 12 Apr 2019 12:23:01 +0000 (14:23 +0200)]
Add a new user option 'ido-big-directories'.

This provides an alternative to 'ido-max-directory-size', for
directories that are statically known to be too big for Ido
completion.

* lisp/ido.el (ido-big-directories): New user option.
(ido-directory-too-big-p): Use it.

* test/lisp/ido-tests.el (ido-directory-too-big-p): New unit test.

5 years agoUse eassume (false) for branch that's never taken.
Philipp Stephani [Fri, 19 Apr 2019 08:26:32 +0000 (10:26 +0200)]
Use eassume (false) for branch that's never taken.

* src/json.c (json_handle_nonlocal_exit): Use eassume (false) since
this branch is never taken.

5 years agoFix compilation warning due to a recent change
Eli Zaretskii [Fri, 19 Apr 2019 08:04:17 +0000 (11:04 +0300)]
Fix compilation warning due to a recent change

* src/json.c (json_handle_nonlocal_exit): Always return a
value.

5 years ago* src/ftcrfont.c (ftcrfont_glyph_extents): Activate ft_size_draw.
YAMAMOTO Mitsuharu [Fri, 19 Apr 2019 00:55:53 +0000 (09:55 +0900)]
* src/ftcrfont.c (ftcrfont_glyph_extents): Activate ft_size_draw.

5 years ago* src/ftcrfont.c (ftcrfont_open): Avoid returning while blocking input.
YAMAMOTO Mitsuharu [Fri, 19 Apr 2019 00:54:59 +0000 (09:54 +0900)]
* src/ftcrfont.c (ftcrfont_open): Avoid returning while blocking input.

5 years agoRefactoring: have CATCHER_ALL also catch signals.
Philipp Stephani [Thu, 18 Apr 2019 23:04:55 +0000 (01:04 +0200)]
Refactoring: have CATCHER_ALL also catch signals.

In all cases where we use a CATCHER_ALL handler we also want to catch
signals.  Therefore have 'signal' respect CATCHER_ALL.  Adapt internal
interfaces so that handlers can distinguish among the two types of
nonlocal exits in CATCHER_ALL handlers.

* src/lisp.h (enum nonlocal_exit): New enum.
(struct handler): Add member 'nonlocal_exit' to hold the type of
nonlocal exit during stack unwinding.

* src/eval.c (signal_or_quit): Also respect CATCHER_ALL handlers.
(unwind_to_catch): Store nonlocal exit type in catch structure.
(Fthrow, signal_or_quit): Adapt callers.
(internal_catch_all): Install only one handler.  Give handler a
nonlocal exit type argument.
(internal_catch_all_1): Remove, no longer needed.

* src/emacs-module.c (MODULE_SETJMP): Install only one handler.
(module_handle_nonlocal_exit): New function to handle all nonlocal
exits.
(MODULE_SETJMP_1): Pass nonlocal exit type to handler function.
(module_handle_signal, module_handle_throw): Remove, no longer needed.

* src/json.c (json_handle_nonlocal_exit): New helper function.
(json_insert_callback): Adapt to change in 'internal_catch_all'.

5 years agoUpdate module documentation for bignum support.
Philipp Stephani [Thu, 18 Apr 2019 21:31:00 +0000 (23:31 +0200)]
Update module documentation for bignum support.

* doc/lispref/internals.texi (Module Values): Update documentation for
'make_integer' and 'extract_integer' for bignum support.

5 years ago; * src/lisp.h (integer_to_intmax): Fix typo.
Philipp Stephani [Thu, 18 Apr 2019 21:29:20 +0000 (23:29 +0200)]
; * src/lisp.h (integer_to_intmax): Fix typo.

5 years ago* lib-src/make-fingerprint.c (main): Properly initialize 'prog'
Philipp Stephani [Thu, 18 Apr 2019 21:19:05 +0000 (23:19 +0200)]
* lib-src/make-fingerprint.c (main): Properly initialize 'prog'

5 years ago* src/emacs-module.c: Add instructions how to change the module API
Philipp Stephani [Thu, 18 Apr 2019 21:18:06 +0000 (23:18 +0200)]
* src/emacs-module.c: Add instructions how to change the module API

5 years agoFix make-fingerprint off-by-one bug
Paul Eggert [Thu, 18 Apr 2019 19:56:23 +0000 (12:56 -0700)]
Fix make-fingerprint off-by-one bug

Problem reported by Alex Gramiak in:
https://lists.gnu.org/r/emacs-devel/2019-04/msg00784.html
* lib-src/make-fingerprint.c (main): Fix recently-introduced
off-by-one bug when accessing args after -r.

5 years ago; Instrument `tramp--test-shell-command-to-string-asynchronously'
Michael Albinus [Thu, 18 Apr 2019 19:47:21 +0000 (21:47 +0200)]
; Instrument `tramp--test-shell-command-to-string-asynchronously'

5 years agoOnly encode Gnus group names if they come from symbol-name
Eric Abrahamsen [Thu, 18 Apr 2019 16:06:09 +0000 (09:06 -0700)]
Only encode Gnus group names if they come from symbol-name

* lisp/gnus/gnus-start.el (gnus-active-to-gnus-format): Names that
  were strings to begin with should already be properly encoded.

5 years agoMark _Noreturn error functions as cold
Paul Eggert [Thu, 18 Apr 2019 07:30:24 +0000 (00:30 -0700)]
Mark _Noreturn error functions as cold

On my platform this made ‘make compile-always’ 1.3% faster.
Suggested by Alex Gramiak in:
https://lists.gnu.org/r/emacs-devel/2019-04/msg00684.html
* configure.ac (nw): Don’t use -Wsuggest-attribute=cold.
* lib-src/make-docfile.c (write_globals):
Mark noreturn functions as cold.
* src/callproc.c (exec_failed):
* src/data.c (wrong_length_argument, wrong_type_argument):
* src/emacs-module.c (module_abort):
* src/emacs.c (terminate_due_to_signal):
* src/eval.c (unwind_to_catch):
* src/image.c (my_png_error, my_error_exit):
* src/json.c (json_out_of_memory, json_parse_error):
* src/keyboard.c (quit_throw_to_read_char, user_error):
* src/lisp.h (die, wrong_type_argument, wrong_choice)
(args_out_of_range, args_out_of_range_3, circular_list)
(buffer_overflow, memory_full, buffer_memory_full)
(string_overflow, xsignal, xsignal0, xsignal1, xsignal2)
(xsignal3, signal_error, overflow_error, error, verror)
(nsberror, report_file_errno, report_file_error)
(report_file_notify_error, terminate_due_to_signal)
(emacs_abort, fatal):
* src/lread.c (load_error_old_style_backquotes)
(end_of_file_error, invalid_syntax):
* src/pdumper.c (error_unsupported_dump_object):
* src/puresize.h (pure_write_error):
* src/search.c (matcher_overflow):
* src/sound.c (sound_perror, alsa_sound_perror):
* src/sysdep.c (handle_arith_signal):
* src/systime.h (time_overflow):
* src/term.c (maybe_fatal, vfatal):
* src/textprop.c (text_read_only):
* src/timefns.c (invalid_time_zone_specification)
(time_error, invalid_hz):
* src/xterm.c (x_connection_closed):
Use AVOID instead of _Noreturn void, so that it’s marked cold.
* src/conf_post.h (__has_attribute_cold) [!__has_attribute]:
New macro.
(ATTRIBUTE_COLD): New macro.
* src/frame.h (WINDOW_SYSTEM_RETURN): Add ATTRIBUTE_COLD.
* src/lisp.h (AVOID): New macro.
* src/xterm.c: Omit unnecessary static decls, so that we needn’t
worry about which functions should be marked cold.
(x_io_error_quitter): Mark as cold.

5 years ago* src/ftcrfont.c (ftcrfont_glyph_extents): Fix last change.
YAMAMOTO Mitsuharu [Thu, 18 Apr 2019 02:30:17 +0000 (11:30 +0900)]
* src/ftcrfont.c (ftcrfont_glyph_extents): Fix last change.

5 years agoAdd ERT explainer for 'tramp--test-file-attributes-equal-p'
Philipp Stephani [Wed, 17 Apr 2019 19:27:15 +0000 (21:27 +0200)]
Add ERT explainer for 'tramp--test-file-attributes-equal-p'

* test/lisp/net/tramp-tests.el (tramp--test-file-attributes-equal-p):
Use ERT explainer for 'equal' to improve failure messages.

5 years agoFix tramp-test32-shell-command
Michael Albinus [Wed, 17 Apr 2019 19:23:41 +0000 (21:23 +0200)]
Fix tramp-test32-shell-command

* test/lisp/net/tramp-tests.el (tramp-test32-shell-command):
Run only if "tput" exist.

5 years agoMerge from origin/emacs-26
Glenn Morris [Wed, 17 Apr 2019 16:32:40 +0000 (09:32 -0700)]
Merge from origin/emacs-26

a1c53d4 (origin/emacs-26) * admin/admin.el (make-manuals-dist--1): Up...
d0f745f Document some compilation-mode faces
23ccba0 Mention the assignment form in "Copyright Assignment"
0f5568e Fix confusing wording in the user manual
70ec392 Fix the MSDOS build when running under CWSDPMI
7a608fc * lisp/progmodes/python.el: Be more careful about temp file r...

5 years ago; Merge from origin/emacs-26
Glenn Morris [Wed, 17 Apr 2019 16:32:40 +0000 (09:32 -0700)]
; Merge from origin/emacs-26

The following commits were skipped:

b3cab41 Backport: Plug memory leak in GTK x-display-monitor-attribute...
e40f39b Backport: * lisp/frame.el (frame--size-history): Fix infloop....

5 years agoMerge from origin/emacs-26
Glenn Morris [Wed, 17 Apr 2019 16:32:39 +0000 (09:32 -0700)]
Merge from origin/emacs-26

266c622 Downcase charset
92f3459 Update for Emacs-26
beb4eac * doc/lispref/display.texi (Showing Images): Fix a typo.  (Bu...

5 years ago; Fix files-tests-executable-find on w32 (Bug#35241)
Noam Postavsky [Wed, 17 Apr 2019 14:24:12 +0000 (10:24 -0400)]
; Fix files-tests-executable-find on w32 (Bug#35241)

* test/lisp/files-tests.el (files-tests-executable-find): Make the
tmpfile end with one of exec-suffixes, so that it will be executable
on w32.

5 years ago; Instrument tramp-test32-shell-command for EMBA
Michael Albinus [Wed, 17 Apr 2019 12:19:42 +0000 (14:19 +0200)]
; Instrument tramp-test32-shell-command for EMBA

5 years agoFix Bug#35241
Michael Albinus [Wed, 17 Apr 2019 12:04:37 +0000 (14:04 +0200)]
Fix Bug#35241

* lisp/files.el (executable-find): Quote default-directory.  (Bug#35241)

* test/lisp/files-tests.el (files-tests-executable-find): New test.

5 years ago* test/lisp/files-tests.el: Unify test names
Michael Albinus [Wed, 17 Apr 2019 09:54:17 +0000 (11:54 +0200)]
* test/lisp/files-tests.el: Unify test names

* test/lisp/files-tests.el (files-tests-local-variables)
(files-tests-bug-18141, files-tests-make-temp-file-empty-prefix)
(files-tests-bug-21454)
(files-tests-save-buffers-kill-emacs--confirm-kill-processes)
(files-tests-read-file-in-~)
(files-tests-file-name-non-special--subprocess)
(files-tests-file-name-non-special--buffers)
(files-tests-insert-directory-wildcard-in-dir-p)
(files-tests-make-directory, files-tests-no-file-write-contents)
(files-tests-copy-directory, files-tests-abbreviated-home-dir):
Unify test names.

5 years agoTest `shell-command-width' in Tramp
Michael Albinus [Wed, 17 Apr 2019 09:42:06 +0000 (11:42 +0200)]
Test `shell-command-width' in Tramp

* test/lisp/net/tramp-tests.el
(tramp--test-shell-command-to-string-asynchronously): Move up.
(tramp-test32-shell-command): Test `shell-command-width'.

5 years agoUse cairo_scaled_font_t object for text drawing and metrics calculation
YAMAMOTO Mitsuharu [Wed, 17 Apr 2019 00:46:34 +0000 (09:46 +0900)]
Use cairo_scaled_font_t object for text drawing and metrics calculation

* src/ftfont.h (struct font_info): Replace member cr_font_face of type
cairo_font_face_t * with cr_scaled_font of type cairo_scaled_font_t *.
* src/ftcrfont.c: Include math.h for floor, ceiling, and lround.
(ftcrfont_glyph_extents): Use cairo_scaled_font_glyph_extents.
(ftcrfont_open): Create cairo_scaled_font_t object and set it to
cr_scaled_font member of struct font_info.
(ftcrfont_close): Use cairo_scaled_font_destroy.
(ftcrfont_draw): Use cairo_set_scaled_font.

5 years agoMake python-shell-prompt-block-regexp match IPython prompt
Andrii Kolomoiets [Tue, 19 Feb 2019 21:57:07 +0000 (23:57 +0200)]
Make python-shell-prompt-block-regexp match IPython prompt

* lisp/progmodes/python.el (python-shell-prompt-block-regexp): Match
also IPython's multiline prompt.  It allows to correctly disable
non-native completions during multiline statement in
inferior-python-mode that runs IPython interpreter (Bug#34582).

Copyright-paperwork-exempt: yes

5 years ago* admin/admin.el (make-manuals-dist--1):
Glenn Morris [Tue, 16 Apr 2019 21:33:24 +0000 (14:33 -0700)]
* admin/admin.el (make-manuals-dist--1):
Update for incompatible copy-file change re "directories".

5 years ago* etc/NEWS: Mention new xref faces (bug#23179)
Juri Linkov [Tue, 16 Apr 2019 21:04:30 +0000 (00:04 +0300)]
* etc/NEWS: Mention new xref faces (bug#23179)

5 years ago* lisp/vc/diff-mode.el (diff-syntax-fontify-hunk): Erase buffer
Juri Linkov [Tue, 16 Apr 2019 20:51:51 +0000 (23:51 +0300)]
* lisp/vc/diff-mode.el (diff-syntax-fontify-hunk): Erase buffer

before inserting file contents to *diff-syntax-file*.
Use absolute file names.

5 years ago* GNUmakefile: Update comment.
Paul Eggert [Tue, 16 Apr 2019 18:04:16 +0000 (11:04 -0700)]
* GNUmakefile: Update comment.

5 years agoDocument some compilation-mode faces
Robert Pluim [Tue, 16 Apr 2019 16:07:31 +0000 (18:07 +0200)]
Document some compilation-mode faces

* doc/emacs/building.texi (Compilation Mode): Describe faces
available to affect appearance of compilation-mode buffers.

5 years agoMention the assignment form in "Copyright Assignment"
Eli Zaretskii [Tue, 16 Apr 2019 15:32:18 +0000 (18:32 +0300)]
Mention the assignment form in "Copyright Assignment"

* doc/emacs/trouble.texi (Copyright Assignment): Mention the
copyright assignment form explicitly.  Suggested by Konstantin
Kharlamov <hi-angel@yandex.ru>.

5 years agoFix confusing wording in the user manual
Eli Zaretskii [Tue, 16 Apr 2019 15:27:37 +0000 (18:27 +0300)]
Fix confusing wording in the user manual

* doc/emacs/maintaining.texi (VC Undo): Remove a potentially
inaccurate, outdated, and/or confusing sentence.  (Bug#35290)

5 years ago* make-dist (possibly_non_vc_files): Remove recently deleted file.
Glenn Morris [Tue, 16 Apr 2019 15:09:47 +0000 (08:09 -0700)]
* make-dist (possibly_non_vc_files): Remove recently deleted file.

5 years agoFix uninit var in widget.c
Paul Eggert [Tue, 16 Apr 2019 03:53:13 +0000 (20:53 -0700)]
Fix uninit var in widget.c

* src/widget.c (EmacsFrameQueryGeometry):
Avoid use of uninitialized variables ok_width, ok_height (Bug#35277).

5 years agoRemove Vparam_value_alist
Paul Eggert [Tue, 16 Apr 2019 03:23:24 +0000 (20:23 -0700)]
Remove Vparam_value_alist

* src/xfaces.c (Vparam_value_alist):
Remove.  All uses removed.
(Finternal_set_lisp_face_attribute):
Simplify by using AUTO_FRAME_ARG.

5 years agoProperly bracket concat of comment-start-skip (Bug#34805)
Noam Postavsky [Fri, 5 Apr 2019 12:00:09 +0000 (08:00 -0400)]
Properly bracket concat of comment-start-skip (Bug#34805)

* lisp/emacs-lisp/smie.el (smie-indent-fixindent):
* lisp/cedet/semantic/doc.el (semantic-doc-snarf-comment-for-tag):
* lisp/progmodes/fortran.el (fortran-previous-statement)
(fortran-next-statement)
(fortran-fill-statement):
* lisp/progmodes/vhdl-mode.el (vhdl-beginning-of-statement): Bracket
comment-start-skip and comment-end-skip to avoid unexpected regexp
operator precedence.

5 years agoMinor change in a comment
Eli Zaretskii [Mon, 15 Apr 2019 16:11:16 +0000 (19:11 +0300)]
Minor change in a comment

* test/src/callproc-tests.el
(call-process-w32-debug-spawn-error): Minor copyedits of the
commentary.

5 years agoFix the MSDOS build when running under CWSDPMI
Eli Zaretskii [Mon, 15 Apr 2019 15:05:52 +0000 (18:05 +0300)]
Fix the MSDOS build when running under CWSDPMI

* src/msdos.c (the_only_tty_output): Define.
* src/msdos.h (the_only_tty_output): Declare.
* src/frame.c (make_terminal_frame) [MSDOS]:
* src/dispnew.c (init_display) [MSDOS]: Set up
f->output_data.tty pointer using the_only_tty_output, before
dereferencing the pointer.  This prevents crashes with DPMI
servers that provide NULL pointer protection.

5 years agoFix MS-Windows build broken by make-fingerprint changes
Eli Zaretskii [Mon, 15 Apr 2019 14:17:01 +0000 (17:17 +0300)]
Fix MS-Windows build broken by make-fingerprint changes

* lib-src/make-fingerprint.c (fseeko) [WNDOWSNT]: Define to
fseeko64 for non-MinGW64 MinGW.

* lib-src/ntlib.c (stat): Fix calculation of file size.
(fstat): New function, a subset of src/w32.c:fstat.  This is
needed because make-fingerprint.c now calls 'fstat', and the
MS version will fail to produce reliable results because
nt/inc/sys/stat.h redefines 'struct stat'.

5 years ago* .gitlab-ci.yml (test-filenotify-gio): Add autorevert changes.
Michael Albinus [Mon, 15 Apr 2019 11:24:55 +0000 (13:24 +0200)]
* .gitlab-ci.yml (test-filenotify-gio): Add autorevert changes.

5 years agoDon't remove notify descriptor that is already gone
Mattias Engdegård [Wed, 10 Apr 2019 13:25:53 +0000 (15:25 +0200)]
Don't remove notify descriptor that is already gone

* lisp/autorevert.el (auto-revert-use-notify, auto-revert-mode,
global-auto-revert-mode, auto-revert-notify-rm-watch,
auto-revert-notify-add-watch, auto-revert-notify-handler,
auto-revert-notify-rm-watch-callback):
Don't remove a notify descriptor after receiving a `stopped' notification
event, because the descriptor is then already gone and any attempt to
remove it causes a recursive call to `auto-revert-notify-handler'.

5 years ago* doc/misc/tramp.texi: Fix direntry.
Michael Albinus [Mon, 15 Apr 2019 07:35:31 +0000 (09:35 +0200)]
* doc/misc/tramp.texi: Fix direntry.

5 years agoRemove static var system_eol_type
Paul Eggert [Mon, 15 Apr 2019 06:10:45 +0000 (23:10 -0700)]
Remove static var system_eol_type

* src/coding.c (system_eol_type): Remove.
(coding_inherit_eol_type, syms_of_coding):
Simplify to avoid the need for system_eol_type.

5 years agoAvoid compiler warnings on cairo build
YAMAMOTO Mitsuharu [Mon, 15 Apr 2019 03:39:05 +0000 (12:39 +0900)]
Avoid compiler warnings on cairo build

* src/image.c (jpeg_load_body) [USE_CAIRO]: #ifdef out USE_SAFE_ALLOCA
and SAFE_FREE.
* src/xterm.c (x_composite_image) [USE_CAIRO]: #ifdef out unused function.
(x_draw_image_glyph_string) [USE_CAIRO]: #ifdef out unused variable pixmap.

5 years agoLet debugger handle process spawn errors on w32 (Bug#33016)
Noam Postavsky [Mon, 8 Apr 2019 21:57:22 +0000 (17:57 -0400)]
Let debugger handle process spawn errors on w32 (Bug#33016)

Since child_setup() is called between block_input()...unblock_input(),
when an error is signaled the Lisp debugger is prevented from
starting.  Therefore, let the callers signal the error instead (which
they already do for non-w32 platforms, just the error message needs an
update).
* src/callproc.c (child_setup) [WINDOWSNT]: Don't call
report_file_error here.
(call_process) [WINDOWNT]:
* src/process.c (create_process) [WINDOWSNT]: Call report_file_errno
here instead, after the unblock_input() call, same as for !WINDOWSNT.
* src/lisp.h (CHILD_SETUP_ERROR_DESC): New preprocessor define.  Flip
the containing ifndef DOS_NT branches so that it's ifdef DOS_NT.
* src/eval.c (when_entered_debugger): Remove.
(syms_of_eval) <internal-when-entered-debugger>: Define it as a Lisp
integer variable instead.
(maybe_call_debugger): Update comment.
* test/src/process-tests.el (make-process-w32-debug-spawn-error):
* test/src/callproc-tests.el (call-process-w32-debug-spawn-error): New
tests.

5 years agoBump minimum GTK versions to 2.24 and 3.10
Alexander Gramiak [Mon, 8 Apr 2019 01:02:03 +0000 (19:02 -0600)]
Bump minimum GTK versions to 2.24 and 3.10

* configure.ac: Bump required GTK 2 and GTK 3 versions and the
associated GLib versions. Remove obsolete AC_CHECK_FUNCS calls. These
check for functions available in later GTK 2 versions. These checks
and can safely be removed with the exception of
gtk_window_set_has_resize_grip, which according to a comment in
gtkutil.c causes an issue in Ubuntu's GTK 2.

* src/gtkutil.c:
* src/xfns.c:
* src/xterm.c:
* src/xterm.h: Remove now unused conditional blocks. Use HAVE_GTK3
instead of GTK_CHECK_VERSION where now applicable. Remove checks of
now always true USE_GTK_TOOLTIP.

5 years agoReplace executable’s fingerprint in place
Paul Eggert [Sun, 14 Apr 2019 23:31:24 +0000 (16:31 -0700)]
Replace executable’s fingerprint in place

* admin/merge-gnulib (GNULIB_MODULES): Add memmem-simple.
(AVOIDED_MODULES): Add memchr.
* configure.ac (HAVE_PDUMPER): AC_SUBST it, too, for use in makefiles.
* lib/Makefile.in (libgnu_a_OBJECTS): Add fingerprint.o.
* lib/fingerprint.c: New file.
* lib/memmem.c, lib/str-two-way.h, m4/memmem.m4: New files,
copied from Gnulib.
* lib/fingerprint.h: Rename from src/fingerprint.h.
* lib-src/make-fingerprint.c: Include limits.h, sys/stat.h,
fingerprint.h, intprops.h, min-max.h.
(SSIZE_MAX): New macro, if not already defined.
(main): Without -r, Replace the fingerprint in the input file
instead of generating a fingerprint.c.
* lib/Makefile.in (libgnu_a_OBJECTS): Add fingerprint.o.
* lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
* src/Makefile.in (HAVE_PDUMPER, MAKE_PDUMPER_FINGERPRINT):
New macros.
(temacs$(EXEEXT)): Use them to replace the fingerprint instead
of precalculating it.
(mostlyclean, ctagsfiles1): Do not worry about fingerprint.c.

5 years ago* m4/utimbuf.m4: Remove unused file.
Paul Eggert [Sun, 14 Apr 2019 23:23:54 +0000 (16:23 -0700)]
* m4/utimbuf.m4: Remove unused file.

5 years ago* lisp/progmodes/python.el: Be more careful about temp file removal
Stefan Monnier [Sun, 14 Apr 2019 22:45:35 +0000 (18:45 -0400)]
* lisp/progmodes/python.el: Be more careful about temp file removal

(python-shell-prompt-detect): Use unwind-protect to try and not leave
file behind in case of error.

5 years agoBackport: Plug memory leak in GTK x-display-monitor-attributes-list
Alexander Gramiak [Sun, 7 Apr 2019 05:02:24 +0000 (23:02 -0600)]
Backport: Plug memory leak in GTK x-display-monitor-attributes-list

* src/frame.c (free_monitors) [USE_GTK]: Define in the GTK case as
well.

* src/xfns.c (x-display-monitor-attributes-list) [USE_GTK]: Plug
memory leak. Use dupstring over xstrdup as gdk_monitor_get_model may
return NULL.

5 years agoBackport: * lisp/frame.el (frame--size-history): Fix infloop. (Bug#35272)
Alexander Gramiak [Sun, 14 Apr 2019 15:27:50 +0000 (09:27 -0600)]
Backport: * lisp/frame.el (frame--size-history): Fix infloop. (Bug#35272)

5 years agoSort files in the default impl of project-files alphabetically
Dmitry Gutov [Sun, 14 Apr 2019 21:39:29 +0000 (00:39 +0300)]
Sort files in the default impl of project-files alphabetically

* lisp/progmodes/project.el (project--files-in-directory):
Sort the files alphabetically
(https://debbugs.gnu.org/cgi/bugreport.cgi?bug=23179#296).

5 years agoSome rearragements for remote tests in filenotify-tests.el
Michael Albinus [Sun, 14 Apr 2019 17:53:38 +0000 (19:53 +0200)]
Some rearragements for remote tests in filenotify-tests.el

* test/lisp/filenotify-tests.el (file-notify--deftest-remote):
Change argument list, EXPECTED is not needed.
(file-notify-test07-many-events-remote)
(file-notify-test09-watched-file-in-watched-dir-remote):
Adapt declaration accordingly.

5 years agoExplain ad-hoc multi-hop in the Tramp Quick Start Guide
Michael Albinus [Sun, 14 Apr 2019 17:53:02 +0000 (19:53 +0200)]
Explain ad-hoc multi-hop in the Tramp Quick Start Guide

* doc/misc/tramp.texi (Quick Start Guide): New section "Combining
@option{ssh} or @option{plink} with @option{su} or @option{sudo}".

5 years agoFix Bug#35055
Michael Albinus [Sun, 14 Apr 2019 17:52:12 +0000 (19:52 +0200)]
Fix Bug#35055

* lisp/net/tramp.el (tramp-handle-shell-command):
Handle `shell-command-width'.  (Bug#35055)

5 years agoDowncase charset
Robert Pluim [Sun, 14 Apr 2019 12:36:30 +0000 (14:36 +0200)]
Downcase charset

RFC 2046 specifies that the charset parameter is case-insensitive.

* lisp/gnus/gnus-icalendar.el (gnus-icalendar-with-decoded-handle):
Downcase charset.  Suggested by Christophe TROESTLER
<Christophe.TROESTLER@umons.ac.be>.  (Bug#35265).

5 years ago* lisp/frame.el (frame--size-history): Fix infloop. (Bug#35272)
Alexander Gramiak [Sun, 14 Apr 2019 15:27:50 +0000 (09:27 -0600)]
* lisp/frame.el (frame--size-history): Fix infloop. (Bug#35272)

5 years agoUpdate for Emacs-26
Phillip Lord [Sun, 14 Apr 2019 17:16:52 +0000 (18:16 +0100)]
Update for Emacs-26

* nt/README.W32: Update details about packaging which changed for
  Emacs-26.

5 years agoMerge commit '890440a44cd5f4f09742f521c7783785d114fffc'
Stephen Leake [Sun, 14 Apr 2019 16:24:42 +0000 (09:24 -0700)]
Merge commit '890440a44cd5f4f09742f521c7783785d114fffc'

5 years agoRename new user variable `next-error-verbosity' to `next-error-verbose'
Stephen Leake [Sun, 14 Apr 2019 16:23:24 +0000 (09:23 -0700)]
Rename new user variable `next-error-verbosity' to `next-error-verbose'

* etc/NEWS: Update entry to match renaming.

* lisp/simple.el (next-error-verbose): Rename.
(next-error, next-error-internal): Match rename.

5 years agoSimplify gdk_monitor_get_model string duplication
Alexander Gramiak [Sun, 14 Apr 2019 14:41:48 +0000 (08:41 -0600)]
Simplify gdk_monitor_get_model string duplication

* src/xfns.c (x-display-monitor-attributes-list): Use dupstring over
explicit if/xstrdup.

* src/frame.c (free_monitors): Remove redundant check for NULL.

5 years agoImprove documentation of a recent commit
Eli Zaretskii [Sun, 14 Apr 2019 14:50:12 +0000 (17:50 +0300)]
Improve documentation of a recent commit

* etc/NEWS: Fix the description of 'shell-command-width'.
Mark the entry as not needing the manual update.

* lisp/simple.el (shell-command-width): Doc fix.  (Bug#35055)

5 years agoUpdate from Gnulib
Paul Eggert [Sun, 14 Apr 2019 04:13:16 +0000 (21:13 -0700)]
Update from Gnulib

This incorporates:
2019-04-07 Add copyright notices in several files
* build-aux/config.sub, doc/misc/texinfo.tex, lib/_Noreturn.h:
Copy from Gnulib.
* lib/gnulib.mk.in: Regenerate.

5 years agoFix gnus-group-describe-all-groups (bug#35233)
Basil L. Contovounesios [Thu, 11 Apr 2019 16:16:00 +0000 (17:16 +0100)]
Fix gnus-group-describe-all-groups (bug#35233)

This fixes oversights from
2018-04-26T16:26:27-07:00!eric@ericabrahamsen.net and
2016-02-13T18:45:11+11:00!larsi@gnus.org.
* lisp/gnus/gnus-group.el (gnus-group-describe-all-groups): Insert
group name and description instead of group name twice.  Do not pass
a hash-table to intern.  Call sort with correct number of arguments.

5 years agoFix segmentation fault with gdk_monitor_get_model (Bug#35259)
Alexander Gramiak [Sat, 13 Apr 2019 22:05:21 +0000 (16:05 -0600)]
Fix segmentation fault with gdk_monitor_get_model (Bug#35259)

* src/frame.c (free_monitors): Check if NULL before freeing.

* src/xfns.c: (x-display-monitor-attributes-list): Check if NULL
before copying.

5 years ago* lisp/vc/log-edit.el (log-edit-insert-changelog): Add field "Summary"
Juri Linkov [Sat, 13 Apr 2019 22:02:39 +0000 (01:02 +0300)]
* lisp/vc/log-edit.el (log-edit-insert-changelog): Add field "Summary"

explicitly after adding field "Author".  (Bug#34972)

5 years agoNew faces in xref (bug#23179)
Juri Linkov [Sat, 13 Apr 2019 21:54:14 +0000 (00:54 +0300)]
New faces in xref (bug#23179)

* lisp/progmodes/xref.el (xref-file-header, xref-line-number)
(xref-match):  New faces.
(xref--insert-xrefs, xref--collect-matches-1): Use them.

5 years ago* lisp/simple.el (shell-command-width): New defcustom.
Juri Linkov [Sat, 13 Apr 2019 21:46:38 +0000 (00:46 +0300)]
* lisp/simple.el (shell-command-width): New defcustom.

(shell-command): Use it.  (Bug#35055)

5 years ago* lisp/progmodes/cc-langs.el (c-class-id-suffix-ws-ids-kwds): Correct a typo
Alan Mackenzie [Sat, 13 Apr 2019 19:33:18 +0000 (19:33 +0000)]
* lisp/progmodes/cc-langs.el (c-class-id-suffix-ws-ids-kwds): Correct a typo

5 years agoImplement "final" before C++ class inheritance lists.
Alan Mackenzie [Sat, 13 Apr 2019 13:29:58 +0000 (13:29 +0000)]
Implement "final" before C++ class inheritance lists.

* lisp/progmodes/cc-langs.el (c-class-id-suffix-ws-ids-kwds)
(c-class-id-suffix-ws-ids-key): New lang const/var.

* lisp/progmodes/cc-engine.el (c-guess-basic-syntax CASE 5D.4): Check for and
skip over any matches for c-class-id-suffix-ws-ids-key (i.e. "final") before
":".

5 years agoFix error in tramp-sh.el
Michael Albinus [Sat, 13 Apr 2019 10:34:44 +0000 (12:34 +0200)]
Fix error in tramp-sh.el

* lisp/net/tramp-sh.el (tramp-sh-handle-make-process):
Revert "simplification", which was an error.

5 years ago* doc/misc/tramp.texi: Fix minor glitches.
Michael Albinus [Sat, 13 Apr 2019 10:34:13 +0000 (12:34 +0200)]
* doc/misc/tramp.texi: Fix minor glitches.

5 years agoFix last patch
Michael Albinus [Sat, 13 Apr 2019 09:12:16 +0000 (11:12 +0200)]
Fix last patch

5 years agoReplace (skip-unless nil) by tag :unstable in test packages
Michael Albinus [Sat, 13 Apr 2019 08:58:17 +0000 (10:58 +0200)]
Replace (skip-unless nil) by tag :unstable in test packages

* test/lisp/filenotify-tests.el (file-notify--deftest-remote):
Use tag :unstable if SKIP is non-nil.

* test/lisp/net/tramp-tests.el (tramp-test36-vc-registered):
Use ert-skip instead of (skip-unless nil).

* test/lisp/progmodes/python-tests.el
(python-tests--python-nav-end-of-statement--infloop): Use tag
:unstable instead of (skip-unless nil).

5 years agoMinor cleanup in 'x_set_frame_alpha'
Eli Zaretskii [Sat, 13 Apr 2019 08:01:39 +0000 (11:01 +0300)]
Minor cleanup in 'x_set_frame_alpha'

* src/xterm.c (x_set_frame_alpha): Remove redundant parts of
testing of value of 'alpha'.  Suggested by Konstantin
Kharlamov <Hi-Angel@yandex.ru>.  (Bug#35062)

5 years agoImprove documentation of JSONRPC
Eli Zaretskii [Sat, 13 Apr 2019 07:42:14 +0000 (10:42 +0300)]
Improve documentation of JSONRPC

* doc/lispref/text.texi (JSONRPC Overview)
(Process-based JSONRPC connections)
(JSONRPC JSON object format): Fix wording and markup.  Add
indexing.

5 years agoImprove documentation changes of a recent commit
Eli Zaretskii [Sat, 13 Apr 2019 07:07:15 +0000 (10:07 +0300)]
Improve documentation changes of a recent commit

* doc/lispref/text.texi (Parsing JSON): Improve wording of the
documentation of 'json-parse-string' and 'json-parse-buffer'.
* src/json.c (Fjson_parse_string, Fjson_parse_buffer): Doc fix.
(Bug#34763)

5 years agoOmit/rewrite useless regexp repetitions
Paul Eggert [Sat, 13 Apr 2019 02:43:16 +0000 (19:43 -0700)]
Omit/rewrite useless regexp repetitions

Problem reported by Mattias Engdegård in:
https://lists.gnu.org/r/emacs-devel/2019-04/msg00527.html
* lisp/align.el (align-rules-list):
* lisp/cedet/srecode/srt-mode.el (srecode-font-lock-keywords):
* lisp/emacs-lisp/copyright.el (copyright-regexp):
* lisp/erc/erc-backend.el (JOIN):
* lisp/erc/erc-goodies.el (erc-unmorse):
* lisp/mail/mail-extr.el (mail-extr-telephone-extension-pattern):
* lisp/net/tramp-adb.el (tramp-adb-prompt):
* lisp/org/org-table.el (org-table-range-regexp):
* lisp/progmodes/idlwave.el (idlwave-where):
* lisp/progmodes/verilog-mode.el (verilog-declaration-re-2-no-macro)
(verilog-declaration-re-2-macro, verilog-delete-auto-buffer)
(verilog-auto-inst-port):
* lisp/url/url-misc.el (url-data):
Omit or rewrite useless repetitions that risk being very slow in
the backtracking regexp engine in Emacs.