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

128082 Commits

Author SHA1 Message Date
Dmitry Gutov
5b9f08fb86 Remove leftover references to log-view-message-face
* lisp/vc/vc-bzr.el (vc-bzr-log-view-mode): Use log-view-message.

* lisp/vc/vc-git.el (vc-git-root-log-format): Same.

* lisp/vc/vc-hg.el (vc-hg-root-log-format): Same.
2017-01-14 06:56:37 +03:00
Phillip Lord
72c668a904 Record autoloads till emacs dump
* admin/ldefs-clean.el (ldefs-clean-up): Record autoloads till emacs dump
* lisp/ldefs-boot-auto.el (batch-byte-compile): Update

Previously, autoloads were collected till loaddefs.el was generated as
part of the build. However, bootstrap-emacs does not load
loaddefs (rather it is dumped), hence we must record autoloads until the
full emacs binary is dumped.
2017-01-13 21:28:43 +00:00
Tom Tromey
502390822f Add chained indentation to js-mode
Bug#20896
* lisp/progmodes/js.el (js-chain-indent): New variable.
(js--skip-term-backward, js--skip-terms-backward)
(js--chained-expression-p): New functions.
(js--proper-indentation): Call js--chained-expression-p.
* test/manual/indent/js-chain.js: New file.
* test/manual/indent/js.js: Add (non-)chained indentation test.
2017-01-13 12:38:36 -07:00
Tom Tromey
b47f97218e Fix js-mode indentation bug
Bug#15582:
* lisp/progmodes/js.el (js--find-newline-backward): New function.
(js--continued-expression-p): Use it.
* test/manual/indent/js.js: Add new test.
2017-01-13 12:38:36 -07:00
Tom Tromey
cab7a38588 Fix definition of EMACS in test/manual/indent/Makefile
* test/manual/indent/Makefile (EMACS): Add one more "..".
2017-01-13 12:38:36 -07:00
Tom Tromey
765920f727 Add .jsx to auto-mode-alist
Bug#25389:
* lisp/files.el (auto-mode-alist): Add entry for .jsx.
2017-01-13 12:38:36 -07:00
Tom Tromey
05fe74bec2 Fix two js-mode filling bugs
Bug#19399 and Bug#22431:
* lisp/progmodes/js.el (js-mode): Set comment-line-break-function and
c-block-comment-start-regexp.
* test/lisp/progmodes/js-tests.el: New file.
2017-01-13 12:38:36 -07:00
Eli Zaretskii
d018843e0e Fix last change
* test/src/thread-tests.el (threads-condvar-wait): Revert
previous change.  Make sure no other threads from previous
tests are running, to avoid interfering with our thread counts.
2017-01-13 18:17:12 +02:00
Eli Zaretskii
26b5426de8 Fix the new condvar test
* test/src/thread-tests.el (threads-condvar-wait): Enlarge the
time we sleep in the main thread to let the other thread
process notifications.
2017-01-13 18:05:38 +02:00
Eli Zaretskii
9c4d2afaa5 Minor improvements in the new condvar test
* test/src/thread-tests.el (threads-test-condvar-wait): Use
with-mutex instead of emulating it inline.
(threads-condvar-wait): Improve comments.  Check that the new
thread is alive before waiting for it to become blocked on the
conditional variable.
2017-01-13 16:13:30 +02:00
Eli Zaretskii
03e4ab0d58 Fix a bug in waiting for condition variable
* src/thread.c (lisp_mutex_lock, lisp_mutex_unlock)
(lisp_mutex_unlock_for_wait, condition_wait_callback)
(condition_notify_callback): Improve commentary.
(condition_wait_callback): Call post_acquire_global_lock before
attempting to lock the mutex, to make sure the lock's owner is
recorded correctly.

