]> code.delx.au - gnu-emacs/log
gnu-emacs
9 years agoFix a false negative in `map-elt' with alists and values being nil
Nicolas Petton [Sat, 25 Apr 2015 10:07:12 +0000 (12:07 +0200)]
Fix a false negative in `map-elt' with alists and values being nil

* lisp/emacs-lisp/map.el (map-elt): If map is an alist and key is
found but its associated value is nil, do not return the default
value.

* test/automated/map-tests.el: Add a regression test.

9 years ago* lisp/emacs-lisp/map.el (map--dispatch): Improve the docstring.
Nicolas Petton [Fri, 24 Apr 2015 17:33:18 +0000 (19:33 +0200)]
* lisp/emacs-lisp/map.el (map--dispatch): Improve the docstring.

9 years agoDo not signal an error when trying to delete a key from an array
Nicolas Petton [Fri, 24 Apr 2015 17:29:59 +0000 (19:29 +0200)]
Do not signal an error when trying to delete a key from an array

* lisp/emacs-lisp/map.el (map-delete): When map is an array, check if
the key is present to avoid signaling an error.

* test/automated/map-tests.el: Add a test for deleting non-existing
keys from maps.

9 years ago* lisp/emacs-lisp/map.el: Better docstring.
Nicolas Petton [Fri, 24 Apr 2015 17:15:23 +0000 (19:15 +0200)]
* lisp/emacs-lisp/map.el: Better docstring.

9 years agoMinor improvement in map-elt.
Nicolas Petton [Fri, 24 Apr 2015 17:06:27 +0000 (19:06 +0200)]
Minor improvement in map-elt.

* lisp/emacs-lisp/map.el (map-elt): Do not use `ignore-errors' when
doing a lookup in arrays, but check the boundaries of the array
instead.

* test/automated/map-tests.el: Adds a test for `map-elt' with arrays
and a negative integer as key.

9 years ago* test/automated/map-tests.el: Refactoring of test methods.
Nicolas Petton [Tue, 21 Apr 2015 18:53:28 +0000 (20:53 +0200)]
* test/automated/map-tests.el: Refactoring of test methods.

9 years ago* test/automated/map-tests.el: Renamed from map-test.el.
Nicolas Petton [Tue, 21 Apr 2015 17:40:57 +0000 (19:40 +0200)]
* test/automated/map-tests.el: Renamed from map-test.el.

9 years ago* lisp/emacs-lisp/map.el (map-into): Better error message.
Nicolas Petton [Sat, 18 Apr 2015 18:05:16 +0000 (20:05 +0200)]
* lisp/emacs-lisp/map.el (map-into): Better error message.

9 years ago* lisp/emacs-lisp/map.el: Removes byte-compilation warnings.
Nicolas Petton [Sat, 18 Apr 2015 18:04:17 +0000 (20:04 +0200)]
* lisp/emacs-lisp/map.el: Removes byte-compilation warnings.

9 years agoThrow an error when converting a map into an unknown map type
Nicolas Petton [Sat, 18 Apr 2015 14:35:43 +0000 (16:35 +0200)]
Throw an error when converting a map into an unknown map type

* lisp/emacs-lisp/map.el (map-into): Throw an error if type is not valid.
* test/automated/map-test.el: Add a regression test.

9 years agoNew library map.el similar to seq.el but for mapping data structures.
Nicolas Petton [Sat, 18 Apr 2015 14:22:16 +0000 (16:22 +0200)]
New library map.el similar to seq.el but for mapping data structures.

* test/automated/map-test.el: New file.
* lisp/emacs-lisp/map.el: New file.

9 years agoMinor improvements in Bulgarian input methods
Ivan Radanov Ivanov [Sat, 18 Apr 2015 08:01:36 +0000 (11:01 +0300)]
Minor improvements in Bulgarian input methods

* lisp/leim/quail/cyrillic.el (bulgarian-phonetic, bulgarian-bds):
Replace U+042C with U+045D, as the former character is not used in
the modern Bulgarian language.

Fixes: Bug#20350
Copyright-paperwork-exempt: yes

9 years agoImprove EUDC manual
Thomas Fitzsimmons [Sat, 18 Apr 2015 02:02:03 +0000 (22:02 -0400)]
Improve EUDC manual

* eudc.texi (LDAP Configuration): Mention simple and SASL
authentication schemes.  Add index items.  Shorten example server
name.

9 years agoDon't show both feature and function with the same name
Dmitry Gutov [Fri, 17 Apr 2015 23:35:59 +0000 (02:35 +0300)]
Don't show both feature and function with the same name

* lisp/progmodes/elisp-mode.el (elisp--xref-identifier-location):
Don't show both feature and function with the same name.

9 years ago(elisp--xref-identifier-location): Skip variable, if it's also a functiong
Dmitry Gutov [Fri, 17 Apr 2015 22:47:31 +0000 (01:47 +0300)]
(elisp--xref-identifier-location): Skip variable, if it's also a functiong

* lisp/progmodes/elisp-mode.el (elisp--xref-identifier-location):
Avoid returning both the variable and the function for the same
minor mode.

9 years agoFix fontification of keywords clobbered by the prompt.
Wolfgang Jenkner [Fri, 17 Apr 2015 17:54:35 +0000 (19:54 +0200)]
Fix fontification of keywords clobbered by the prompt.

* lisp/comint.el (comint-output-filter): Remove the uses of
with-silent-modifications I introduced as part of the last change.

This fixes, e.g., erratically missing highlighting when running
./configure --help; ./configure in a shell-mode buffer with
compilation-shell-minor-mode turned on.

