]> git.eshelyaron.com Git - emacs.git/log
emacs.git
5 years ago* lisp/progmodes/sql.el Bug#35307
Michael R. Mauger [Sun, 21 Apr 2019 04:40:00 +0000 (00:40 -0400)]
* lisp/progmodes/sql.el  Bug#35307
(sql-product-alist): Added :prompt-cont-regexp for ms.

Looking for experience with Microsofts SQLCMD interpreter and
adjustments needed for Emacs to support it.

5 years ago* lisp/progmodes/sql.el Bug#24483
Michael R. Mauger [Sun, 21 Apr 2019 04:19:56 +0000 (00:19 -0400)]
* lisp/progmodes/sql.el  Bug#24483
(sql-interactive-remove-continuation-prompt): Properly protect `sql-prompt-cont-regexp'.
(sql-interactive-mode): Same.

5 years ago * lisp/progmodes.sql.el
Michael R. Mauger [Sun, 21 Apr 2019 00:13:56 +0000 (20:13 -0400)]
 * lisp/progmodes.sql.el
(sql-product-alist): Corrected :terminator defns.
(sql-debug-send): New variable.
(sql-send-string): Use it and correct buffer context.
(sql-send-magic-terminator): Use `sql-input-sender'.
(sql-placeholders-filter): Bug#11481 Don't recursively replace placeholders
* test/lisp/progmodes/sql-tests.el
(sql-test-placeholder-filter): Test placeholder functionality.

5 years agoFix text metrics calculation in Xft support for lwlib
YAMAMOTO Mitsuharu [Sun, 21 Apr 2019 02:39:06 +0000 (11:39 +0900)]
Fix text metrics calculation in Xft support for lwlib

* lwlib/lwlib-Xaw.c (get_text_width_and_height) [HAVE_XFT]:
* lwlib/xlwmenu.c (string_width) [HAVE_XFT]: Use xOff member instead of width.

5 years ago* src/configure.ac: Check for GTK 2 features only on GTK 2
Alexander Gramiak [Sun, 21 Apr 2019 02:16:20 +0000 (20:16 -0600)]
* src/configure.ac: Check for GTK 2 features only on GTK 2

5 years ago* lwlib/lwlib-Xaw.c (draw_text) [HAVE_XFT]: Fix memory leak.
YAMAMOTO Mitsuharu [Sun, 21 Apr 2019 00:53:39 +0000 (09:53 +0900)]
* lwlib/lwlib-Xaw.c (draw_text) [HAVE_XFT]: Fix memory leak.

5 years agoSupport amending the last commit using VC-Hg
Dmitry Gutov [Sat, 20 Apr 2019 21:39:36 +0000 (00:39 +0300)]
Support amending the last commit using VC-Hg

