1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2025-01-06 11:55:48 +00:00
Commit Graph

125457 Commits

Author SHA1 Message Date
Paul Eggert
d2ea891fca Merge from origin/emacs-25
91e6676 Fix an Isearch var to be a string (Bug#23038)
76ef522 Fix (args-out-of-range 1) error in cursor-sensor--detect
2016-03-22 11:04:37 -07:00
Paul Eggert
656058b790 ; Merge from origin/emacs-25
The following commits were skipped:

8a35f83 Render empty <ul><li><ul> correctly
d8b2ce5 Ignore invalid base64 encoded embedded images
52ba24b Fix <p> and <div> newlines with or without <li> in shr
2016-03-22 11:04:36 -07:00
Paul Eggert
f95bbe5a67 - 2016-03-22 11:04:36 -07:00
Paul Eggert
4869e0d85a ; Merge from origin/emacs-25
The following commit was skipped:

9ab03f2 ; Auto-commit of loaddefs files.
2016-03-22 11:01:30 -07:00
Paul Eggert
37b9099068 - 2016-03-22 11:01:30 -07:00
Paul Eggert
6bd1e22034 Keep "merge" commits by default in gitmerge
* admin/gitmerge.el (gitmerge-skip-regexp): Omit "merge", as it
causes false positives.  See:
http://lists.gnu.org/archive/html/emacs-devel/2016-03/msg01234.html
2016-03-22 10:52:54 -07:00
Paul Eggert
780a605e1d Assume NON_BLOCKING_CONNECT (Bug#22946)
* lisp/proced.el (proced-signal-list): Omit comment about
obsolete systems that do not support POSIX 1003.1-2001 signals.
* src/process.c (NON_BLOCKING_CONNECT): Remove, since we can now
assume POSIX 1003.1-2001 or better here.  Assume it’s defined.
(connect_network_socket): Assume EINPROGRESS is defined,
as that’s portable too now.
(Fmake_network_process): Use bool for boolean.
2016-03-22 01:19:03 -07:00
Eli Zaretskii
7dba17670f Fix problems caused by new implementation of sub-word mode
* lisp/subr.el (forward-word-strictly, backward-word-strictly):
New functions.
(word-move-empty-char-table): New variable.

* etc/NEWS: Mention 'forward-word-strictly' and
'backward-word-strictly'.

* doc/lispref/positions.texi (Word Motion): Document
'find-word-boundary-function-table', 'forward-word-strictly', and
'backward-word-strictly'.  (Bug#22560)

* src/syntax.c (syms_of_syntax)
<find-word-boundary-function-table>: Doc fix.

* lisp/wdired.el (wdired-xcase-word):
* lisp/textmodes/texnfo-upd.el (texinfo-copy-node-name)
(texinfo-copy-section-title, texinfo-start-menu-description)
(texinfo-copy-menu-title, texinfo-specific-section-type)
(texinfo-insert-node-lines, texinfo-copy-next-section-title):
* lisp/textmodes/texinfo.el (texinfo-clone-environment)
(texinfo-insert-@end):
* lisp/textmodes/texinfmt.el (texinfo-format-scan)
(texinfo-anchor, texinfo-multitable-widths)
(texinfo-multitable-item):
* lisp/textmodes/tex-mode.el (latex-env-before-change):
* lisp/textmodes/flyspell.el (texinfo-mode-flyspell-verify):
* lisp/skeleton.el (skeleton-insert):
* lisp/simple.el (count-words):
* lisp/progmodes/vhdl-mode.el (vhdl-beginning-of-libunit)
(vhdl-beginning-of-defun, vhdl-beginning-of-statement-1)
(vhdl-update-sensitivity-list, vhdl-template-block)
(vhdl-template-break, vhdl-template-case, vhdl-template-default)
(vhdl-template-default-indent, vhdl-template-for-loop)
(vhdl-template-if-then-use, vhdl-template-bare-loop)
(vhdl-template-nature, vhdl-template-procedural)
(vhdl-template-process, vhdl-template-selected-signal-asst)
(vhdl-template-type, vhdl-template-variable)
(vhdl-template-while-loop, vhdl-beginning-of-block)
(vhdl-hooked-abbrev, vhdl-port-copy, vhdl-hs-forward-sexp-func):
* lisp/progmodes/verilog-mode.el (verilog-backward-sexp)
(verilog-forward-sexp, verilog-beg-of-statement)
(verilog-set-auto-endcomments, verilog-backward-token)
(verilog-do-indent):
* lisp/progmodes/vera-mode.el (vera-guess-basic-syntax)
(vera-indent-block-closing):
* lisp/progmodes/simula.el (simula-context)
(simula-backward-up-level, simula-forward-down-level)
(simula-previous-statement, simula-next-statement)
(simula-skip-comment-backward, simula-calculate-indent)
(simula-find-if, simula-electric-keyword):
* lisp/progmodes/sh-script.el (sh-smie--rc-newline-semi-p):
* lisp/progmodes/ruby-mode.el (ruby-smie--redundant-do-p)
(ruby-smie--forward-token, ruby-smie--backward-token)
(ruby-singleton-class-p, ruby-calculate-indent)
(ruby-forward-sexp, ruby-backward-sexp):
* lisp/progmodes/ps-mode.el (ps-run-goto-error):
* lisp/progmodes/perl-mode.el (perl-syntax-propertize-function)
(perl-syntax-propertize-special-constructs)
(perl-backward-to-start-of-continued-exp):
* lisp/progmodes/pascal.el (pascal-indent-declaration):
* lisp/progmodes/octave.el (octave-function-file-p):
* lisp/progmodes/mantemp.el (mantemp-insert-cxx-syntax):
* lisp/progmodes/js.el (js--forward-function-decl):
* lisp/progmodes/idlwave.el (idlwave-show-begin-check)
(idlwave-beginning-of-block, idlwave-end-of-block)
(idlwave-block-jump-out, idlwave-determine-class):
* lisp/progmodes/icon.el (icon-is-continuation-line)
(icon-backward-to-start-of-continued-exp, end-of-icon-defun):
* lisp/progmodes/hideif.el (hide-ifdef-define):
* lisp/progmodes/f90.el (f90-change-keywords):
* lisp/progmodes/cperl-mode.el (cperl-electric-pod)
(cperl-linefeed, cperl-electric-terminator)
(cperl-find-pods-heres, cperl-fix-line-spacing)
(cperl-invert-if-unless):
* lisp/progmodes/cc-engine.el (c-forward-<>-arglist-recur):
* lisp/progmodes/cc-align.el (c-lineup-java-inher):
* lisp/progmodes/ada-mode.el (ada-compile-goto-error)
(ada-adjust-case-skeleton, ada-create-case-exception)
(ada-create-case-exception-substring)
(ada-case-read-exceptions-from-file, ada-after-keyword-p)
(ada-scan-paramlist, ada-get-current-indent, ada-get-indent-end)
(ada-get-indent-if, ada-get-indent-block-start)
(ada-get-indent-loop, ada-get-indent-type)
(ada-search-prev-end-stmt, ada-check-defun-name)
(ada-goto-decl-start, ada-goto-matching-start)
(ada-goto-matching-end, ada-looking-at-semi-or)
(ada-looking-at-semi-private, ada-in-paramlist-p)
(ada-search-ignore-complex-boolean, ada-move-to-start)
(ada-move-to-end, ada-which-function, ada-gen-treat-proc):
* lisp/net/quickurl.el (quickurl-grab-url):
* lisp/mail/sendmail.el (mail-do-fcc):
* lisp/mail/rmail.el (rmail-resend):
* lisp/mail/mailabbrev.el (mail-abbrev-complete-alias):
* lisp/mail/mail-extr.el (mail-extract-address-components):
* lisp/json.el (json-read-keyword):
* lisp/files.el (insert-directory):
* lisp/emacs-lisp/checkdoc.el (checkdoc-this-string-valid-engine):
* lisp/completion.el (symbol-under-point, symbol-before-point)
(symbol-before-point-for-complete, next-cdabbrev)
(add-completions-from-c-buffer):
* lisp/cedet/semantic/texi.el (semantic-up-context)
(semantic-beginning-of-context):
* lisp/cedet/semantic/bovine/el.el (semantic-get-local-variables):
use 'forward-word-strictly' and 'backward-word-strictly' instead
of 'forward-word' and 'backward-word'.

[This reapplies commit c1d32a6537,
which was inadvertently lost by merge commit
c71e7cc113ed0d5f01aaa2e441a3e3c9fbeb9fa5.]
2016-03-21 17:47:22 -07:00
Paul Eggert
22cd92a0f3 * etc/TODO: Minor quoting and grammar fixes.
[This reapplies commit 433407d823,
which was inadvertently lost by merge commit
5ab243f40e4db91586ff74b01a775a5218a1d5be.]
2016-03-21 17:47:22 -07:00
Alan Mackenzie
515ce25ffd Don't confuse "::" with ":" when trying to parse member initializers.
* lisp/progmodes/cc-engine.el (c-back-over-member-initializers): Check
more robustly for ":" token when searching backwards for it.

* lisp/progmodes/cc-langs (c-:$-multichar-token-regexp): New language
variable.

[This reapplies commit 9e5452f716,
which was inadvertently lost by merge commit
7823745acbe9b87eea2db4ef434e379fc903ec35.]
2016-03-21 17:05:55 -07:00
Eli Zaretskii
a17bddeaa4 Ensure positive number of glyphs for margins of positive width
* src/dispnew.c (margin_glyphs_to_reserve): Always return a
positive value when a non-zero width of the marginal area was
requested.  (Bug#22356)

[This reapplies commit 740849fe98,
which was inadvertently lost by merge commit
7823745acbe9b87eea2db4ef434e379fc903ec35.]
2016-03-21 17:05:55 -07:00
Alan Mackenzie
5a78876770 In comment-dwim with style `extra-line', respect indent-tabs-mode.
This fixes bug #22369.

* lisp/newcomment.el (comment-make-bol-ws): New function.
(comment-make-extra-lines): Use new function instead of a crude `make-string'.

[This reapplies commit 016b3d5894,
which was inadvertently lost by merge commit
7823745acbe9b87eea2db4ef434e379fc903ec35.]
2016-03-21 17:05:55 -07:00
Eli Zaretskii
05b6268078 Merge doc fixes for 'random' lost in previous merge
[This reapplies part of commit
3ffe81e245,
which was inadvertently lost by merge commit
7823745acbe9b87eea2db4ef434e379fc903ec35.]
(Bug#22202)
2016-03-21 17:05:55 -07:00
Eli Zaretskii
a1f71da92d Unhide the --no-line-directive option to 'etags'
* lib-src/etags.c (print_help): Un-undocument the --no-line-directive
option.  (Bug#22306)

* doc/man/etags.1: Document the --no-line-directive option.

[This reapplies commit fee0526a18,
which was inadvertently lost by merge commit
7823745acbe9b87eea2db4ef434e379fc903ec35.]
2016-03-21 17:05:55 -07:00
Alan J Third
1e9a1229b1 Fix picture-mode wrt double-width characters
* lisp/textmodes/picture.el (picture-insert): Check the width of
the character being replaced, not just that of the replacement.
(Bug#1808)

[This reapplies commit b70dba4e18,
which was inadvertently lost by merge commit
7823745acbe9b87eea2db4ef434e379fc903ec35.]

Copyright-paperwork-exempt: yes
2016-03-21 17:05:54 -07:00
Eli Zaretskii
fa5c69c0a3 ; * etc/NEWS: Remove unneeded text.
[This reapplies commit 2bc07f7a2a,
which was inadvertently lost by merge commit
7823745acbe9b87eea2db4ef434e379fc903ec35.]
2016-03-21 17:05:54 -07:00
Kaushal Modi
91e667692b Fix an Isearch var to be a string (Bug#23038)
* isearch.el (isearch--describe-regexp-mode): The `description' var
  needs to always be a string.  Add the missing default case for the
  cond form that ensures that.

Before this bug fix, for the events when `regexp-function' and
`search-default-mode' both were nil, `description' also stayed nil.  So
when `space-before' was non-nil, the "non-string" `description'
(with a value of nil) got passed as an argument to
`replace-regexp-in-string' (where a string was expected).  That caused
the error described in Bug#23038.
2016-03-22 01:05:24 +01:00
Leo Liu
76ef52267c Fix (args-out-of-range 1) error in cursor-sensor--detect
* lisp/emacs-lisp/cursor-sensor.el (cursor-sensor--detect): Don't
  hard-code (point-min) as 1 which fails in narrowed buffers.
2016-03-21 18:26:40 +08:00
Martin Rudalics
5283593ced Resurrect earlier fix of resize_frame_windows
* src/window.c (resize_frame_windows): Resurrect earlier fix for
calculating the number of columns of the minibuffer window which
was lost in subsequent merges.
2016-03-20 16:52:39 +01:00
Lars Magne Ingebrigtsen
68f1342204 Move the cert files to the data directory 2016-03-20 16:08:55 +01:00
Lars Magne Ingebrigtsen
78bcd42857 Further empty <li> tweaks
* lisp/net/shr.el (shr-tag-li): When showing several empty
<li> elements, ensure that they really get inserted on a new line.
2016-03-20 15:15:32 +01:00
Lars Magne Ingebrigtsen
61b2e837d8 Don't remove too much white space at the end of documents
* lisp/net/shr.el (shr--remove-blank-lines-at-the-end): Don't
remove too much white space -- leave it on the last line (in
case there's a background color).
2016-03-20 14:47:30 +01:00
Alan Mackenzie
9dcf599893 Amend parse-partial-sexp correctly to handle two character comment delimiters
Do this by adding a new field to the parser state: the syntax of the last
character scanned, should that be the first char of a (potential) two char
construct, nil otherwise.
This should make the parser state complete.
Also document element 9 of the parser state.  Also refactor the code a bit.

* src/syntax.c (struct lisp_parse_state): Add a new field.
(SYNTAX_FLAGS_COMSTARTEND_FIRST): New function.
(internalize_parse_state): New function, extracted from scan_sexps_forward.
(back_comment): Call internalize_parse_state.
(forw_comment): Return the syntax of the last character scanned to the caller
when that character might be the first of a two character construct.
(Fforward_comment, scan_lists): New dummy variables, passed to forw_comment.
(scan_sexps_forward): Remove a redundant state parameter.  Access all `state'
information via the address parameter `state'.  Remove the code which converts
from external to internal form of `state'.  Access buffer contents only from
`from' onwards.  Reformulate code at the top of the main loop correctly to
recognize comment openers when starting in the middle of one.  Call
forw_comment with extra argument (for return of syntax value of possible first
char of a two char construct).
(Fparse_partial_sexp): Document elements 9, 10 of the parser state in the
doc string.  Clarify the doc string in general.  Call
internalize_parse_state.  Take account of the new elements when consing up the
output parser state.

* doc/lispref/syntax.texi: (Parser State): Document element 9 and the new
element 10.  Minor wording corrections (remove reference to "trivial
cases").
(Low Level Parsing): Minor corrections.

* etc/NEWS: Note new element 10, and documentation of element 9 of parser
state.
2016-03-20 13:19:48 +00:00
Lars Magne Ingebrigtsen
565df7265d Allow the shr test files to have trailing blank space.
* .gitattributes: Allow the shr test files to have trailing
blank space.
2016-03-20 14:07:47 +01:00
Lars Magne Ingebrigtsen
ebe63f43df Add tests for empty <ul><li> 2016-03-20 14:07:24 +01:00
Lars Magne Ingebrigtsen
8a35f83c6c Render empty <ul><li><ul> correctly
* lisp/net/shr.el (shr-tag-ul): Render empty <ul><li><ul>
correctly (bug#22964).
(cherry picked from commit 4f6ea3988b)

Backport:
2016-03-20 13:58:26 +01:00
Paul Eggert
17ba74742c * src/alloc.c (purecopy): Use AUTO_STRING. 2016-03-20 05:58:17 -07:00
Lars Magne Ingebrigtsen
d8b2ce5f8a Ignore invalid base64 encoded embedded images
* lisp/net/shr.el (shr-image-from-data): Ignore invalid base64
encoded embedded images (bug#22928).
(cherry picked from commit f2da80d0e1)

Backport:
2016-03-20 13:58:04 +01:00
Lars Magne Ingebrigtsen
f2da80d0e1 Ignore invalid base64 encoded embedded images
* lisp/net/shr.el (shr-image-from-data): Ignore invalid base64
encoded embedded images (bug#22928).
2016-03-20 13:57:11 +01:00
Lars Magne Ingebrigtsen
4f6ea3988b Render empty <ul><li><ul> correctly
* lisp/net/shr.el (shr-tag-ul): Render empty <ul><li><ul>
correctly (bug#22964).
2016-03-20 13:52:36 +01:00
Lars Magne Ingebrigtsen
52ba24bdd9 Fix <p> and <div> newlines with or without <li> in shr
* lisp/net/shr.el (shr-ensure-newline): Respect that we're in
a <li>, if we are, and don't insert newlines there.
(shr-ensure-paragraph): When mixing newlines and paragraph
ensurements, don't insert too many blank lines.
(shr-tag-div): A <div> shouldn't introduce a paragraph, but a
new line.
(cherry picked from commit 292921faca)

Backport:
2016-03-20 13:45:09 +01:00
Lars Magne Ingebrigtsen
292921faca Fix <p> and <div> newlines with or without <li> in shr
* lisp/net/shr.el (shr-ensure-newline): Respect that we're in
a <li>, if we are, and don't insert newlines there.
(shr-ensure-paragraph): When mixing newlines and paragraph
ensurements, don't insert too many blank lines.
(shr-tag-div): A <div> shouldn't introduce a paragraph, but a
new line.
2016-03-20 13:43:42 +01:00
Lars Magne Ingebrigtsen
21c89971c3 Add more shr HTML rendering tests 2016-03-20 13:41:59 +01:00
Lars Magne Ingebrigtsen
4f9c775700 Add a test harness for shr HTML rendering and one test 2016-03-20 12:55:36 +01:00
Lars Magne Ingebrigtsen
c688c44ddf Remove code left over from when overlays were used for padding
* lisp/net/shr.el (shr-previous-newline-padding-width): Remove.
(shr-remove-trailing-whitespace): Ditto.
(shr-insert-document): Don't call them.
2016-03-20 12:54:24 +01:00
Lars Magne Ingebrigtsen
35d58020b6 Remove trailing blank lines in shr
* lisp/net/shr.el (shr--remove-blank-lines-at-the-end): New function.
(shr-insert-document): Use it to remove trailing blank lines
at the end of documents, since these never seem to be very useful.
2016-03-20 12:52:28 +01:00
Lars Magne Ingebrigtsen
0b7836dda6 Don't bug out on nil `patch-buf' arguments
* lisp/vc/ediff.el (ediff-patch-file): Don't bug out on nil
`patch-buf' arguments.
2016-03-20 12:12:27 +01:00
Ernest Adrogué
6e70769e31 Add a Catalan language environment
* international/mule-cmds.el (locale-language-names): Map locale
  language name `ca' to language environment `Catalan'.

* language/european.el: Add definition of language environment for
  the Catalan language.

* leim/quail/latin-pre.el: Add quail rule to the `catalan-prefix'
  input method to support input of middle dot characters through
  composition (bug#18279).
2016-03-20 12:01:23 +01:00
Paul Eggert
9d5f235112 No need to block input when reading directories
* src/dired.c: Don’t include blockinput.h.
(open_directory, directory_files_internal_unwind)
(directory_files_internal, file_attributes):
Don’t block input here, as the reasons for blocking input should
no longer apply.  See blockinput.h FIXME.  (Bug#22996).
2016-03-19 18:45:09 -07:00
Eli Zaretskii
b8ea08b037 Avoid errors in 'newline'
* lisp/simple.el (newline): Don't barf if invoked with
non-positive argument in the middle of a line.  (Bug#22490)
2016-03-19 21:32:27 +02:00
Oscar Fuentes
070b9de4e3 * lisp/vc/vc-hooks.el: Fix typo 2016-03-19 18:57:43 +01:00
Michael Albinus
fc3cd53900 Fix Bug#23032
* doc/misc/eshell.texi (Arguments): Mention the pipe symbol in
remote file names.  (Bug#23032)
2016-03-19 16:51:46 +01:00
Fabrice Popineau
326fff41fa Improve w32notify notifications
* src/w32notify.c (DIRWATCH_BUFFER_SIZE): New macro.
(struct notification): 'terminate' is now a HANDLE.
(send_notifications): Argument is now a pointer to a
notification.  Don't loop waiting for the notification to be
acknowledged by the main thread; instead, just add the
notification to the linked list of notifications waiting to be
acknowledged.
(watch_end): Don't close the directory handle.
(watch_completion): Allocate a new notification structure to be
added to the notifications set.  Call ReadDirectoryChangesW
immediately after adding the new notification, and before sending
a message to the main thread about them.
(watch_worker): Don't loop calling ReadDirectoryChangesW; instead,
call it just once -- it will be called again in watch_completion.
Loop waiting for the main thread's indication to terminate.
(start_watching): Create the event to be used to indicate to the
worker thread that its should terminate.
(remove_watch): Indicate to the worker thread that it should
terminate.
* src/w32term.c (queue_notifications): Loop over all the
notifications in the linked list, processing all of them in one
go.
* src/w32inevt.c (handle_file_notifications): Loop over all the
notifications in the linked list.
* src/w32xfns.c (init_crit): Initialize the linked list of file
notifications.
(delete_crit): Free the linked list of file notifications,
including any unprocessed notifications left in it.
* src/w32term.h (struct notifications_se): New struct.

* test/lisp/filenotify-tests.el (file-notify-test02-events)
(file-notify-test05-dir-validity): Add read-event calls to
facilitate event recognition by the main thread in batch mode.
2016-03-19 14:44:53 +02:00
Eli Zaretskii
dd2737b375 Adjudicate review comments in abbrevs.texi
* doc/lispref/abbrevs.texi (Abbrev Files, Abbrev Expansion):
* doc/emacs/abbrevs.texi (Dabbrev Customization): State the
default values of variables.  Suggested by Steve Byrne
<sbb@penguinis.org>.  (Bug#23016)

* admin/release-process (Check manuals): Mark files reviewed by
Steve Byrne.
2016-03-19 13:05:55 +02:00
Dmitry Gutov
26f9c5075f Fixup the "normal" matcher; highlight global var symbols, too
* lisp/progmodes/ruby-mode.el (ruby-font-lock-keywords): Highlight
operator name symbols with the "normal" matcher (it actually
needed updating).  Highlight global variable symbols, too.
2016-03-19 00:37:54 +02:00
Tassilo Horn
413e73b5db ; Small theme additions 2016-03-18 23:29:58 +01:00
Marcin Borkowski
cd950da9db Honor prefix arg in doc-view-next-line-or-next-page
* lisp/doc-view.el (doc-view-next-line-or-next-page): Take the
prefix argument into consideration when continuous scrolling is
not in effect (i.e., by default) (bug#19559).
2016-03-18 22:46:42 +01:00
Paul Eggert
ed909c049e ; Spelling fixes 2016-03-18 08:55:26 -07:00
Paul Eggert
6da3a6dc9e Port to strict C99 offsetof
* src/bidi.c (bidi_copy_it):
* src/lisp.h (CHAR_TABLE_EXTRA_SLOTS):
Use only a single identifier as the second argument of offsetof.
Found by using clang -pedantic.
2016-03-18 08:43:32 -07:00
Paul Eggert
de7601f149 Port to GTK with strict C11 compiler
* src/gtkutil.c (xg_create_frame_widgets, xg_toggle_notify_cb):
Cast from function type to void * where the C standard requires this.
This works around a problem in the prototypes for
g_signal_handler_find and g_signal_handlers_block_by_func, which
use gpointer instead of GCallback.  Found by using gcc -pedantic.
2016-03-18 08:43:32 -07:00