9 years ago; ChangeLog fixes
Glenn Morris [Fri, 17 Apr 2015 17:48:00 +0000 (13:48 -0400)]
; ChangeLog fixes

9 years ago* admin/authors.el (authors-valid-file-names, authors-renamed-files-alist): Additions.
Glenn Morris [Fri, 17 Apr 2015 17:27:44 +0000 (13:27 -0400)]
* admin/authors.el (authors-valid-file-names, authors-renamed-files-alist): Additions.

9 years ago; ChangeLog fixes
Glenn Morris [Fri, 17 Apr 2015 17:13:04 +0000 (13:13 -0400)]
; ChangeLog fixes

9 years ago* lisp/indent.el (indent-region): Don't deactivate the mark
Stefan Monnier [Fri, 17 Apr 2015 14:30:50 +0000 (10:30 -0400)]
* lisp/indent.el (indent-region): Don't deactivate the mark

Fixes: debbugs:20357
9 years agolisp/net/rcirc.el (defun-rcirc-command): mark `target' as ignorable
Sam Steingold [Fri, 17 Apr 2015 12:45:58 +0000 (08:45 -0400)]
lisp/net/rcirc.el (defun-rcirc-command): mark `target' as ignorable

9 years ago* lisp/progmodes/xref.el (xref-push-marker-stack): Add optional arg.
Leo Liu [Fri, 17 Apr 2015 04:32:33 +0000 (12:32 +0800)]
* lisp/progmodes/xref.el (xref-push-marker-stack): Add optional arg.

9 years ago* lisp/erc/erc-pcomplete.el (erc-pcomplete): Don't use `pcomplete' any more.
Stefan Monnier [Fri, 17 Apr 2015 02:55:41 +0000 (22:55 -0400)]
* lisp/erc/erc-pcomplete.el (erc-pcomplete): Don't use `pcomplete' any more.

9 years ago; Add missing "(tiny change)"
Paul Eggert [Fri, 17 Apr 2015 00:59:11 +0000 (17:59 -0700)]
; Add missing "(tiny change)"

9 years ago; make change-history-commit
Paul Eggert [Fri, 17 Apr 2015 00:57:41 +0000 (17:57 -0700)]
; make change-history-commit

9 years ago* admin/authors.el (authors-lax-changelogs): Update for erc changes.
Glenn Morris [Fri, 17 Apr 2015 00:47:35 +0000 (20:47 -0400)]
* admin/authors.el (authors-lax-changelogs): Update for erc changes.

9 years ago; Split lisp/erc ChangeLogs, for the sake of authors.el
Glenn Morris [Fri, 17 Apr 2015 00:46:14 +0000 (20:46 -0400)]
; Split lisp/erc ChangeLogs, for the sake of authors.el

This turns the old 0.1..0.8 files into ChangeLog.1,
and the old ChangeLog file into ChangeLog.2.

9 years agoDon't link with -ljpeg on MS-Windows, to avoid dependency on DLL
Eli Zaretskii [Thu, 16 Apr 2015 16:02:41 +0000 (19:02 +0300)]
Don't link with -ljpeg on MS-Windows, to avoid dependency on DLL

* configure.ac (LIBJPEG): Leave it empty for MinGW.

9 years ago* lisp/replace.el (query-replace-from-to-separator): Delay initialization
Glenn Morris [Thu, 16 Apr 2015 15:32:38 +0000 (08:32 -0700)]
* lisp/replace.el (query-replace-from-to-separator): Delay initialization

to avoid rogue setting after startup.

9 years ago; CONTRIBUTE: Further updates
Dmitry Gutov [Thu, 16 Apr 2015 14:48:32 +0000 (17:48 +0300)]
; CONTRIBUTE: Further updates

* Better explanation of commit message vs ChangeLog distinction.

* Fix the name of the ChangeLog make task.

* Make instructions WRT NEWS, etc, ChangeLog entries clearer.

Fixes: debbugs:20328
9 years agoPre-4.6 GCC succeeds with unknown option
Paul Eggert [Thu, 16 Apr 2015 07:14:11 +0000 (00:14 -0700)]
Pre-4.6 GCC succeeds with unknown option

* configure.ac (emacs_cv_prog_cc_nopie): Port to pre-4.6 GCC.
Fixes: bug#20338
9 years ago'[:graph:]' now excludes whitespace, not just ' '
Paul Eggert [Thu, 16 Apr 2015 06:45:08 +0000 (23:45 -0700)]
'[:graph:]' now excludes whitespace, not just ' '

* doc/lispref/searching.texi (Char Classes):
* lisp/emacs-lisp/rx.el (rx): Document [:graph:] to be [:print:]
sans whitespace (not sans space).
* src/character.c (graphicp): Exclude all Unicode whitespace chars,
not just space.
* src/regex.c (ISGRAPH): Exclude U+00A0 (NO-BREAK SPACE).

9 years ago(looking-back): Make the second arg non-optional.
Stefan Monnier [Thu, 16 Apr 2015 02:25:16 +0000 (22:25 -0400)]
(looking-back): Make the second arg non-optional.

* lisp/subr.el (substitute-key-definition-key, special-form-p)
(macrop): Drop deprecated second arg to indirect-function.
(looking-back): Make the second arg non-optional.

9 years ago* lisp/org/org-clock.el (org-x11idle-exists-p): Be honest about which
Stefan Monnier [Thu, 16 Apr 2015 02:04:40 +0000 (22:04 -0400)]
* lisp/org/org-clock.el (org-x11idle-exists-p): Be honest about which

command is actually sent to the shell.

