diff options
| -rw-r--r-- | doc/lispref/ChangeLog | 6 | ||||
| -rw-r--r-- | lisp/ChangeLog | 18 | ||||
| -rw-r--r-- | lisp/dnd.el | 9 | ||||
| -rw-r--r-- | lisp/minibuffer.el | 112 | ||||
| -rw-r--r-- | lisp/vc-svn.el | 2 | ||||
| -rw-r--r-- | src/ChangeLog | 10 | ||||
| -rw-r--r-- | src/buffer.c | 10 | ||||
| -rw-r--r-- | src/dbusbind.c | 10 |
8 files changed, 107 insertions, 70 deletions
diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog index 4302da5aa27..2aca9fce5bf 100644 --- a/doc/lispref/ChangeLog +++ b/doc/lispref/ChangeLog | |||
| @@ -2325,6 +2325,12 @@ | |||
| 2325 | 2325 | ||
| 2326 | * display.texi (Images): Delete redundant @findex. | 2326 | * display.texi (Images): Delete redundant @findex. |
| 2327 | 2327 | ||
| 2328 | 2007-08-16 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 2329 | |||
| 2330 | * text.texi (Change Hooks): (after|before)-change-functions are no | ||
| 2331 | longer bound to nil while running; rather inhibit-modification-hooks | ||
| 2332 | is t. | ||
| 2333 | |||
| 2328 | 2007-08-16 Richard Stallman <rms@gnu.org> | 2334 | 2007-08-16 Richard Stallman <rms@gnu.org> |
| 2329 | 2335 | ||
| 2330 | * processes.texi (Asynchronous Processes): Clarify | 2336 | * processes.texi (Asynchronous Processes): Clarify |
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 696941f93cd..85d108356cc 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,21 @@ | |||
| 1 | 2010-10-03 Chong Yidong <cyd@stupidchicken.com> | ||
| 2 | |||
| 3 | * minibuffer.el (completion--some, completion--do-completion) | ||
| 4 | (minibuffer-complete-and-exit, minibuffer-completion-help) | ||
| 5 | (completion-basic-try-completion) | ||
| 6 | (completion-basic-all-completions) | ||
| 7 | (completion-pcm--find-all-completions): Use lexical-let to | ||
| 8 | avoid some false matches in variable completion (Bug#7056) | ||
| 9 | |||
| 10 | 2010-10-03 Olof Ohlsson Sax <olof.ohlsson.sax@gmail.com> (tiny change) | ||
| 11 | |||
| 12 | * vc-svn.el (vc-svn-merge-news): Use --non-interactive. (Bug#7152) | ||
| 13 | |||
| 14 | 2010-10-03 Leo <sdl.web@gmail.com> | ||
| 15 | |||
| 16 | * dnd.el (dnd-get-local-file-name): If MUST-EXIST is non-nil, only | ||
| 17 | return non-nil if the file exists (Bug#7090). | ||
| 18 | |||
| 1 | 2010-09-30 Stefan Monnier <monnier@iro.umontreal.ca> | 19 | 2010-09-30 Stefan Monnier <monnier@iro.umontreal.ca> |
| 2 | 20 | ||
| 3 | * minibuffer.el (completion--replace): | 21 | * minibuffer.el (completion--replace): |
diff --git a/lisp/dnd.el b/lisp/dnd.el index d7cbb641bab..aadfad6d7ac 100644 --- a/lisp/dnd.el +++ b/lisp/dnd.el | |||
| @@ -154,10 +154,11 @@ Return nil if URI is not a local file." | |||
| 154 | (let* ((decoded-f (decode-coding-string | 154 | (let* ((decoded-f (decode-coding-string |
| 155 | f | 155 | f |
| 156 | (or file-name-coding-system | 156 | (or file-name-coding-system |
| 157 | default-file-name-coding-system))) | 157 | default-file-name-coding-system)))) |
| 158 | (try-f (if (file-readable-p decoded-f) decoded-f f))) | 158 | (setq f (cond ((file-readable-p decoded-f) decoded-f) |
| 159 | (when (file-readable-p try-f) try-f))))) | 159 | ((file-readable-p f) f) |
| 160 | 160 | (t nil))))) | |
| 161 | f)) | ||
| 161 | 162 | ||
| 162 | (defun dnd-open-local-file (uri action) | 163 | (defun dnd-open-local-file (uri action) |
| 163 | "Open a local file. | 164 | "Open a local file. |
diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el index 9a477020421..a4ab5261f7c 100644 --- a/lisp/minibuffer.el +++ b/lisp/minibuffer.el | |||
| @@ -129,8 +129,8 @@ the closest directory separators." | |||
| 129 | "Apply FUN to each element of XS in turn. | 129 | "Apply FUN to each element of XS in turn. |
| 130 | Return the first non-nil returned value. | 130 | Return the first non-nil returned value. |
| 131 | Like CL's `some'." | 131 | Like CL's `some'." |
| 132 | (let ((firsterror nil) | 132 | (lexical-let ((firsterror nil) |
| 133 | res) | 133 | res) |
| 134 | (while (and (not res) xs) | 134 | (while (and (not res) xs) |
| 135 | (condition-case err | 135 | (condition-case err |
| 136 | (setq res (funcall fun (pop xs))) | 136 | (setq res (funcall fun (pop xs))) |
| @@ -518,15 +518,16 @@ E = after completion we now have an Exact match. | |||
| 518 | 101 5 ??? impossible | 518 | 101 5 ??? impossible |
| 519 | 110 6 some completion happened | 519 | 110 6 some completion happened |
| 520 | 111 7 completed to an exact completion" | 520 | 111 7 completed to an exact completion" |
| 521 | (let* ((beg (field-beginning)) | 521 | (lexical-let* |
| 522 | (end (field-end)) | 522 | ((beg (field-beginning)) |
| 523 | (string (buffer-substring beg end)) | 523 | (end (field-end)) |
| 524 | (comp (funcall (or try-completion-function | 524 | (string (buffer-substring beg end)) |
| 525 | 'completion-try-completion) | 525 | (comp (funcall (or try-completion-function |
| 526 | string | 526 | 'completion-try-completion) |
| 527 | minibuffer-completion-table | 527 | string |
| 528 | minibuffer-completion-predicate | 528 | minibuffer-completion-table |
| 529 | (- (point) beg)))) | 529 | minibuffer-completion-predicate |
| 530 | (- (point) beg)))) | ||
| 530 | (cond | 531 | (cond |
| 531 | ((null comp) | 532 | ((null comp) |
| 532 | (minibuffer-hide-completions) | 533 | (minibuffer-hide-completions) |
| @@ -539,14 +540,15 @@ E = after completion we now have an Exact match. | |||
| 539 | ;; `completed' should be t if some completion was done, which doesn't | 540 | ;; `completed' should be t if some completion was done, which doesn't |
| 540 | ;; include simply changing the case of the entered string. However, | 541 | ;; include simply changing the case of the entered string. However, |
| 541 | ;; for appearance, the string is rewritten if the case changes. | 542 | ;; for appearance, the string is rewritten if the case changes. |
| 542 | (let* ((comp-pos (cdr comp)) | 543 | (lexical-let* |
| 543 | (completion (car comp)) | 544 | ((comp-pos (cdr comp)) |
| 544 | (completed (not (eq t (compare-strings completion nil nil | 545 | (completion (car comp)) |
| 545 | string nil nil t)))) | 546 | (completed (not (eq t (compare-strings completion nil nil |
| 546 | (unchanged (eq t (compare-strings completion nil nil | 547 | string nil nil t)))) |
| 547 | string nil nil nil)))) | 548 | (unchanged (eq t (compare-strings completion nil nil |
| 549 | string nil nil nil)))) | ||
| 548 | (if unchanged | 550 | (if unchanged |
| 549 | (goto-char end) | 551 | (goto-char end) |
| 550 | ;; Insert in minibuffer the chars we got. | 552 | ;; Insert in minibuffer the chars we got. |
| 551 | (completion--replace beg end completion)) | 553 | (completion--replace beg end completion)) |
| 552 | ;; Move point to its completion-mandated destination. | 554 | ;; Move point to its completion-mandated destination. |
| @@ -693,8 +695,8 @@ If `minibuffer-completion-confirm' is `confirm-after-completion', | |||
| 693 | `minibuffer-confirm-exit-commands', and accept the input | 695 | `minibuffer-confirm-exit-commands', and accept the input |
| 694 | otherwise." | 696 | otherwise." |
| 695 | (interactive) | 697 | (interactive) |
| 696 | (let ((beg (field-beginning)) | 698 | (lexical-let ((beg (field-beginning)) |
| 697 | (end (field-end))) | 699 | (end (field-end))) |
| 698 | (cond | 700 | (cond |
| 699 | ;; Allow user to specify null string | 701 | ;; Allow user to specify null string |
| 700 | ((= beg end) (exit-minibuffer)) | 702 | ((= beg end) (exit-minibuffer)) |
| @@ -1071,13 +1073,13 @@ variables.") | |||
| 1071 | "Display a list of possible completions of the current minibuffer contents." | 1073 | "Display a list of possible completions of the current minibuffer contents." |
| 1072 | (interactive) | 1074 | (interactive) |
| 1073 | (message "Making completion list...") | 1075 | (message "Making completion list...") |
| 1074 | (let* ((start (field-beginning)) | 1076 | (lexical-let* ((start (field-beginning)) |
| 1075 | (string (field-string)) | 1077 | (string (field-string)) |
| 1076 | (completions (completion-all-completions | 1078 | (completions (completion-all-completions |
| 1077 | string | 1079 | string |
| 1078 | minibuffer-completion-table | 1080 | minibuffer-completion-table |
| 1079 | minibuffer-completion-predicate | 1081 | minibuffer-completion-predicate |
| 1080 | (- (point) (field-beginning))))) | 1082 | (- (point) (field-beginning))))) |
| 1081 | (message nil) | 1083 | (message nil) |
| 1082 | (if (and completions | 1084 | (if (and completions |
| 1083 | (or (consp (cdr completions)) | 1085 | (or (consp (cdr completions)) |
| @@ -1707,9 +1709,10 @@ Return the new suffix." | |||
| 1707 | suffix)) | 1709 | suffix)) |
| 1708 | 1710 | ||
| 1709 | (defun completion-basic-try-completion (string table pred point) | 1711 | (defun completion-basic-try-completion (string table pred point) |
| 1710 | (let* ((beforepoint (substring string 0 point)) | 1712 | (lexical-let* |
| 1711 | (afterpoint (substring string point)) | 1713 | ((beforepoint (substring string 0 point)) |
| 1712 | (bounds (completion-boundaries beforepoint table pred afterpoint))) | 1714 | (afterpoint (substring string point)) |
| 1715 | (bounds (completion-boundaries beforepoint table pred afterpoint))) | ||
| 1713 | (if (zerop (cdr bounds)) | 1716 | (if (zerop (cdr bounds)) |
| 1714 | ;; `try-completion' may return a subtly different result | 1717 | ;; `try-completion' may return a subtly different result |
| 1715 | ;; than `all+merge', so try to use it whenever possible. | 1718 | ;; than `all+merge', so try to use it whenever possible. |
| @@ -1720,28 +1723,30 @@ Return the new suffix." | |||
| 1720 | (concat completion | 1723 | (concat completion |
| 1721 | (completion--merge-suffix completion point afterpoint)) | 1724 | (completion--merge-suffix completion point afterpoint)) |
| 1722 | (length completion)))) | 1725 | (length completion)))) |
| 1723 | (let* ((suffix (substring afterpoint (cdr bounds))) | 1726 | (lexical-let* |
| 1724 | (prefix (substring beforepoint 0 (car bounds))) | 1727 | ((suffix (substring afterpoint (cdr bounds))) |
| 1725 | (pattern (delete | 1728 | (prefix (substring beforepoint 0 (car bounds))) |
| 1726 | "" (list (substring beforepoint (car bounds)) | 1729 | (pattern (delete |
| 1727 | 'point | 1730 | "" (list (substring beforepoint (car bounds)) |
| 1728 | (substring afterpoint 0 (cdr bounds))))) | 1731 | 'point |
| 1729 | (all (completion-pcm--all-completions prefix pattern table pred))) | 1732 | (substring afterpoint 0 (cdr bounds))))) |
| 1733 | (all (completion-pcm--all-completions prefix pattern table pred))) | ||
| 1730 | (if minibuffer-completing-file-name | 1734 | (if minibuffer-completing-file-name |
| 1731 | (setq all (completion-pcm--filename-try-filter all))) | 1735 | (setq all (completion-pcm--filename-try-filter all))) |
| 1732 | (completion-pcm--merge-try pattern all prefix suffix))))) | 1736 | (completion-pcm--merge-try pattern all prefix suffix))))) |
| 1733 | 1737 | ||
| 1734 | (defun completion-basic-all-completions (string table pred point) | 1738 | (defun completion-basic-all-completions (string table pred point) |
| 1735 | (let* ((beforepoint (substring string 0 point)) | 1739 | (lexical-let* |
| 1736 | (afterpoint (substring string point)) | 1740 | ((beforepoint (substring string 0 point)) |
| 1737 | (bounds (completion-boundaries beforepoint table pred afterpoint)) | 1741 | (afterpoint (substring string point)) |
| 1738 | (suffix (substring afterpoint (cdr bounds))) | 1742 | (bounds (completion-boundaries beforepoint table pred afterpoint)) |
| 1739 | (prefix (substring beforepoint 0 (car bounds))) | 1743 | (suffix (substring afterpoint (cdr bounds))) |
| 1740 | (pattern (delete | 1744 | (prefix (substring beforepoint 0 (car bounds))) |
| 1741 | "" (list (substring beforepoint (car bounds)) | 1745 | (pattern (delete |
| 1742 | 'point | 1746 | "" (list (substring beforepoint (car bounds)) |
| 1743 | (substring afterpoint 0 (cdr bounds))))) | 1747 | 'point |
| 1744 | (all (completion-pcm--all-completions prefix pattern table pred))) | 1748 | (substring afterpoint 0 (cdr bounds))))) |
| 1749 | (all (completion-pcm--all-completions prefix pattern table pred))) | ||
| 1745 | (completion-hilit-commonality all point (car bounds)))) | 1750 | (completion-hilit-commonality all point (car bounds)))) |
| 1746 | 1751 | ||
| 1747 | ;;; Partial-completion-mode style completion. | 1752 | ;;; Partial-completion-mode style completion. |
| @@ -1896,12 +1901,13 @@ POINT is a position inside STRING. | |||
| 1896 | FILTER is a function applied to the return value, that can be used, e.g. to | 1901 | FILTER is a function applied to the return value, that can be used, e.g. to |
| 1897 | filter out additional entries (because TABLE migth not obey PRED)." | 1902 | filter out additional entries (because TABLE migth not obey PRED)." |
| 1898 | (unless filter (setq filter 'identity)) | 1903 | (unless filter (setq filter 'identity)) |
| 1899 | (let* ((beforepoint (substring string 0 point)) | 1904 | (lexical-let* |
| 1900 | (afterpoint (substring string point)) | 1905 | ((beforepoint (substring string 0 point)) |
| 1901 | (bounds (completion-boundaries beforepoint table pred afterpoint)) | 1906 | (afterpoint (substring string point)) |
| 1902 | (prefix (substring beforepoint 0 (car bounds))) | 1907 | (bounds (completion-boundaries beforepoint table pred afterpoint)) |
| 1903 | (suffix (substring afterpoint (cdr bounds))) | 1908 | (prefix (substring beforepoint 0 (car bounds))) |
| 1904 | firsterror) | 1909 | (suffix (substring afterpoint (cdr bounds))) |
| 1910 | firsterror) | ||
| 1905 | (setq string (substring string (car bounds) (+ point (cdr bounds)))) | 1911 | (setq string (substring string (car bounds) (+ point (cdr bounds)))) |
| 1906 | (let* ((relpoint (- point (car bounds))) | 1912 | (let* ((relpoint (- point (car bounds))) |
| 1907 | (pattern (completion-pcm--string->pattern string relpoint)) | 1913 | (pattern (completion-pcm--string->pattern string relpoint)) |
diff --git a/lisp/vc-svn.el b/lisp/vc-svn.el index 34ebc3bb949..7b95c2a214d 100644 --- a/lisp/vc-svn.el +++ b/lisp/vc-svn.el | |||
| @@ -373,7 +373,7 @@ The changes are between FIRST-VERSION and SECOND-VERSION." | |||
| 373 | (message "Merging changes into %s..." file) | 373 | (message "Merging changes into %s..." file) |
| 374 | ;; (vc-file-setprop file 'vc-working-revision nil) | 374 | ;; (vc-file-setprop file 'vc-working-revision nil) |
| 375 | (vc-file-setprop file 'vc-checkout-time 0) | 375 | (vc-file-setprop file 'vc-checkout-time 0) |
| 376 | (vc-svn-command nil 0 file "update") | 376 | (vc-svn-command nil 0 file "--non-interactive" "update") ; see bug#7152 |
| 377 | ;; Analyze the merge result reported by SVN, and set | 377 | ;; Analyze the merge result reported by SVN, and set |
| 378 | ;; file properties accordingly. | 378 | ;; file properties accordingly. |
| 379 | (with-current-buffer (get-buffer "*vc*") | 379 | (with-current-buffer (get-buffer "*vc*") |
diff --git a/src/ChangeLog b/src/ChangeLog index bb20d5739de..53adc561021 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -3,6 +3,16 @@ | |||
| 3 | * coding.c (complement_process_encoding_system): Fix previous | 3 | * coding.c (complement_process_encoding_system): Fix previous |
| 4 | change. | 4 | change. |
| 5 | 5 | ||
| 6 | 2010-10-03 Michael Albinus <michael.albinus@gmx.de> | ||
| 7 | |||
| 8 | * dbusbind.c (syms_of_dbusbind): Move putenv call ... | ||
| 9 | (Fdbus_init_bus): ... here. (Bug#7113) | ||
| 10 | |||
| 11 | 2010-10-03 Glenn Morris <rgm@gnu.org> | ||
| 12 | |||
| 13 | * buffer.c (before-change-functions, after-change-functions): | ||
| 14 | Three-year overdue doc fix following 2007-08-13 change. | ||
| 15 | |||
| 6 | 2010-10-02 Kenichi Handa <handa@m17n.org> | 16 | 2010-10-02 Kenichi Handa <handa@m17n.org> |
| 7 | 17 | ||
| 8 | * coding.c (coding_inherit_eol_type): If parent doesn't specify | 18 | * coding.c (coding_inherit_eol_type): If parent doesn't specify |
diff --git a/src/buffer.c b/src/buffer.c index adb85b83e5f..939e2bb0e19 100644 --- a/src/buffer.c +++ b/src/buffer.c | |||
| @@ -6096,10 +6096,7 @@ No information is given about the length of the text after the change. | |||
| 6096 | 6096 | ||
| 6097 | Buffer changes made while executing the `before-change-functions' | 6097 | Buffer changes made while executing the `before-change-functions' |
| 6098 | don't call any before-change or after-change functions. | 6098 | don't call any before-change or after-change functions. |
| 6099 | That's because these variables are temporarily set to nil. | 6099 | That's because `inhibit-modification-hooks' is temporarily set non-nil. |
| 6100 | As a result, a hook function cannot straightforwardly alter the | ||
| 6101 | value of these variables. See the Emacs Lisp manual for a way of | ||
| 6102 | accomplishing an equivalent result by using other variables. | ||
| 6103 | 6100 | ||
| 6104 | If an unhandled error happens in running these functions, | 6101 | If an unhandled error happens in running these functions, |
| 6105 | the variable's value remains nil. That prevents the error | 6102 | the variable's value remains nil. That prevents the error |
| @@ -6117,10 +6114,7 @@ and the post-change beginning and end are at the same place.) | |||
| 6117 | 6114 | ||
| 6118 | Buffer changes made while executing the `after-change-functions' | 6115 | Buffer changes made while executing the `after-change-functions' |
| 6119 | don't call any before-change or after-change functions. | 6116 | don't call any before-change or after-change functions. |
| 6120 | That's because these variables are temporarily set to nil. | 6117 | That's because `inhibit-modification-hooks' is temporarily set non-nil. |
| 6121 | As a result, a hook function cannot straightforwardly alter the | ||
| 6122 | value of these variables. See the Emacs Lisp manual for a way of | ||
| 6123 | accomplishing an equivalent result by using other variables. | ||
| 6124 | 6118 | ||
| 6125 | If an unhandled error happens in running these functions, | 6119 | If an unhandled error happens in running these functions, |
| 6126 | the variable's value remains nil. That prevents the error | 6120 | the variable's value remains nil. That prevents the error |
diff --git a/src/dbusbind.c b/src/dbusbind.c index f3a573d3bce..460cf52364e 100644 --- a/src/dbusbind.c +++ b/src/dbusbind.c | |||
| @@ -854,6 +854,9 @@ This is an internal function, it shall not be used outside dbus.el. */) | |||
| 854 | NULL, (void*) XHASH (bus), NULL)) | 854 | NULL, (void*) XHASH (bus), NULL)) |
| 855 | XD_SIGNAL1 (build_string ("Cannot add watch functions")); | 855 | XD_SIGNAL1 (build_string ("Cannot add watch functions")); |
| 856 | 856 | ||
| 857 | /* We do not want to abort. */ | ||
| 858 | putenv ("DBUS_FATAL_WARNINGS=0"); | ||
| 859 | |||
| 857 | /* Return. */ | 860 | /* Return. */ |
| 858 | return Qnil; | 861 | return Qnil; |
| 859 | } | 862 | } |
| @@ -2130,12 +2133,11 @@ message arrives. */); | |||
| 2130 | doc: /* If non-nil, debug messages of D-Bus bindings are raised. */); | 2133 | doc: /* If non-nil, debug messages of D-Bus bindings are raised. */); |
| 2131 | #ifdef DBUS_DEBUG | 2134 | #ifdef DBUS_DEBUG |
| 2132 | Vdbus_debug = Qt; | 2135 | Vdbus_debug = Qt; |
| 2133 | /* We can also set environment DBUS_VERBOSE=1 in order to see more | 2136 | /* We can also set environment variable DBUS_VERBOSE=1 in order to |
| 2134 | traces. */ | 2137 | see more traces. This requires libdbus-1 to be configured with |
| 2138 | --enable-verbose-mode. */ | ||
| 2135 | #else | 2139 | #else |
| 2136 | Vdbus_debug = Qnil; | 2140 | Vdbus_debug = Qnil; |
| 2137 | /* We do not want to abort. */ | ||
| 2138 | putenv ("DBUS_FATAL_WARNINGS=0"); | ||
| 2139 | #endif | 2141 | #endif |
| 2140 | 2142 | ||
| 2141 | Fprovide (intern_c_string ("dbusbind"), Qnil); | 2143 | Fprovide (intern_c_string ("dbusbind"), Qnil); |