* test/src/thread-tests.el (threads-condvar-wait): New test.
2017-01-13 11:48:51 +02:00
Katsumi Yamaoka
62e27ebd54 Fix last change of dd80ee6 (was: mm-uu.el: Don't dissect patch part) 2017-01-13 07:42:35 +00:00
Katsumi Yamaoka
dd80ee695c mm-uu.el: Don't dissect patch part
This fixes a bug that the patch part is broken in the article
<87inpjzhpb.fsf@users.sourceforge.net> in the bug-gnu-emacs list.

* lisp/gnus/mm-uu.el (mm-uu-dissect-text-parts):
Don't dissect patch part.
2017-01-13 07:22:30 +00:00
Dmitry Lazurkin
d4a97088f6 Fix extracting async def type and name in python mode imenu
* lisp/progmodes/python.el (python-imenu--get-defun-type-name):
New function.
(python-imenu--build-tree): Use python-imenu--get-defun-type-name for
extract async or simple def type and name at current
position (Bug#24820).
* test/lisp/progmodes/python-tests.el (python-imenu-create-index-1):
(python-imenu-create-flat-index-1): Add async def's.
2017-01-12 20:40:19 -05:00
Katsumi Yamaoka
55b5265847 Remove garbage from Content-Transfer-Encoding value (bug#25420)
* lisp/mail/ietf-drums.el (ietf-drums-strip-cte): New function.
(ietf-drums-remove-garbage): New function.
(ietf-drums-remove-whitespace): Remove CR as well.

* lisp/mail/mail-parse.el (mail-header-strip-cte):
Alias to ietf-drums-strip-cte.

* lisp/gnus/gnus-art.el (article-decode-charset):
* lisp/gnus/gnus-sum.el (gnus-summary-enter-digest-group):
* lisp/gnus/mm-decode.el (mm-dissect-buffer):
* lisp/gnus/nndoc.el (nndoc-decode-content-transfer-encoding)
(nndoc-rfc822-forward-generate-article):
* lisp/mh-e/mh-mime.el (mh-decode-message-body):
Replace mail-header-strip with mail-header-strip-cte.
2017-01-12 23:32:41 +00:00
Paul Eggert
70d6f2d14f Restore behavior of ‘./autogen.sh autoconf git’
* autogen.sh: Do both autoconf and git setup when invoked
as ‘./autogen.sh autoconf git’.  Avoid unnecessary newline in chatter.
Mention new --no-check option in usage message.  (Bug#25359)
2017-01-12 15:08:15 -08:00
Glenn Morris
3713c7a062 * autogen.sh: Simplify argument parsing. 2017-01-12 14:06:03 -05:00
Glenn Morris
d40073f017 * autogen.sh: Add --no-check option. (Bug#25359) 2017-01-11 15:01:28 -05:00
Glenn Morris
255f675d89 Convert some network test failures to skipping
These tests intermittently fail on hydra.nixos.org for unclear
reasons related to starting the external process.
This isn't an Emacs issue, and the failures cause noise on
the emacs-buildstatus list.  (Bug#24503)
* test/lisp/net/network-stream-tests.el (echo-server-nowait)
(connect-to-tls-ipv4-nowait): Skip rather than fail if the
external process fails to start properly.
2017-01-11 14:35:51 -05:00
Alexander Kuleshov
d569dd2198
Add DNS keywords and remove duplications
* lisp/textmodes/dns-mode.el (dns-mode-types): Add two TLSA and
NSEC" DNS related keywords and remove duplication of "NSAP".
2017-01-11 10:30:46 -08:00
Alan Mackenzie
6463b85aeb Handle syntactic WS cache properties more accurately at buffer changes.
This fixes bug #25362.

* lisp/progmodes/cc-engine.el (c-sws-lit-type, c-sws-lit-limits)
(c-invalidate-sws-region-before, c-invalidate-sws-region-after-del)
(c-invalidate-sws-region-after-ins): New variables and functions.
(c-invalidate-sws-region-after): Change from a defsubst to a defun.
Also pass
it the standard OLD-LEN argument.  Call both
c-invalidate-sws-region-after-{ins,del} to check for "dangerous" WS
cache
properties.

* lisp/progmodes/cc-langs.el (c-block-comment-ender-regexp): New language
variable.

* lisp/progmodes/cc-mode.el (c-before-change): Call
c-invalidate-sws-region-before.
(c-after-change): Pass old-len to c-invalidate-sws-region-after.
2017-01-11 18:25:39 +00:00
Michael Albinus
3a6df2d604 Support stat 8.26 in Tramp
* lisp/net/tramp-sh.el (tramp-get-remote-stat): Use QUOTING_STYLE
environment variable of newer coreutils.  (Bug#23422)
2017-01-11 17:13:41 +01:00
Paul Eggert
fa0a2b4e7c Merge from gnulib
This incorporates:
2017-01-09 maint: time stamp -> timestamp
2017-01-07 stdioext: Port to Minix 3.2 and newer
2017-01-06 glob, intprops, xalloc: work around Clang bug
2017-01-02 revert copyright-year change to synced files
* doc/misc/texinfo.tex, lib/fpending.c, lib/intprops.h, lib/mktime.c:
* lib/stat-time.h, lib/stdio-impl.h, lib/time.in.h, lib/timespec.h:
* lib/utimens.c, lib/xalloc-oversized.h:
Copy from gnulib.
2017-01-10 07:49:55 -08:00
Eli Zaretskii
560a384038 Don't use unsafe encoding for the bookmark file
* lisp/bookmark.el (bookmark-write-file): Handle the case when the
explicitly specified encoding of the bookmark file cannot encode the
additional bookmarks just added.  (Bug#25365)
2017-01-10 17:47:10 +02:00
Phillip Lord
ef8c9f8fc9 Remove unused ldefs-boot.el
* lisp/ldefs-boot.el: Remove

This file was not removed as reported in c27b645956, but accidentally
left.
2017-01-09 08:56:03 +00:00
Noam Postavsky
13c6f1d185 Use expanded stack during regex matches
While the stack is increased in main(), to allow the regex stack
allocation to use alloca we also need to modify regex.c to actually take
advantage of the increased stack, and not limit stack allocations to
SAFE_ALLOCA bytes.

* src/regex.c (MATCH_MAY_ALLOCATE): Remove obsolete comment about
allocations in signal handlers which no longer happens and correct
description about when and why MATCH_MAY_ALLOCATE should be defined.
(emacs_re_safe_alloca): New variable.
(REGEX_USE_SAFE_ALLOCA): Use it as the limit of stack allocation instead
of MAX_ALLOCA.
(emacs_re_max_failures): Rename from `re_max_failures' to avoid
confusion with glibc's `re_max_failures'.
* src/emacs.c (main): Increase the amount of fixed 'extra' bytes we add
to the stack.  Instead of changing emacs_re_max_failures based on the
new stack size, just change emacs_re_safe_alloca; emacs_re_max_failures
remains constant regardless, since if we run out stack space SAFE_ALLOCA
will fall back to heap allocation.

Co-authored-by: Eli Zaretskii <eliz@gnu.org>
2017-01-08 18:45:52 -05:00
Noam Postavsky
9a19f26cd7 Fix computation of regex stack limit
The regex stack limit was being computed as the number of stack entries,
whereas it was being compared with the current size as measured in
bytes.  This could cause indefinite looping when nearing the stack limit
if re_max_failures happened not to be a multiple of sizeof
fail_stack_elt_t (Bug #24751).

* src/regex.c (GROW_FAIL_STACK): Compute both current stack size and
limit as numbers of stack entries.
2017-01-08 18:45:52 -05:00
Alan Third
88a501b30d Remove apploopnr
* src/nsterm.m (ns_select, ns_read_socket): Remove apploopnr and only
allow app loop to run in main thread.
2017-01-08 21:29:35 +00:00
Glenn Morris
fc20bd940f Remove unused configure output variable
* configure.ac (GNULIB_MK):
* Makefile.in (gnulib_mk): Remove, no longer used.
2017-01-08 10:19:48 -08:00
Glenn Morris
25d3297bb9 Fix automake dependencies
* Makefile.in (AUTOMAKE_INPUTS): Add nt/gnulib.mk.  (Bug#25372)
All platforms need this file to exist.
2017-01-08 10:16:16 -08:00
Paul Eggert
8d7bdd7540 Remove unnecessary blankp code
* src/character.c (blankp): Remove redundant code that slows Emacs
down a bit.  The caller already does the test.
2017-01-08 10:07:00 -08:00
Stefan Merten
3d418bd46f * lisp/textmodes/rst.el: Fix rst-forward-indented-block.
* rst.el (rst-cvs-header, rst-svn-rev, rst-svn-timestamp)
	(rst-official-version, rst-official-cvs-rev)
	(rst-package-emacs-version-alist): Maintain version numbers.
	(rst-forward-indented-block): Fix. Start searching at next
	line again. Fixes fontification of comments continuing on the
	same line they started.
2017-01-08 11:09:10 +01:00
Paul Eggert
952d0f2ce4 Remove @SET_MAKE@ from manually-maintained files
Emacs now assumes GNU Make, so @SET_MAKE@ is no longer needed.
* Makefile.in, lwlib/Makefile.in, nextstep/Makefile.in:
* src/Makefile.in: Remove @SET_MAKE@.
2017-01-07 18:15:37 -08:00
Michael Albinus
77f35363fd Fix a problem with `start-file-process' in Tramp
* lisp/net/tramp-sh.el (tramp-maybe-open-connection):
`start-file-process' shall work when `non-essential' is
non-nil, but there is already an established connection.
<https://github.com/company-mode/company-mode/issues/462>
2017-01-07 18:51:30 +01:00
Rolf Ade
75cdf42917 Fix selecting SQLite database files with sql-mode (Bug#23566)
* lisp/progmodes/sql.el (sql-sqlite-login-params): Allow any name as
SQLite database file name, by default.
(sql-get-login-ext): Fixed read-file-name arguments to provide
path completion even if a database name pattern is customized and to
allow creation of new SQLite database files.

Copyright-paperwork-exempt: yes
2017-01-07 11:20:17 -05:00
Eli Zaretskii
e272032769 Specify encoding of the bookmark file
* lisp/bookmark.el (bookmark-insert-file-format-version-stamp):
Accept an argument CODING and include a 'coding:' cookie in the
bookmark file preamble.
(bookmark-upgrade-file-format-from-0): Call
'bookmark-insert-file-format-version-stamp' with the file buffer's
encoding, as detected when it was read.
(bookmark-file-coding-system): New variable.
(bookmark-load): Set bookmark-file-coding-system to the encoding
of the loaded file.
(bookmark-write-file): Bind coding-system-for-write to either the
user setting via "C-x RET c" or to the existing file encoding,
defaulting to 'utf-8-emacs'.  Update the value of
bookmark-file-coding-system.  (Bug#25365)
2017-01-07 14:33:41 +02:00
Eli Zaretskii
50fd04cd4b Avoid infloop in 'ispell-region'
* lisp/textmodes/ispell.el (ispell-begin-skip-region-regexp):
Protect against 'ispell-skip-region-alist' being nil.  Reported by
Ernest Adrogué <nfdisco@gmail.com>, see
http://lists.gnu.org/archive/html/help-gnu-emacs/2017-01/msg00007.html.
2017-01-07 13:02:50 +02:00
Philipp Stephani
512e9886be Add support for Unicode whitespace in [:blank:]
See Bug#25366.

* src/character.c (blankp): New function for checking Unicode
horizontal whitespace.
* src/regex.c (ISBLANK): Use 'blankp' for non-ASCII horizontal
whitespace.
(BIT_BLANK): New bit for range table.
(re_wctype_to_bit, execute_charset): Use it.
* test/lisp/subr-tests.el (subr-tests--string-match-p--blank): Add
unit test for [:blank:] character class.
* test/src/regex-tests.el (test): Adapt unit test.
* doc/lispref/searching.texi (Char Classes): Document new Unicode
behavior for [:blank:].
2017-01-06 20:12:48 +01:00
Stefan Monnier
8f0376309e (feedmail-deduce-address-list): Avoid add-to-list on local variables.
Author:

* lisp/mail/feedmail.el (feedmail-deduce-address-list):
Avoid add-to-list on local variables.
2017-01-05 21:02:48 -05:00
Noam Postavsky
69b9224a32 Fix isearch handling of C-u C-u...
* lisp/isearch.el: Add `isearch-scroll' property to
universal-argument-more so that `isearch-allow-scroll' will apply to it
as well.
(isearch-pre-command-hook): Let `isearch-allow-prefix' apply to
`universal-argument-more' as well (Bug#25302).
2017-01-05 20:20:42 -05:00
Paul Eggert
d1d9b37630 Shorten autogen.sh script
* autogen.sh: Use a shorter script, as some 'sed' implementations
mishandle long scripts.
2017-01-05 12:05:27 -08:00
Eli Zaretskii
ade6a024c8 Yet another fix for autogen.sh
* autogen.sh (gnulib.mk): Make the Sed script more portable.

* nt/Makefile.in (${srcdir}/gnulib.mk): Adapt the Sed command to
the changes in autogen.sh.
2017-01-05 21:36:58 +02:00
Eli Zaretskii
99af58d74e * autogen.sh (gnulib.mk): Another attempt to fix macOS build. 2017-01-05 19:48:49 +02:00
Eli Zaretskii
003954e67f Fix dependencies of nt/gnulib.mk
* Makefile.in ($(srcdir)/nt/gnulib.mk): Avoid circular dependency
of nt/gnulib.mk on lib/Makefile.in.
2017-01-05 18:04:54 +02:00
Eli Zaretskii
b5f157e935 Unbreak macOS build
* autogen.sh (gnulib.mk): Don't use non-portable extensions of GNU
Sed.
2017-01-05 17:55:43 +02:00
Johan Claesson
d88cdad284 Fix term.el handling of ^Z-sequences spanning chunks
Bash will after each command send ?\032 and the current directory "/tmp"
to inform term.el.  Bash output is buffered in 4096 bytes chunks.  If a
command outputs roughly 4096 bytes then the end of the first chunk will
be "/tm" (Bug#13350).

* lisp/term.el (term-emulate-terminal): Change the regexp to find the
end of the ?\032 sequence to use \n instead of $, the latter can match
end of string as well.

Copyright-paperwork-exempt: yes
2017-01-04 23:20:47 -05:00
Mark Oteiza
0392f942c7 Turn on lexical-binding in mb-depth.el
* lisp/mb-depth.el: Turn on lexical-binding.
(minibuffer-depth-setup): Bind things used multiple times.
2017-01-04 22:31:26 -05:00
Alan Third
308d596223 Revert "Rework NS event handling (bug#25265)"
This reverts commit e0e5b0f4a4.
2017-01-04 21:00:52 +00:00
Paul Eggert
44c588a25c Port recent autogen.sh changes to Darwin
Problem reported by Sam Steingold (Bug#25347).
* autogen.sh: Don't assume 'sed -f-' reads a script from stdin, as
POSIX does not require it and it does not work on Darwin.
2017-01-04 00:45:14 -08:00
Stefan Monnier
2ec41c415f Avoid add-to-list on local variables
* lisp/gnus/nnir.el: Use lexical-binding and cl-lib.
(nnir-retrieve-headers): Use pcase.
(nnir-search-thread): Avoid add-to-list on local variables.

* lisp/gnus/smime.el: Use lexical-binding and cl-lib.
(smime-verify-region): Avoid add-to-list on local variables.

* lisp/mail/undigest.el: Use lexical-binding and cl-lib.
(rmail-digest-parse-mime, rmail-digest-rfc1153)
(rmail-digest-parse-rfc934): Avoid add-to-list on local variable.

* lisp/net/ldap.el (ldap-search): Move init into declaration.

* lisp/net/newst-backend.el (newsticker--cache-add):
Avoid add-to-list on local variables; Simplify code with `assq'.

* lisp/net/zeroconf.el: Use lexical-binding and cl-lib.
(dbus-debug): Remove declaration, unused.
(zeroconf-service-add-hook, zeroconf-service-remove-hook)
(zeroconf-service-browser-handler, zeroconf-publish-service):
Avoid add-to-list and *-hook on local variables.

* lisp/org/org-archive.el (org-all-archive-files):
* lisp/org/org-agenda.el (org-agenda-get-restriction-and-command):
Avoid add-to-list on local variables.

* lisp/org/ox-publish.el (org-publish--run-functions): New function.
(org-publish-projects): Use it to avoid run-hooks on a local variable.
(org-publish-cache-file-needs-publishing): Avoid add-to-list on
local variables.

* lisp/progmodes/ada-prj.el: Use setq instead of (set '...).
(ada-prj-load-from-file): Avoid add-to-list on local variables.

* lisp/progmodes/ada-xref.el (ada-initialize-runtime-library): Simplify.
(ada-gnat-parse-gpr, ada-parse-prj-file-1)
(ada-xref-find-in-modified-ali): Avoid add-to-list on local variables.

* lisp/progmodes/idlw-shell.el (idlwave-shell-update-bp-overlays):
Avoid add-to-list on local variables.
2017-01-04 00:40:45 -05:00