9 years agoPort jpeg configuration to Solaris 10 with Sun C
Paul Eggert [Thu, 16 Apr 2015 01:30:01 +0000 (18:30 -0700)]
Port jpeg configuration to Solaris 10 with Sun C

* configure.ac: Check for jpeglib 6b by trying to link it, instead
of relying on cpp magic that has problems in practice.  Check for
both jpeglib.h and jerror.h features.  Remove special case for
mingw32, which should no longer be needed (and if it were needed,
should now be addressable by hotwiring emacs_cv_jpeglib).
Fixes: bug#20332
9 years agoMove some Elisp-specific code from lisp-mode.el to elisp-mode.el
Stefan Monnier [Wed, 15 Apr 2015 20:50:17 +0000 (16:50 -0400)]
Move some Elisp-specific code from lisp-mode.el to elisp-mode.el

* lisp/emacs-lisp/lisp-mode.el (lisp--el-font-lock-flush-elisp-buffers):
Move to elisp-mode.el.
(lisp-mode-variables): (Re)move elisp-specific settings.

* lisp/progmodes/elisp-mode.el (emacs-lisp-mode): Add settings removed
from lisp-mode-variables.
(elisp--font-lock-flush-elisp-buffers): New function, moved from
lisp-mode.el.

9 years ago* lisp/emacs-lisp/lisp-mode.el (lisp--el-non-funcall-position-p):
Stefan Monnier [Wed, 15 Apr 2015 20:39:18 +0000 (16:39 -0400)]
* lisp/emacs-lisp/lisp-mode.el (lisp--el-non-funcall-position-p):

Avoid pathological slowdown at top-level in large file.

9 years ago; Auto-commit of loaddefs files.
Glenn Morris [Wed, 15 Apr 2015 19:20:20 +0000 (15:20 -0400)]
; Auto-commit of loaddefs files.

9 years agoStandardize names of ChangeLog history files
Paul Eggert [Wed, 15 Apr 2015 17:57:50 +0000 (10:57 -0700)]
Standardize names of ChangeLog history files

Suggested by Glenn Morris in:
http://lists.gnu.org/archive/html/emacs-devel/2015-04/msg00678.html
* Makefile.in (install-man): Don't treat ChangeLog.1 as a man page.
* doc/man/ChangeLog.1: Rename back from doc/man/ChangeLog.01.
* lisp/erc/ChangeLog.1: New file, containing the old contents of ...
* lisp/erc/ChangeLog.01, lisp/erc/ChangeLog.02, lisp/erc/ChangeLog.03:
* lisp/erc/ChangeLog.04, lisp/erc/ChangeLog.05, lisp/erc/ChangeLog.06:
* lisp/erc/ChangeLog.07, lisp/erc/ChangeLog.08, lisp/erc/ChangeLog.09:
Remove.

9 years agoSplit top-level entries into pre- and post-April 7
Paul Eggert [Wed, 15 Apr 2015 17:57:50 +0000 (10:57 -0700)]
Split top-level entries into pre- and post-April 7