* lisp/vc/log-edit.el (log-edit--toggle-amend): Extract from
vc-git-log-edit-toggle-amend (bug#34944).

* lisp/vc/vc-hg.el (vc-hg-log-edit-toggle-amend): New function.
Use the aforementioned.
(vc-hg-log-edit-mode-map): New variable.
(vc-hg-log-edit-mode): New major mode.

5 years agoMark different-diagnostic-types as failed on emba.
Michael Albinus [Sat, 20 Apr 2019 19:16:05 +0000 (21:16 +0200)]
Mark different-diagnostic-types as failed on emba.

* test/lisp/progmodes/flymake-tests.el (different-diagnostic-types):
Expect also failure on emba.gnu.org.

5 years agoImprove XDG_RUNTIME_DIR diagnostic
Paul Eggert [Sat, 20 Apr 2019 16:31:47 +0000 (09:31 -0700)]
Improve XDG_RUNTIME_DIR diagnostic

* lib-src/emacsclient.c (set_local_socket):
If there appears to be an XDG runtime directory for the user
but XDG_RUNTIME_DIR is unset, suggest setting it while warning
about potential security issues (Bug#35300).

5 years agoFix Pike Mode's autodoc doc comments style's continued lines.
Alan Mackenzie [Sat, 20 Apr 2019 11:30:55 +0000 (11:30 +0000)]
Fix Pike Mode's autodoc doc comments style's continued lines.

* lisp/progmodes/cc-engine.el (c-forward-sws, c-backward-sws): Recognize
matches of c-doc-line-join-re as syntactic whitespace.
(c-find-decl-prefix-search): Recognize and move over matches of
c-doc-line-join-re as whitespace.
(c-find-decl-spots): Before moving backward a char, check (bobp).  Before
moving forward over a comment, check it isn't possibly a "bright" comment.

* lisp/progmodes/cc-fonts.el (c-get-doc-comment-style): New function,
extracted from c-compose-keywords-list.
(c-compose-keywords-list): Call the above new function.
(pike-font-lock-keywords, pike-font-lock-keywords-2)
(pike-font-lock-keywords-3): Call c-set-doc-comment-res.
(c-doc-line-join-re, c-doc-bright-comment-start-re, c-doc-line-join-end-ch):
New variables.
(c-set-doc-comment-re-element, c-set-doc-comment-char-list): New macros.
(c-set-doc-comment-res): New function.
(c-font-lock-doc-comments): For consistency and repeatability, in a sequence
of C++ style doc comments, don't fontify the region between BOL and the
comment marker.
(autodoc-line-join-re, autodoc-bright-comment-start-re)
(autodoc-line-join-end-ch): New variables.

* lisp/progmodes/cc-mode.el (c-doc-fl-decl-start, c-doc-fl-decl-end): New
functions.
(c-change-expand-fl-region, c-context-expand-fl-region): Call the above two
new functions for extra possibilities for the start and end of a construct.

* doc/misc/cc-mode.texi (Doc Comments): Add a sentence drawing attention to
the possibility of fontifying constructs within a doc comment.

5 years ago* lisp/emacs-lisp/smie.el (smie-indent-comment-continue): Single-char case.
Stefan Monnier [Sat, 20 Apr 2019 03:50:58 +0000 (23:50 -0400)]
* lisp/emacs-lisp/smie.el (smie-indent-comment-continue): Single-char case.

Make it so the comment-continue is aligned with the comment-start when
comment-start is a single-char.

5 years ago* src/ftcrfont.c (ftcrfont_shape): Fix last change.
YAMAMOTO Mitsuharu [Sat, 20 Apr 2019 03:50:32 +0000 (12:50 +0900)]
* src/ftcrfont.c (ftcrfont_shape): Fix last change.

5 years agoUse bitmap strikes as fallbacks for ftcr font backend
YAMAMOTO Mitsuharu [Sat, 20 Apr 2019 03:43:45 +0000 (12:43 +0900)]
Use bitmap strikes as fallbacks for ftcr font backend

* src/ftfont.h (struct font_info): New member bitmap_strike_index.
* src/ftfont.c (ftfont_open2): Try bitmap strikes as fallbacks.
(ftfont_open): Discard bitmap strikes.
* src/ftcrfont.c (ftcrfont_open): Recalculate metrics for bitmap strikes.
(ftcrfont_get_bitmap, ftcrfont_anchor_point, ftcrfont_shape): New functions.
(struct font_driver): Use them.

5 years ago* lisp/emacs-lisp/radix-tree.el (pcase-defmacro): Improve docstring
Stefan Monnier [Sat, 20 Apr 2019 03:31:59 +0000 (23:31 -0400)]
* lisp/emacs-lisp/radix-tree.el (pcase-defmacro): Improve docstring

5 years ago* lisp/emacs-lisp/byte-run.el (define-obsolete-variable-alias): Tweak doc
Stefan Monnier [Sat, 20 Apr 2019 03:29:33 +0000 (23:29 -0400)]
* lisp/emacs-lisp/byte-run.el (define-obsolete-variable-alias): Tweak doc

5 years ago* lisp/calendar/time-date.el (date-to-time): 'signal' only takes 2 args
Stefan Monnier [Sat, 20 Apr 2019 03:28:07 +0000 (23:28 -0400)]
* lisp/calendar/time-date.el (date-to-time): 'signal' only takes 2 args

5 years ago* lisp/calendar/parse-time.el (parse-time-string): Use functionp and setf
Stefan Monnier [Sat, 20 Apr 2019 03:25:04 +0000 (23:25 -0400)]
* lisp/calendar/parse-time.el (parse-time-string): Use functionp and setf

5 years agoFix GC_CHECK_STRING_BYTES false alarm with pdumper
Paul Eggert [Sat, 20 Apr 2019 00:35:39 +0000 (17:35 -0700)]
Fix GC_CHECK_STRING_BYTES false alarm with pdumper

* src/alloc.c (string_bytes): Don’t abort on strings
taken from the dumped file.

5 years agoFix another hash false alarm
Paul Eggert [Sat, 20 Apr 2019 00:35:39 +0000 (17:35 -0700)]
Fix another hash false alarm

* src/pdumper.c (dump_vectorlike): Fix hash.

5 years ago; * src/alloc.c (xrealloc): Fix typo.
Philipp Stephani [Fri, 19 Apr 2019 23:49:41 +0000 (01:49 +0200)]
; * src/alloc.c (xrealloc): Fix typo.

5 years ago* src/emacs-module.c (value_storage_contains_p): Fix typo.
Paul Eggert [Fri, 19 Apr 2019 21:41:37 +0000 (14:41 -0700)]
* src/emacs-module.c (value_storage_contains_p): Fix typo.

5 years agoRemove some ineffective #ifdefs.
Philipp Stephani [Fri, 19 Apr 2019 21:17:19 +0000 (23:17 +0200)]
Remove some ineffective #ifdefs.

Since DEFSYM doesn't by itself do anything and make-docfile ignores
preprocessor statements, conditional compilation of DEFSYMs is
ineffective.

* src/data.c (syms_of_data): Remove ineffective #ifdefs.

5 years ago; * src/alloc.c (HAVE_MODULES): remove unused constant
Philipp Stephani [Fri, 19 Apr 2019 21:11:14 +0000 (23:11 +0200)]
; * src/alloc.c (HAVE_MODULES): remove unused constant

5 years agoRemove some #ifdefs for user pointers.
Philipp Stephani [Fri, 19 Apr 2019 21:07:58 +0000 (23:07 +0200)]
Remove some #ifdefs for user pointers.

Even if Emacs is compiled without module support, we don't have to
comment out every bit of user pointer support.  Defining the basic
structures and functions and detecting user pointers in switch
statements is harmless, and we're already doing the same for module
functions.  Removing these #ifdefs makes the code a bit easier to
read.

* src/lisp.h (PVEC_USER_PTR, struct Lisp_User_Ptr, USER_PTRP)
(XUSER_PTR): Define unconditionally.

* src/data.c (Ftype_of):
* src/alloc.c (cleanup_vector):
* src/print.c (print_vectorlike):
* src/pdumper.c (dump_vectorlike): Remove #ifdef for user pointers.

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}".