Paul Eggert [Sun, 16 Oct 2016 23:25:47 +0000 (16:25 -0700)]
Port to Ubuntu 16.10, which needs gcc -nopie
* configure.ac (emacs_cv_prog_cc_no_pie): Rename from
emacs_cv_prog_cc_nopie. All usages changed. Check for -no-pie in
preference to -nopie (Bug#24682). Backport from master.
Eli Zaretskii [Sat, 15 Oct 2016 13:53:36 +0000 (16:53 +0300)]
Keep point when switching from and to *terminal* buffer
* lisp/term.el (term-reset-size): Don't reset the size if it
didn't change. If the size did change, restore point after
adjusting the size. (Bug#24465)
Eli Zaretskii [Fri, 14 Oct 2016 19:52:46 +0000 (22:52 +0300)]
Avoid crashes due to objects read with the #n=object form
* src/lread.c (read1): Use Fcons for 'placeholder', not AUTO_CONS,
because elements of the list in 'read_objects' cannot be allocated
off the stack. (Bug#24640)
Paul Eggert [Wed, 12 Oct 2016 16:16:31 +0000 (09:16 -0700)]
Port --enable-gcc-warnings to GCC 6.2.1
Backport from master.
* src/conf_post.h (GNUC_PREREQ): New macro.
* src/keyboard.c: Use it to work around GCC bug 54561.
* src/process.c (would_block): New function.
(server_accept_connection, wait_reading_process_output, send_process):
Use it.
Paul Eggert [Wed, 12 Oct 2016 16:01:03 +0000 (09:01 -0700)]
Work around Samba bug with ':' in symlink contents
* src/filelock.c (current_lock_owner): When reading the contents
of a lock, treat the UTF-8 for U+F022 as if it were ':' (Bug#24656).
Backport from master.
Eli Zaretskii [Wed, 12 Oct 2016 08:59:53 +0000 (11:59 +0300)]
Adapt GDB scripts to '--enable-check-lisp-object-type' builds
* etc/emacs-buffer.gdb <$qnil>: New variable.
(ybuffer-list, yset-buffer): Use $qnil for comparing against
'nil', as direct comparison with Qnil doesn't work in a build with
'--enable-check-lisp-object-type'.
* src/.gdbinit: Adapt commands of the temporary breakpoint in
init_sys_modes to a build with '--enable-check-lisp-object-type'.
Eli Zaretskii [Sat, 8 Oct 2016 19:31:14 +0000 (22:31 +0300)]
Allow to disable compaction of font caches
* src/font.c (syms_of_font) <inhibit-compacting-font-caches>: New
boolean variable.
* src/alloc.c (compact_font_caches): Use it to bypass the call to
compact_font_cache_entry. (Bug#24634) (Bug#24565)
Eli Zaretskii [Sat, 8 Oct 2016 19:03:51 +0000 (22:03 +0300)]
Allow selection of font for symbols as in Emacs 24.x
* src/fontset.c (syms_of_fontset) <use-default-font-for-symbols>:
New boolean variable.
(face_for_char): Use it to fall back to pre-Emacs 25.1 behavior
when selecting fonts for displaying symbol and punctuation
characters. (Bug#24644)
Eli Zaretskii [Sat, 8 Oct 2016 14:16:33 +0000 (17:16 +0300)]
; Fix last commit
* doc/lispref/functions.texi (Argument List): Restore the index
entry for 'wrong-number-of-arguments'. (Bug#24222)
* doc/lispref/errors.texi: Fix cross-reference for
'wrong-number-of-arguments'.
Eli Zaretskii [Sat, 8 Oct 2016 07:52:52 +0000 (10:52 +0300)]
Fix infloop in redisplay due to truncated lines and invisible text
* src/xdisp.c (forward_to_next_line_start): Don't call
'get_next_display_element' after finding the end of line. This
avoids setting the row's end position to the wrong value when the
next screen line begins with invisible text; that wrong value
caused set_cursor_from_row position the cursor in the wrong screen
line, and eventually triggered bug#24109.
Eli Zaretskii [Thu, 6 Oct 2016 15:08:31 +0000 (18:08 +0300)]
Fix compilation with MinGW runtime 3.22.2 and w32api 3.18.2
* nt/inc/ms-w32.h (_WIN32_WINNT) [!MINGW_W64]: Undefine before
defining to avoid redefinition warnings.
* nt/inc/sys/stat.h (_SYS_STAT_H, _INC_STAT_H): Define, to avoid
inclusion of sys/stat.h from the system headers, which could then
lead to compilation errors due to redefinition of 'struct stat'
etc. This is needed because latest versions of MinGW runtime
include sys/stat.h from wchar.h.
* src/image.c (__MINGW_MAJOR_VERSION) [WINDOWSNT]: Temporarily
redefine to 4 to avoid conflict between 2 definitions of
MemoryBarrier. (Bug#24613)
Karl Fogel [Tue, 4 Oct 2016 21:03:27 +0000 (16:03 -0500)]
Clarify that doc fixes are okay in feature freeze
* CONTRIBUTE (branches): Explain that doc fixes are always safe, even
on a release branch in feature freeze. Tweak wording of paragraph
after that to avoid a misleading contrast.
Eli Zaretskii [Tue, 4 Oct 2016 19:12:08 +0000 (22:12 +0300)]
Avoid crashes when setting the cursor
* src/xdisp.c (display_and_set_cursor): Don't index glyphs of a
glyph row if hpos is out of valid bounds. This avoids crashes in
some rare cases. (Bug#24614)
Karl Fogel [Mon, 3 Oct 2016 00:47:27 +0000 (19:47 -0500)]
Document yank behavior in the right place
* lisp/simple.el (yank): Document the handling of the
`yank-handled-properties' and `yank-excluded-properties' variables,
and the `yank-handler' text property.
(yank-pop): Refer to `yank' now (bug#286)
* lisp/subr.el (insert-for-yank): Refer to `yank' now.
(insert-for-yank-1): Refer to `insert-for-yank' now.
See this thread for discussion:
https://lists.gnu.org/archive/html/emacs-devel/2016-09/threads.html#00329
From: Karl Fogel
To: Emacs Devel
Subject: Question about intended behavior of 'insert-for-yank-1'.
Date: Mon, 12 Sep 2016 00:17:14 -0500
Message-ID: <874m5lr92d.fsf@red-bean.com>
It is useful to be able to call `isearch-done' unconditionally to
ensure a non-isearching state.
* lisp/isearch.el (isearch-done): Check that `isearch--current-buffer'
is a live buffer before using it (Bug #21091).
* test/lisp/isearch-tests.el (isearch--test-done): Test it.
* lisp/calendar/icalendar.el (icalendar--read-element): Avoid a regex
stack overflow by not using regex to extract values from calendar
events. (Bug#24315)
Paul Eggert [Tue, 27 Sep 2016 00:00:03 +0000 (17:00 -0700)]
Regexp Functions doc minor fixes
* doc/lispref/searching.texi (Regexp Functions):
Fix misspelling of “matching”. Use @table for table.
Reformat code example to fit into info file width (Bug#17862).
Eli Zaretskii [Mon, 26 Sep 2016 16:02:01 +0000 (19:02 +0300)]
Improve documentation of 'expand-abbrev' and wrapper hooks
* lisp/simple.el (filter-buffer-substring-functions)
(buffer-substring--filter): Add a link to 'with-wrapper-hook' as
the place to look for documentation of wrapper hooks.
* lisp/minibuffer.el (completion-in-region-functions)
(completion--in-region): Add a link to 'with-wrapper-hook' as the
place to look for documentation of wrapper hooks.
* lisp/abbrev.el (expand-abbrev, abbrev--default-expand): Clarify
the doc strings. (Bug#24540)
* doc/lispref/text.texi (Buffer Contents): Mention
'with-wrapper-hook's doc string as the place to learn about that
obsolete facility.
Eli Zaretskii [Fri, 23 Sep 2016 14:25:55 +0000 (17:25 +0300)]
Fix display of cursor when 'blink-cursor-delay' has small value
* lisp/frame.el (blink-cursor-check, blink-cursor-mode):
Protect ourselves against too small values of blink-cursor-delay.
This avoids erratic display of the cursor, or even failure to
display it, when user types text at high speed or leans on a key
to invoke the keyboard auto-repeat feature. (Bug#24372)
Noam Postavsky [Sat, 6 Aug 2016 02:11:00 +0000 (22:11 -0400)]
Fix debugging of string-match-p errors
* src/eval.c (call_debugger): Bind inhibit-changing-match-data to nil so
that debugger code that needs to do regexp match won't break
(Bug #23949, Bug #24166, Bug#16294).
Eli Zaretskii [Sat, 30 Jul 2016 08:32:02 +0000 (11:32 +0300)]
Fix region display while dragging mouse
* lisp/mouse.el (mouse-drag-track): Reset deactivate-mark in the
buffer of the drag event, to allow mark to be set and the region
be shown as we drag the mouse. (Bug#24030)
Eli Zaretskii [Sat, 21 May 2016 09:35:08 +0000 (12:35 +0300)]
Fix 'vertical-motion' and 'posn-at-point' under 'visual-line-mode'
* src/xdisp.c (move_it_in_display_line_to): Don't assume we can
wrap on a whitespace character if it's followed by another
whitespace character. When returning under WORD_WRAP for a screen
line that is continued, restore to wrap point when atpos/atx
position would be displayed on the next screen line due to
line-wrap. (Bug#23570)
Paul Eggert [Fri, 13 May 2016 20:30:33 +0000 (13:30 -0700)]
Improve display of tex-verbatim and Info quoted
Problem reported by Glenn Morris (Bug#19889).
* doc/emacs/display.texi (Standard Faces):
* doc/lispref/display.texi (Basic Faces):
* etc/NEWS: Mention fixed-pitch-serif.
* lisp/faces.el (face-font-family-alternatives):
New family alias Monospace Serif.
(fixed-pitch-serif): New face, which uses the new family.
* lisp/info.el (Info-quoted):
* lisp/textmodes/tex-mode.el (tex-verbatim): Use the new face.
* test/lisp/legacy/font-parse-tests.el (font-parse-tests--data):
Add test case for Monospace Serif.
Run find-function-after-hook after finding a symbol
* lisp/emacs-lisp/find-func.el (find-library):
* lisp/help-mode.el (help-function-def, help-variable-def):
Run `find-function-after-hook' inside the help-function of the
buttons (bug#22583).
* etc/NEWS: Mention the change.
Eli Zaretskii [Fri, 23 Sep 2016 08:27:18 +0000 (11:27 +0300)]
Improve documentation of overlay priorities
* doc/lispref/display.texi (Overlay Properties): Minor copyedits.
By popular demand, mention the '(PRIMNARY . SECONDARY)' form of
overlay properties used for the region. (Bug#20253)
Eli Zaretskii [Fri, 23 Sep 2016 08:08:34 +0000 (11:08 +0300)]
Fix 'dired-compress-files'
* lisp/dired-aux.el (dired-do-compress-to): Make sure the archive
file name is fully expanded by running it through
'expand-file-name'. Suggested by Drew Adams <drew.adams@oracle.com>.
(Bug#24486) Doc fix.
* lisp/dired.el: Regenerated changes in autoloads.
Eli Zaretskii [Fri, 23 Sep 2016 07:52:07 +0000 (10:52 +0300)]
Update commentary of STRING_CHAR and FETCH_MULTIBYTE_CHAR
* src/character.h (STRING_CHAR):
* src/buffer.h (FETCH_MULTIBYTE_CHAR): Update commentary: these
two macros no longer do any character unification, so the caveats
in those comments are no longer pertinent.
Eli Zaretskii [Wed, 21 Sep 2016 15:10:29 +0000 (18:10 +0300)]
Fix tagging of DEFUN by etags
* lib-src/etags.c (C_entries): Tag DEFUN twice: once with its C
name, and then again with its Lisp name. This restores the
ability to find Lisp primitives by their C name, which was lost
when the etags back-end was switched to a more strict search
criteria.
* test/etags/ETAGS.good_1:
* test/etags/ETAGS.good_2:
* test/etags/ETAGS.good_3:
* test/etags/ETAGS.good_4:
* test/etags/ETAGS.good_5:
* test/etags/ETAGS.good_6:
* test/etags/CTAGS.good: Adapt to the changes in etags.c wrt
tagging DEFUN.
Eli Zaretskii [Wed, 21 Sep 2016 15:00:18 +0000 (18:00 +0300)]
Avoid resetting track-mouse by mouse clicks
* lisp/mouse.el (mouse-drag-line, mouse-drag-track): Don't assume
the previous value of track-mouse is nil; instead, save and
restore the previous value. (Bug#24480)
Eli Zaretskii [Sat, 17 Sep 2016 09:20:09 +0000 (12:20 +0300)]
Document that desktop file overrides frame parameters
* doc/emacs/misc.texi (Saving Emacs Sessions):
* doc/emacs/frames.texi (Frame Parameters): Document that frame
parameters restored by desktop.el take precedence over the
customizations in the init file, and explain how to countermand
that. For the details of the issue, see
http://lists.gnu.org/archive/html/emacs-devel/2016-09/msg00318.html.
* src/window.h (WINDOW_MODE_LINE_HEIGHT, WINDOW_HEADER_LINE_HEIGHT): Fix
confusing claim that "height is in pixels and in lines"; in fact it's in
pixels.
Fix 'url-http-create-request' when cookies are used
* lisp/url/url-http.el (url-http-create-request): Make sure the
cookie headers are a unibyte string. For the details, see
http://lists.gnu.org/archive/html/emacs-devel/2016-09/msg00202.html.
Eli Zaretskii [Fri, 26 Aug 2016 19:13:34 +0000 (22:13 +0300)]
Clarify documentation of precision in format specs
* doc/lispref/strings.texi (Formatting Strings): Be less
definitive wrt what precision means in format specs other than
floating-point, %s and %S. (Bug#24314)
Eli Zaretskii [Wed, 24 Aug 2016 14:36:28 +0000 (17:36 +0300)]
Improve and clarify documentation of subprocesses
* doc/lispref/processes.texi (Subprocess Creation, Shell Arguments):
Mention 'make-process' rather than 'start-process'. Update wrt
standard destinations of standard output/error streams and due to
different formats of arguments accepted by 'make-process'.
(Processes): Mention process objects that represent connections.
(Synchronous Processes): Minor clarifications.
(Asynchronous Processes): Describe 'make-process' and
'make-pipe-process' before 'start-process'. Update and expand the
documentation.
(Deleting Processes, Process Information, Input to Processes)
(Signals to Processes, Query Before Exit, Network): Update and
expand the documentation, especially wrt process objects that
represent connections.
(Output from Processes): Mention the possibility of separating
stderr via 'make-process'.
(Filter Functions): Mention that stderr by default arrives at the
filter function together with stdout. (Bug#24287)
* src/process.c (Fprocess_id, Fprocess_command)
(Fprocess_contact, Fprocess_type, Fstop_process): Doc fixes for
process objects that represent connections.
Philipp Stephani [Fri, 19 Aug 2016 19:23:24 +0000 (21:23 +0200)]
Some assorted documentation clarifications
* src/fileio.c (Fwrite_region): Clarify that END is ignored if
START is nil.
* src/editfns.c (Fbuffer_size): Add short discussion about
narrowing.
* src/callproc.c (Fcall_process_region): Discuss behavior when
START and END are not buffer positions.
Eli Zaretskii [Thu, 18 Aug 2016 14:23:22 +0000 (17:23 +0300)]
Improve commentary in src/character.h
* src/character.h (BYTES_BY_CHAR_HEAD, MULTIBYTE_LENGTH)
(MULTIBYTE_LENGTH_NO_CHECK, STRING_CHAR_AND_LENGTH): Remove stale
info from commentary and improve it.