This more clearly distingiushes pre-April-7 ChangeLog entries (which
are for top-level files only) from post-April-7 entries (which are
about files at all levels.  Problem reported by Glenn Morris in:
http://lists.gnu.org/archive/html/emacs-devel/2015-04/msg00678.html
* ChangeLog.1: Move post-April-7 entries from here ...
* ChangeLog.2: ... to this new file.
* Makefile.in (CHANGELOG_HISTORY_INDEX_MAX): Bump to 2.

9 years agoFix recent cus-start changes that added customize-rogues
Stefan Monnier [Wed, 15 Apr 2015 17:02:15 +0000 (13:02 -0400)]
Fix recent cus-start changes that added customize-rogues

* lisp/cus-start.el (custom-delayed-init-variables): Initialize the
vars early.
* lisp/loadup.el ("cus-start"): Move to the end to reduce customize-rogue.

9 years ago; * etc/NEWS: Add missing system-type entry.
Glenn Morris [Wed, 15 Apr 2015 16:43:37 +0000 (12:43 -0400)]
; * etc/NEWS: Add missing system-type entry.

9 years agoDefine cl-concatenate as an alias to seq-concatenate
Nicolas Petton [Wed, 15 Apr 2015 16:26:52 +0000 (18:26 +0200)]
Define cl-concatenate as an alias to seq-concatenate

* lisp/emacs-lisp/cl-extra.el (cl-concatenate): Removes duplicated
  code by making cl-concatenate an alias to seq-concatenate.

9 years ago* src/lread.c (intern_1): Make sure we'd find the symbol we add
Stefan Monnier [Wed, 15 Apr 2015 16:15:14 +0000 (12:15 -0400)]
* src/lread.c (intern_1): Make sure we'd find the symbol we add

Fixes: debbugs:20334
* src/xfaces.c (resolve_face_name): Don't use `intern' with Lisp_Strings.

9 years ago* doc/lispref/sequences.texi (Sequence Functions): Fix typo in previous.
Glenn Morris [Wed, 15 Apr 2015 16:11:15 +0000 (09:11 -0700)]
* doc/lispref/sequences.texi (Sequence Functions): Fix typo in previous.

9 years agoClean up gnus-uu saving code slightly
Lars Magne Ingebrigtsen [Wed, 15 Apr 2015 13:28:20 +0000 (15:28 +0200)]
Clean up gnus-uu saving code slightly

* gnus-uu.el (gnus-uu-save-article): Make the
save-restriction/widen calls make more sense.

9 years agoMake [:graph:] act like [:print:] sans space
Paul Eggert [Wed, 15 Apr 2015 07:26:32 +0000 (00:26 -0700)]
Make [:graph:] act like [:print:] sans space

In POSIX [[:print:]] is equivalent to [ [:graph:]], so change
[:graph:] so that it matches everything that [:print:] does,
except for space.
* doc/lispref/searching.texi (Char Classes):
* etc/NEWS:
* lisp/emacs-lisp/rx.el (rx):
Document [:graph:] to be [:print:] sans ' '.
* src/character.c, src/character.h (graphicp): New function.
* src/regex.c (ISGRAPH) [emacs]: Use it.
(BIT_GRAPH): New macro.
(BIT_PRINT): Increase to 0x200, to make room for BIT_GRAPH.
(re_wctype_to_bit) [! WIDE_CHAR_SUPPORT]:
Return BIT_GRAPH for RECC_GRAPH.
(re_match_2_internal) [emacs]: Use ISGRAPH if BIT_GRAPH,
and ISPRINT if BIT_PRINT.

9 years agoautomated/eieio-test-methodinvoke.el (make-instance) <(subclass C)>:
Stefan Monnier [Wed, 15 Apr 2015 03:06:44 +0000 (23:06 -0400)]
automated/eieio-test-methodinvoke.el (make-instance) <(subclass C)>:

Don't use call-next-method in a cl-defmethod.

9 years ago* lisp/emacs-lisp/eieio-core.el (eieio--class): Derive from cl--class
Stefan Monnier [Wed, 15 Apr 2015 03:04:45 +0000 (23:04 -0400)]
* lisp/emacs-lisp/eieio-core.el (eieio--class): Derive from cl--class

(eieio--class-p): Remove, provided by cl-defstruct.

9 years agoAdd seq-intersection and seq-difference to the seq library
Nicolas Petton [Tue, 14 Apr 2015 22:33:27 +0000 (00:33 +0200)]
Add seq-intersection and seq-difference to the seq library

* lisp/emacs-lisp/seq.el (seq-intersection, seq-difference): New
functions.

* test/automated/seq-tests.el: Add tests for seq-intersection and
seq-difference.

* doc/lispref/sequences.texi: Add documentation for seq-intersection
and seq-difference.

9 years ago; CONTRIBUTE: Update the "make the ChangeLog entry in their name" bit
Dmitry Gutov [Tue, 14 Apr 2015 23:21:55 +0000 (02:21 +0300)]
; CONTRIBUTE: Update the "make the ChangeLog entry in their name" bit

Fixes: debbugs:20328
9 years ago; CONTRIBUTE: Remove the "relax this rule for commit messages" bit
Dmitry Gutov [Tue, 14 Apr 2015 23:15:07 +0000 (02:15 +0300)]
; CONTRIBUTE: Remove the "relax this rule for commit messages" bit

Fixes: debbugs:20328
9 years ago; Set indent-tabs-mode to nil in (most) Elisp sources
Dmitry Gutov [Tue, 14 Apr 2015 22:40:52 +0000 (01:40 +0300)]
; Set indent-tabs-mode to nil in (most) Elisp sources

Fixes: bug#20323
9 years ago* eieio-core.el (class-abstract-p): Don't inline, to avoid leaking internals
Stefan Monnier [Tue, 14 Apr 2015 21:26:12 +0000 (17:26 -0400)]
* eieio-core.el (class-abstract-p): Don't inline, to avoid leaking internals

9 years agopackage--ensure-init-file: widen requires save-restriction
Sam Steingold [Tue, 14 Apr 2015 19:14:20 +0000 (15:14 -0400)]
package--ensure-init-file: widen requires save-restriction

9 years agoImprove the commit-msg Git hook for unibyte environments
Eli Zaretskii [Tue, 14 Apr 2015 18:57:23 +0000 (21:57 +0300)]
Improve the commit-msg Git hook for unibyte environments

* build-aux/git-hooks/commit-msg: Set LC_ALL=C, before running Awk
in unibyte environments.  (Suggested by Paul Eggert
<eggert@cs.ucla.edu>.)  Use a more accurate approximation to
[:print:], based on UTF-8 sequences of the unprintable characters.

9 years agoDescribe problems with cursor caused by Windows Magnifier
Eli Zaretskii [Tue, 14 Apr 2015 16:34:05 +0000 (19:34 +0300)]
Describe problems with cursor caused by Windows Magnifier

* etc/PROBLEMS: Describe the problem with cursor shape on
MS-Windows due to Windows Magnifier.

Fixes: Bug#20271
9 years agoMake [:print:] support non-ASCII characters correctly
Eli Zaretskii [Tue, 14 Apr 2015 15:47:04 +0000 (18:47 +0300)]
Make [:print:] support non-ASCII characters correctly

* src/regex.c (ISPRINT): Call 'printablep' for multibyte characters.
(BIT_PRINT): New bit mask.
(re_wctype_to_bit): Return BIT_PRINT for RECC_PRINT.
* src/character.c (printablep): New function.
* src/character.h (printablep): Add prototype.

* lisp/emacs-lisp/rx.el (rx): Doc fix: document the new behavior
of 'print', 'alnum', and 'alphabetic'.

* doc/lispref/searching.texi (Char Classes): Document the new
behavior of [:print:].

* etc/NEWS: Mention the new behavior of [:print:].

9 years agoAssign correct general-category and names to surrogates
Eli Zaretskii [Tue, 14 Apr 2015 15:37:07 +0000 (18:37 +0300)]
Assign correct general-category and names to surrogates

* admin/unidata/unidata-gen.el (unidata-setup-list): Don't ignore
surrogates.  This avoids assigning them the default
general-category of 'Cn', i.e. unassigned codepoints.
(unidata-get-name): Give surrogates synthetic names.

9 years agoAssume C89 offsetof in xterm.c, xlwmenu.c
Paul Eggert [Tue, 14 Apr 2015 07:58:07 +0000 (00:58 -0700)]
Assume C89 offsetof in xterm.c, xlwmenu.c

* lwlib/xlwmenu.c (offset):
* src/xterm.c (cvt_string_to_pixel_args):
Use offsetof, not XtOffset.

9 years agoAssume C89 offsetof in widget.c
Paul Eggert [Tue, 14 Apr 2015 07:37:48 +0000 (00:37 -0700)]
Assume C89 offsetof in widget.c

* src/widget.c (XtOffset): Remove; no longer needed.
(offset): Implement via offsetof instead of via pre-C89 XtOffset hack.

9 years agoFix think-o in previous patch
Paul Eggert [Tue, 14 Apr 2015 07:26:18 +0000 (00:26 -0700)]
Fix think-o in previous patch

* src/window.c (count_windows, get_leaf_windows):
Don't optimize count_windows incorrectly.

9 years agoAvoid some int overflows in window.c
Paul Eggert [Tue, 14 Apr 2015 06:26:13 +0000 (23:26 -0700)]
Avoid some int overflows in window.c

* src/print.c (print_object):
* src/window.c (sequence_number):
* src/window.h (struct window.sequence_number):
Don't assume window sequence number fits in int.
* src/window.c (window_select_count):
* src/window.h (struct window.use_time, window_select_count):
Don't assume window use time fits in int.
* src/window.c (Fsplit_window_internal):
Don't assume user-supplied integer, or sum, fits in int.
(Fset_window_configuration, count_windows, get_leaf_windows)
(save_window_save, Fcurrent_window_configuration):
Use ptrdiff_t for object counts.
(Fset_window_configuration): Omit unused local 'n'.
(count_windows): Simplify by writing in terms of get_leaf_windows.
(get_leaf_windows): Don't store through FLAT if it's null.
(extract_dimension): New static function.
(set_window_margins, set_window_fringes, set_window_scroll_bars):
Use it to avoid undefined behavior when converting user-supplied
integer to 'int'.

9 years agoMinor doc copyedits
Glenn Morris [Tue, 14 Apr 2015 06:20:48 +0000 (23:20 -0700)]
Minor doc copyedits

* doc/emacs/custom.texi (Init Examples): Tweak example, replace typo.

* doc/lispintro/emacs-lisp-intro.texi (condition-case): Typo fix.

9 years ago[Gnus] Catch the invalid-operation that idna.el will issue
Katsumi Yamaoka [Tue, 14 Apr 2015 03:35:02 +0000 (03:35 +0000)]
[Gnus] Catch the invalid-operation that idna.el will issue

* lisp/gnus/gnus-art.el (gnus-use-idna):
* lisp/gnus/gnus-sum.el (gnus-summary-idna-message):
* lisp/gnus/message.el (message-use-idna):
Catch the invalid-operation that idna.el will issue.

9 years ago* doc/lispref/processes.texi (Shell Arguments): Prefer diff -u.
Paul Eggert [Tue, 14 Apr 2015 03:30:50 +0000 (20:30 -0700)]
* doc/lispref/processes.texi (Shell Arguments): Prefer diff -u.

9 years agopackage--ensure-init-file: widen before looking for "(package-initialize)"
Sam Steingold [Tue, 14 Apr 2015 03:27:02 +0000 (23:27 -0400)]
package--ensure-init-file: widen before looking for "(package-initialize)"

9 years agoChange diff-switches default to `-u'
Dmitry Gutov [Tue, 14 Apr 2015 02:03:32 +0000 (05:03 +0300)]
Change diff-switches default to `-u'

Fixes: debbugs:20290
* doc/emacs/files.texi (Comparing Files): Document the new default
value of `diff-switches'.

* doc/emacs/trouble.texi (Sending Patches): Document the preference
for unified diff format.  Escape the plus in the suggested `-F' regexp
value.

* lisp/vc/diff.el (diff-switches): Change the default to `-u'.

9 years ago(gnus-group--setup-tool-bar-update): Fix last change
Stefan Monnier [Tue, 14 Apr 2015 01:30:27 +0000 (21:30 -0400)]
(gnus-group--setup-tool-bar-update): Fix last change

* lisp/gnus/gnus-group.el (gnus-group--setup-tool-bar-update):
cursor-sensor-functions should be a list of functions.

9 years agoUse gmm-called-interactively-p in Gnus
Katsumi Yamaoka [Mon, 13 Apr 2015 23:42:18 +0000 (23:42 +0000)]
Use gmm-called-interactively-p in Gnus

* lisp/gnus/gnus-topic.el (gnus-topic-mode): Use gmm-called-interactively-p.

9 years ago* lisp/loadup.el ("cus-start"): Load it after loaddefs.el
Stefan Monnier [Mon, 13 Apr 2015 22:21:00 +0000 (18:21 -0400)]
* lisp/loadup.el ("cus-start"): Load it after loaddefs.el

Fixes: debbugs:20321
* lisp/cus-start.el (read-buffer-function): Don't advertize
iswitchb-read-buffer any more.
(iswitchb): Don't tweak this obsolete group any more.

9 years ago* lisp/emacs-lisp/package.el: Fix package--ensure-init-file
Artur Malabarba [Mon, 13 Apr 2015 19:50:33 +0000 (20:50 +0100)]
* lisp/emacs-lisp/package.el: Fix package--ensure-init-file

9 years ago* lisp/emacs-lisp/cl-macs.el (cl-defstruct): Implement docstrings
Artur Malabarba [Mon, 13 Apr 2015 12:13:36 +0000 (13:13 +0100)]
* lisp/emacs-lisp/cl-macs.el (cl-defstruct): Implement docstrings

Adding a string after a constructor's argument list will use
that string as the constructor function docstring.  If this string
is absent but the struct itself was given a docstring, use that as
the constructor's docstring.

Fixes (bug#17284).

9 years agoDeprecate `intangible' and `point-entered' properties
Stefan Monnier [Mon, 13 Apr 2015 19:51:15 +0000 (15:51 -0400)]
Deprecate `intangible' and `point-entered' properties

* lisp/emacs-lisp/cursor-sensor.el: New file.

* lisp/simple.el (pre-redisplay-functions): New hook.
(redisplay--pre-redisplay-functions): New function.
(pre-redisplay-function): Use it.
(minibuffer-avoid-prompt): Mark obsolete.
(redisplay--update-region-highlight): Adapt it to work as a function on
pre-redisplay-functions.

* lisp/cus-start.el (minibuffer-prompt-properties--setter): New fun.
(minibuffer-prompt-properties): Use it.  Use cursor-intangible rather
than point-entered to make the prompt intangible.

* lisp/forms.el: Move `provide' calls to the end.
(forms-mode): Don't use `run-hooks' on a local var.
(forms--make-format, forms--make-format-elt-using-text-properties):
Use cursor-intangible rather than `intangible'.
(forms-mode): Enable cursor-intangible-mode.

* lisp/isearch.el (isearch-mode): Use defvar-local.
(cursor-sensor-inhibit): Declare.
(isearch-mode): Set cursor-sensor-inhibit.
(isearch-done): Set it back.
(isearch-open-overlay-temporary, isearch-open-necessary-overlays)
(isearch-close-unnecessary-overlays): Don't bother with `intangible'
any more.

* lisp/ses.el (ses-localvars): Remove `mode-line-process'.
(ses-sym-rowcol, ses-cell-value, ses-col-width, ses-col-printer):
Add Edebug spec.
(ses-goto-print, ses-print-cell, ses-adjust-print-width)
(ses-goto-data, ses-setup, ses-copy-region): Don't let-bind
inhibit-point-motion-hooks any more.
(ses--cell-at-pos, ses--curcell): New functions, extracted from
ses-set-curcell.
(ses-set-curcell): Use them.
(ses-print-cell, ses-setup): Use cursor-intangible instead of
`intangible'.  Make sure cursor-intangible isn't sticky at BOB.
(ses-print-cell-new-width, ses-reprint-all, ses-recalculate-all):
Use ses--cell-at-pos.
(ses--mode-line-process, ses--cursor-sensor-highlight): New functions,
extracted from ses-command-hook.  Make them work with multiple windows
displaying the same buffer.
(ses-mode): Use them via mode-line-process and pre-redisplay-functions.
Enable cursor-intangible-mode.
(ses-command-hook): Remove cell highlight and mode-line update code.
(ses-forward-or-insert, ses-copy-region-helper, ses-sort-column):
Update for new name of text-property holding the cell name.
(ses-rename-cell): Don't mess with mode-line-process.

* lisp/erc/erc-stamp.el (erc-add-timestamp): Use the new
cursor-sensor-functions property instead of point-entered.
(erc-insert-timestamp-right, erc-format-timestamp):
Use cursor-intangible rather than `intangible'.
(erc-munge-invisibility-spec): Use add-to-invisibility-spec and
remove-from-invisibility-spec.  Enable cursor-intangible-mode and
cursor-sensor-mode if needed.
(erc-echo-timestamp): Adapt to calling convention of
cursor-sensor-functions.
(erc-insert-timestamp-right): Remove unused vars `current-window' and
`indent'.

* lisp/gnus/gnus-group.el (gnus-tmp-*): Declare.
(gnus-update-group-mark-positions): Remove unused `topic' var.
(gnus-group-insert-group-line): Remove unused var `header'.
(gnus-group--setup-tool-bar-update): New function.
(gnus-group-insert-group-line): Use it.
(gnus-group-update-eval-form): Declare local
dynamically-bound variables.
(gnus-group-unsubscribe-group): Use \` and \' to match string bounds.

* lisp/gnus/gnus-topic.el (gnus-topic-jump-to-topic)
(gnus-group-prepare-topics, gnus-topic-update-topic)
(gnus-topic-change-level, gnus-topic-catchup-articles)
(gnus-topic-remove-group, gnus-topic-delete, gnus-topic-indent):
Use inhibit-read-only.
(gnus-topic-prepare-topic): Use gnus-group--setup-tool-bar-update.
(gnus-topic-mode): Use define-minor-mode and derived-mode-p.

* lisp/textmodes/reftex-index.el (reftex-display-index):
Use cursor-intangible-mode if available.
(reftex-index-post-command-hook): Check cursor-intangible.

* lisp/textmodes/reftex-toc.el (reftex-toc):
Use cursor-intangible-mode if available.
(reftex-toc-recenter, reftex-toc-post-command-hook):
Check cursor-intangible.

* lisp/textmodes/sgml-mode.el: Use lexical-binding.
(sgml-tag): Use cursor-sensor-functions instead of point-entered.
(sgml-tags-invisible): Use with-silent-modifications and
inhibit-read-only.  Enable cursor-sensor-mode.
(sgml-cursor-sensor): Rename from sgml-point-entered and adjust to
calling convention of cursor-sensor-functions.

* lisp/textmodes/table.el (table-cell-map-hook, table-load-hook)
(table-point-entered-cell-hook, table-point-left-cell-hook):
Don't autoload.
(table-cell-entered-state): Remove var.
(table--put-cell-point-entered/left-property)
(table--remove-cell-properties):
Use cursor-sensor-functions rather than point-entered/left.
(table--point-entered/left-cell-function): Merge
table--point-entered-cell-function and table--point-left-cell-function
and adjust to calling convention of cursor-sensor-functions.

9 years agoUpdate ldef-boots.el
Stefan Monnier [Mon, 13 Apr 2015 18:55:10 +0000 (14:55 -0400)]
Update ldef-boots.el

9 years ago* lisp/emacs-lisp/pcase.el (pcase-dolist): Autoload as well.
Stefan Monnier [Mon, 13 Apr 2015 18:46:58 +0000 (14:46 -0400)]
* lisp/emacs-lisp/pcase.el (pcase-dolist): Autoload as well.

9 years ago* doc/misc/eieio.texi: Don't advertize now obsolete constructs
Stefan Monnier [Mon, 13 Apr 2015 18:36:55 +0000 (14:36 -0400)]
* doc/misc/eieio.texi: Don't advertize now obsolete constructs

9 years agoCollapse successive char deletions in the undo log
Stefan Monnier [Mon, 13 Apr 2015 18:05:09 +0000 (14:05 -0400)]
Collapse successive char deletions in the undo log

* src/cmds.c (remove_excessive_undo_boundaries): New function,
extracted from Fself_insert_command.
(Fdelete_char, Fself_insert_command): Use it.
* src/fileio.c (Fmake_symbolic_link): Rename arg to `target'.
* src/keyboard.c (syms_of_keyboard): `top-level' shouldn't be special.

9 years agoxterm and OSC 52: Add NEWS entry, and tweak the code
Stefan Monnier [Mon, 13 Apr 2015 15:36:30 +0000 (11:36 -0400)]
xterm and OSC 52: Add NEWS entry, and tweak the code

* lisp/term/xterm.el (gui-set-selection) <nil>: Move method definition to
top-level.
(terminal-init-xterm-activate-set-selection): Set a terminal property.
(xterm--set-selection): Use it instead of checking the value of
`terminal-initted'.  Don't use string-bytes.

9 years agoxterm.el: Implement OSC-52 functionality for setting the X selection
Philipp Stephani [Mon, 13 Apr 2015 14:48:47 +0000 (10:48 -0400)]
xterm.el: Implement OSC-52 functionality for setting the X selection

* lisp/term/xterm.el (xterm-max-cut-length): New var.
(xterm--set-selection, terminal-init-xterm-activate-set-selection): New funs.
(terminal-init-xterm, xterm--version-handler): Use them.

9 years agoRemove left over code from when we used an obsolete/loaddefs.el file
Stefan Monnier [Mon, 13 Apr 2015 14:41:30 +0000 (10:41 -0400)]
Remove left over code from when we used an obsolete/loaddefs.el file

* lisp/subr.el (do-after-load-evaluation): Remove left over code from when
we used an obsolete/loaddefs.el file.

9 years ago* cedet/semantic/fw.el: Use declare.
Stefan Monnier [Mon, 13 Apr 2015 14:39:25 +0000 (10:39 -0400)]
* cedet/semantic/fw.el: Use declare.

* cedet/semantic/fw.el (semantic-exit-on-input)
(semanticdb-without-unloaded-file-searches): Use declare.
(semantic-fw-add-edebug-spec): Remove.

9 years ago(completion-lisp-mode-hook): Use completion-separator-chars
Stefan Monnier [Mon, 13 Apr 2015 14:35:15 +0000 (10:35 -0400)]
(completion-lisp-mode-hook): Use completion-separator-chars

* lisp/completion.el (completion-lisp-mode-hook):
Use completion-separator-chars rather than local key binding.

9 years ago* src/*.c: Set deactivate_mark buffer-locally
Stefan Monnier [Mon, 13 Apr 2015 14:16:38 +0000 (10:16 -0400)]
* src/*.c: Set deactivate_mark buffer-locally

Fixes: debbugs:20260
* src/insdel.c (prepare_to_modify_buffer_1):
* src/fileio.c (Finsert_file_contents): Set deactivate_mark
buffer-locally.

9 years agopython.el: Keep symmetry on sexp navigation with parens
Fabián Ezequiel Gallina [Mon, 13 Apr 2015 01:43:44 +0000 (22:43 -0300)]
python.el: Keep symmetry on sexp navigation with parens

Fixes: debbugs:19954
* lisp/progmodes/python.el
(python-nav--forward-sexp): Add argument skip-parens-p.
(python-nav-forward-sexp, python-nav-backward-sexp)
(python-nav-forward-sexp-safe)
(python-nav-backward-sexp-safe): Use it.

* test/automated/python-tests.el
(python-nav-forward-sexp-1): Fix test.

9 years agoDon't use `setq-local' in Gnus code
João Távora [Sun, 12 Apr 2015 22:23:44 +0000 (23:23 +0100)]
Don't use `setq-local' in Gnus code

This might break upstream builds with older Emacsen

* lisp/gnus/message.el (message-mode): Use `set' and
`make-local-variable' instead of `setq-local'.

9 years agoUpdate Makefile.in's .PHONY dependencies
Paul Eggert [Sun, 12 Apr 2015 22:21:08 +0000 (15:21 -0700)]
Update Makefile.in's .PHONY dependencies

* Makefile.in (change-history-commit, master-branch-is-current)
(no-ChangeLog): Now phony.

9 years agoRemove configure's --with-mmdf option
Paul Eggert [Sun, 12 Apr 2015 21:55:38 +0000 (14:55 -0700)]
Remove configure's --with-mmdf option

* configure.ac (MAIL_USE_MMDF): Remove.
* etc/NEWS: Document this.
* lib-src/movemail.c: Assume MAIL_USE_MMDF is not defined.
Fixes: bug#20308
9 years ago* doc/man/ChangeLog.01: Rename from doc/man/ChangeLog.1.
Paul Eggert [Sun, 12 Apr 2015 18:26:50 +0000 (11:26 -0700)]
* doc/man/ChangeLog.01: Rename from doc/man/ChangeLog.1.

That way, 'make install' won't think it's a man page.
Reported by Ashish SHUKLA in:
http://lists.gnu.org/archive/html/emacs-devel/2015-04/msg00656.html

9 years agoImprove 'make change-history' prereq tests
Paul Eggert [Sun, 12 Apr 2015 17:21:59 +0000 (10:21 -0700)]
Improve 'make change-history' prereq tests

* Makefile.in (gen_origin): Fix to match what's in the master branch.
(no-ChangeLog, master-branch-is-current): New rules.
(change-history): Depend on them, to avoid similar future problems.
Escape the local-variables string to pacify Emacs when editing
Makefile.in.

9 years ago* test/automated/package-test.el (with-package-test): Kill Packages buffer
Artur Malabarba [Sun, 12 Apr 2015 15:10:22 +0000 (16:10 +0100)]
* test/automated/package-test.el (with-package-test): Kill Packages buffer

9 years ago* lisp/emacs-lisp/package.el: Improve transaction y-or-n prompt
Artur Malabarba [Sun, 12 Apr 2015 14:11:08 +0000 (15:11 +0100)]
* lisp/emacs-lisp/package.el: Improve transaction y-or-n prompt

(package-menu--prompt-transaction-p): Prompt for "Delete" first,
"Upgrade" last, and use capitalized instead of all-caps.

9 years ago* lisp/emacs-lisp/package.el: Completely silence async operations
Artur Malabarba [Sun, 12 Apr 2015 14:03:45 +0000 (15:03 +0100)]
* lisp/emacs-lisp/package.el: Completely silence async operations

(package--make-autoloads-and-stuff): Silence autoloads.

(package--save-selected-packages): New function, silences
`customize-save-variable'.
(package--user-selected-p, package-install-from-buffer)
(package-delete, package-install): Use it.

(package-install-from-archive)
(package-menu--perform-transaction): Silence.

(package-menu-execute): Feedback when operation starts.

9 years agoUse delay-mode-hooks when visiting the init-file
Artur Malabarba [Sun, 12 Apr 2015 13:37:45 +0000 (14:37 +0100)]
Use delay-mode-hooks when visiting the init-file

* lisp/emacs-lisp/package.el (package--ensure-init-file):
delay-mode-hooks

* lisp/cus-edit.el (custom-save-all): delay-mode-hooks

9 years ago* lisp/files.el: Only message when saving if save-silently is nil
Artur Malabarba [Sun, 12 Apr 2015 13:36:54 +0000 (14:36 +0100)]
* lisp/files.el: Only message when saving if save-silently is nil

(save-silently): New variable.
(files--message): New function.

(find-file-noselect, save-buffer, basic-save-buffer)
(basic-save-buffer-2, save-some-buffers, not-modified)
(append-to-file): Use them.

9 years agoSupport debug declarations in pcase macros
Johan Bockgård [Sun, 12 Apr 2015 14:26:52 +0000 (16:26 +0200)]
Support debug declarations in pcase macros

* lisp/emacs-lisp/pcase.el (pcase-MACRO): New edebug spec.
(pcase-UPAT): Use it.  Remove "`".
(pcase--edebug-match-macro): New function.
(pcase-defmacro): Support debug declarations.

* lisp/emacs-lisp/cl-macs.el (cl-struct) <pcase-defmacro>:
* lisp/emacs-lisp/eieio.el (eieio) <pcase-defmacro>:
* lisp/emacs-lisp/pcase.el (\`): <pcase-defmacro>: Add debug declaration.

9 years agopcase.el: Edebug support for `app' and vector patterns
Johan Bockgård [Sun, 12 Apr 2015 14:26:51 +0000 (16:26 +0200)]
pcase.el: Edebug support for `app' and vector patterns

* lisp/emacs-lisp/pcase.el (pcase-FUN): New edebug spec.
(pcase-UPAT): Use it. Support `app' patterns.
(pcase-QPAT): Support vector patterns.

9 years agoedebug.el: Disambiguate vector specifications
Johan Bockgård [Sun, 12 Apr 2015 14:26:51 +0000 (16:26 +0200)]
edebug.el: Disambiguate vector specifications

* lisp/emacs-lisp/edebug.el (edebug-match-list): Always treat
`(vector ...)' as a vector specification, not as a sublist.

9 years ago(gnus-summary-refer-thread): Don't clobber unread articles
Johan Bockgård [Sun, 12 Apr 2015 14:13:08 +0000 (16:13 +0200)]
(gnus-summary-refer-thread): Don't clobber unread articles

This fixes a bug where `A T' causes "random" articles to become marked
as read.

* lisp/gnus/gnus-sum.el (gnus-summary-refer-thread): Make sure
gnus-newsgroup-unreads remains sorted.

9 years agomouse-sel.el: Fix mouse-sel-get-selection-function
Johan Bockgård [Sun, 12 Apr 2015 13:55:32 +0000 (15:55 +0200)]
mouse-sel.el: Fix mouse-sel-get-selection-function

* lisp/obsolete/mouse-sel.el (mouse-sel-get-selection-function):
Use gui--last-selected-text-primary instead of no longer existing
gui-last-selected-text.