aboutsummaryrefslogtreecommitdiffstats
path: root/lisp
diff options
context:
space:
mode:
authorAlan Mackenzie2011-10-28 13:56:09 +0000
committerAlan Mackenzie2011-10-28 13:56:09 +0000
commitc0f13227ab16ad9a87a16182e9d9ace5d2f7a6d9 (patch)
tree5b6aad37a5ab5a4d0591a0159b7041dba54f43b5 /lisp
parent536610a433e6edc0b3f831272c4e0424ebebee46 (diff)
parent44b0122fbb0af5606471d9667ce6352696d259b8 (diff)
downloademacs-c0f13227ab16ad9a87a16182e9d9ace5d2f7a6d9.tar.gz
emacs-c0f13227ab16ad9a87a16182e9d9ace5d2f7a6d9.zip
Merge in random stuff from savannah.
Diffstat (limited to 'lisp')
-rw-r--r--lisp/ChangeLog112
-rw-r--r--lisp/comint.el6
-rw-r--r--lisp/emacs-lisp/cl-extra.el14
-rw-r--r--lisp/emacs-lisp/cl-loaddefs.el26
-rw-r--r--lisp/emacs-lisp/cl.el54
-rw-r--r--lisp/emacs-lisp/derived.el2
-rw-r--r--lisp/emacs-lisp/easy-mmode.el11
-rw-r--r--lisp/facemenu.el2
-rw-r--r--lisp/files.el6
-rw-r--r--lisp/gnus/ChangeLog15
-rw-r--r--lisp/gnus/message.el6
-rw-r--r--lisp/gnus/mml.el4
-rw-r--r--lisp/ido.el8
-rw-r--r--lisp/info.el2
-rw-r--r--lisp/international/mule-conf.el2
-rw-r--r--lisp/isearch.el2
-rw-r--r--lisp/net/tramp-cache.el3
-rw-r--r--lisp/net/tramp-sh.el17
-rw-r--r--lisp/net/trampver.el4
-rw-r--r--lisp/notifications.el3
-rw-r--r--lisp/org/ChangeLog2
-rw-r--r--lisp/progmodes/octave-inf.el5
-rw-r--r--lisp/progmodes/octave-mod.el12
-rw-r--r--lisp/simple.el3
-rw-r--r--lisp/subr.el47
-rw-r--r--lisp/term/w32-win.el1
-rw-r--r--lisp/textmodes/reftex.el2
27 files changed, 265 insertions, 106 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 09e2e7dc1de..6aa1bddb9f3 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,95 @@
12011-10-27 Glenn Morris <rgm@gnu.org>
2
3 * emacs-lisp/cl-extra.el (most-positive-float, most-negative-float)
4 (least-positive-float, least-negative-float)
5 (least-positive-normalized-float, least-negative-normalized-float)
6 (float-epsilon, float-negative-epsilon):
7 Remove unnecessary declarations.
8
9 * emacs-lisp/cl-extra.el (cl-float-limits): Add doc string.
10 * emacs-lisp/cl.el (most-positive-float, most-negative-float)
11 (least-positive-float, least-negative-float)
12 (least-positive-normalized-float, least-negative-normalized-float)
13 (float-epsilon, float-negative-epsilon): Add doc-strings,
14 based on those in cl.texi.
15
16 * files.el (set-visited-file-name): If the major-mode changed,
17 reload the local variables. (Bug#9796)
18
192011-10-27 Chong Yidong <cyd@gnu.org>
20
21 * subr.el (change-major-mode-after-body-hook): New hook.
22 (run-mode-hooks): Run it.
23
24 * emacs-lisp/easy-mmode.el (define-globalized-minor-mode): Use
25 change-major-mode-before-body-hook.
26
27 * simple.el (fundamental-mode):
28 * emacs-lisp/derived.el (define-derived-mode): Revert 2010-04-28
29 change introducing fundamental-mode-hook.
30
312011-10-26 Juanma Barranquero <lekktu@gmail.com>
32
33 * term/w32-win.el (w32-default-color-map): Declare obsolete. (Bug#9785)
34
352011-10-26 Michael Albinus <michael.albinus@gmx.de>
36
37 * ido.el (ido-file-name-all-completions-1): Do not require
38 tramp.el explicitely. (Bug#7583)
39
402011-10-26 Stefan Monnier <monnier@iro.umontreal.ca>
41
42 * progmodes/octave-mod.el:
43 * progmodes/octave-inf.el: Update maintainer.
44
452011-10-26 Chong Yidong <cyd@gnu.org>
46
47 * subr.el (with-wrapper-hook): Rewrite doc.
48
492011-10-25 Michael Albinus <michael.albinus@gmx.de>
50
51 * net/tramp-sh.el (tramp-sh-handle-file-directory-p): Return t for
52 filenames "/method:foo:". (Bug#9793)
53
542011-10-25 Stefan Monnier <monnier@iro.umontreal.ca>
55
56 * comint.el (comint-get-old-input-default): Fix use-prompt-regexp case
57 (bug#9865).
58
592011-10-24 Glenn Morris <rgm@gnu.org>
60
61 * emacs-lisp/easy-mmode.el (define-minor-mode): Doc fix. (Bug#9819)
62
632011-10-24 Michael Albinus <michael.albinus@gmx.de>
64
65 * notifications.el: Add the requirement of a running D-Bus session
66 bus to the Commentary.
67
682011-10-24 Juri Linkov <juri@jurta.org>
69
70 * isearch.el (isearch-occur): Let-bind `search-spaces-regexp' to
71 `search-whitespace-regexp' only when `isearch-regexp' is non-nil.
72 (Bug#9364)
73
742011-10-24 Juri Linkov <juri@jurta.org>
75
76 * info.el (Info-following-node-name-re): Add newline to the list
77 of allowed characters for leading space. (Bug#9824)
78
792011-10-24 Stefan Monnier <monnier@iro.umontreal.ca>
80
81 * progmodes/octave-inf.el (inferior-octave-mode-map): Fix C-c C-h binding.
82 * progmodes/octave-mod.el (octave-help): Remove.
83
842011-10-23 Michael Albinus <michael.albinus@gmx.de>
85
86 Sync with Tramp 2.2.3.
87
88 * net/tramp-cache.el (top): Pacify byte-compiler using
89 `init-file-user' and `site-run-file'.
90
91 * net/trampver.el: Update release number.
92
12011-10-23 Chong Yidong <cyd@gnu.org> 932011-10-23 Chong Yidong <cyd@gnu.org>
2 94
3 * files.el (toggle-read-only): Remove obsolete comment about 95 * files.el (toggle-read-only): Remove obsolete comment about
@@ -7,16 +99,16 @@
7 for toggle-read-only. Note that this hasn't called vc-next-action 99 for toggle-read-only. Note that this hasn't called vc-next-action
8 since 2008-05-02, though it wasn't documented at the time. 100 since 2008-05-02, though it wasn't documented at the time.
9 101
10 * vc/ediff-init.el (ediff-toggle-read-only-function): Use 102 * vc/ediff-init.el (ediff-toggle-read-only-function):
11 toggle-read-only. 103 Use toggle-read-only.
12 104
132011-10-22 Alan Mackenzie <bug-cc-mode@gnu.org> 1052011-10-22 Alan Mackenzie <bug-cc-mode@gnu.org>
14 106
15 Fix bug #9560, sporadic wrong indentation; improve instrumentation 107 Fix bug #9560, sporadic wrong indentation; improve instrumentation
16 of c-parse-state. 108 of c-parse-state.
17 109
18 * cc-engine.el (c-append-lower-brace-pair-to-state-cache): correct 110 * cc-engine.el (c-append-lower-brace-pair-to-state-cache):
19 faulty logical expression. 111 correct faulty logical expression.
20 (c-parse-state-state, c-record-parse-state-state): 112 (c-parse-state-state, c-record-parse-state-state):
21 (c-replay-parse-state-state): New defvar/defuns. 113 (c-replay-parse-state-state): New defvar/defuns.
22 (c-debug-parse-state): Use new functions. 114 (c-debug-parse-state): Use new functions.
@@ -30,8 +122,8 @@
30 122
31 * progmodes/idlwave.el (idlwave-mode): 123 * progmodes/idlwave.el (idlwave-mode):
32 * progmodes/vera-mode.el (vera-mode): No need to set 124 * progmodes/vera-mode.el (vera-mode): No need to set
33 require-final-newline; that's done in prog-mode. Suggested by 125 require-final-newline; that's done in prog-mode.
34 Stefan Monnier. 126 Suggested by Stefan Monnier.
35 127
362011-10-21 Martin Rudalics <rudalics@gmx.at> 1282011-10-21 Martin Rudalics <rudalics@gmx.at>
37 129
@@ -52,8 +144,8 @@
522011-10-21 Chong Yidong <cyd@gnu.org> 1442011-10-21 Chong Yidong <cyd@gnu.org>
53 145
54 * progmodes/idlwave.el (idlwave-mode): 146 * progmodes/idlwave.el (idlwave-mode):
55 * progmodes/vera-mode.el (vera-mode): Use 147 * progmodes/vera-mode.el (vera-mode):
56 mode-require-final-newline. 148 Use mode-require-final-newline.
57 149
582011-10-20 Glenn Morris <rgm@gnu.org> 1502011-10-20 Glenn Morris <rgm@gnu.org>
59 151
@@ -189,8 +281,8 @@
189 (global-whitespace-mode, global-whitespace-newline-mode): 281 (global-whitespace-mode, global-whitespace-newline-mode):
190 * xt-mouse.el (xterm-mouse-mode): Doc fix. 282 * xt-mouse.el (xterm-mouse-mode): Doc fix.
191 283
192 * emacs-lisp/easy-mmode.el (define-globalized-minor-mode): Fix 284 * emacs-lisp/easy-mmode.el (define-globalized-minor-mode):
193 autogenerated docstring. 285 Fix autogenerated docstring.
194 286
1952011-10-19 Juri Linkov <juri@jurta.org> 2872011-10-19 Juri Linkov <juri@jurta.org>
196 288
diff --git a/lisp/comint.el b/lisp/comint.el
index 591be5e2d9d..b91b82adb21 100644
--- a/lisp/comint.el
+++ b/lisp/comint.el
@@ -2151,8 +2151,10 @@ current line, if point is on an output field.
2151If `comint-use-prompt-regexp' is non-nil, then return 2151If `comint-use-prompt-regexp' is non-nil, then return
2152the current line with any initial string matching the regexp 2152the current line with any initial string matching the regexp
2153`comint-prompt-regexp' removed." 2153`comint-prompt-regexp' removed."
2154 (let ((bof (field-beginning))) 2154 (let (bof)
2155 (if (null (get-char-property bof 'field)) ;Not `output'. 2155 (if (and (not comint-use-prompt-regexp)
2156 ;; Make sure we're in an input rather than output field.
2157 (null (get-char-property (setq bof (field-beginning)) 'field)))
2156 (field-string-no-properties bof) 2158 (field-string-no-properties bof)
2157 (comint-bol) 2159 (comint-bol)
2158 (buffer-substring-no-properties (point) (line-end-position))))) 2160 (buffer-substring-no-properties (point) (line-end-position)))))
diff --git a/lisp/emacs-lisp/cl-extra.el b/lisp/emacs-lisp/cl-extra.el
index 7468a0237cf..8ea58b2e07c 100644
--- a/lisp/emacs-lisp/cl-extra.el
+++ b/lisp/emacs-lisp/cl-extra.el
@@ -480,17 +480,13 @@ If STATE is t, return a new state object seeded from the time of day."
480 (and (numberp res) (/= res (/ res 2)) res)) 480 (and (numberp res) (/= res (/ res 2)) res))
481 (arith-error nil))) 481 (arith-error nil)))
482 482
483(defvar most-positive-float)
484(defvar most-negative-float)
485(defvar least-positive-float)
486(defvar least-negative-float)
487(defvar least-positive-normalized-float)
488(defvar least-negative-normalized-float)
489(defvar float-epsilon)
490(defvar float-negative-epsilon)
491
492;;;###autoload 483;;;###autoload
493(defun cl-float-limits () 484(defun cl-float-limits ()
485 "Initialize the Common Lisp floating-point parameters.
486This sets the values of: `most-positive-float', `most-negative-float',
487`least-positive-float', `least-negative-float', `float-epsilon',
488`float-negative-epsilon', `least-positive-normalized-float', and
489`least-negative-normalized-float'."
494 (or most-positive-float (not (numberp '2e1)) 490 (or most-positive-float (not (numberp '2e1))
495 (let ((x '2e0) y z) 491 (let ((x '2e0) y z)
496 ;; Find maximum exponent (first two loops are optimizations) 492 ;; Find maximum exponent (first two loops are optimizations)
diff --git a/lisp/emacs-lisp/cl-loaddefs.el b/lisp/emacs-lisp/cl-loaddefs.el
index d6512306ad1..1cd953d9e18 100644
--- a/lisp/emacs-lisp/cl-loaddefs.el
+++ b/lisp/emacs-lisp/cl-loaddefs.el
@@ -10,7 +10,7 @@
10;;;;;; ceiling* floor* isqrt lcm gcd cl-progv-before cl-set-frame-visible-p 10;;;;;; ceiling* floor* isqrt lcm gcd cl-progv-before cl-set-frame-visible-p
11;;;;;; cl-map-overlays cl-map-intervals cl-map-keymap-recursively 11;;;;;; cl-map-overlays cl-map-intervals cl-map-keymap-recursively
12;;;;;; notevery notany every some mapcon mapcan mapl maplist map 12;;;;;; notevery notany every some mapcon mapcan mapl maplist map
13;;;;;; cl-mapcar-many equalp coerce) "cl-extra" "cl-extra.el" "26339d9571f9485bf34fa6d2ae38fc84") 13;;;;;; cl-mapcar-many equalp coerce) "cl-extra" "cl-extra.el" "15a5e127e1c9c9c3d1f398963b66cde7")
14;;; Generated autoloads from cl-extra.el 14;;; Generated autoloads from cl-extra.el
15 15
16(autoload 'coerce "cl-extra" "\ 16(autoload 'coerce "cl-extra" "\
@@ -28,7 +28,7 @@ strings case-insensitively.
28\(fn X Y)" nil nil) 28\(fn X Y)" nil nil)
29 29
30(autoload 'cl-mapcar-many "cl-extra" "\ 30(autoload 'cl-mapcar-many "cl-extra" "\
31Not documented 31
32 32
33\(fn CL-FUNC CL-SEQS)" nil nil) 33\(fn CL-FUNC CL-SEQS)" nil nil)
34 34
@@ -84,27 +84,27 @@ Return true if PREDICATE is false of some element of SEQ or SEQs.
84(defalias 'cl-map-keymap 'map-keymap) 84(defalias 'cl-map-keymap 'map-keymap)
85 85
86(autoload 'cl-map-keymap-recursively "cl-extra" "\ 86(autoload 'cl-map-keymap-recursively "cl-extra" "\
87Not documented 87
88 88
89\(fn CL-FUNC-REC CL-MAP &optional CL-BASE)" nil nil) 89\(fn CL-FUNC-REC CL-MAP &optional CL-BASE)" nil nil)
90 90
91(autoload 'cl-map-intervals "cl-extra" "\ 91(autoload 'cl-map-intervals "cl-extra" "\
92Not documented 92
93 93
94\(fn CL-FUNC &optional CL-WHAT CL-PROP CL-START CL-END)" nil nil) 94\(fn CL-FUNC &optional CL-WHAT CL-PROP CL-START CL-END)" nil nil)
95 95
96(autoload 'cl-map-overlays "cl-extra" "\ 96(autoload 'cl-map-overlays "cl-extra" "\
97Not documented 97
98 98
99\(fn CL-FUNC &optional CL-BUFFER CL-START CL-END CL-ARG)" nil nil) 99\(fn CL-FUNC &optional CL-BUFFER CL-START CL-END CL-ARG)" nil nil)
100 100
101(autoload 'cl-set-frame-visible-p "cl-extra" "\ 101(autoload 'cl-set-frame-visible-p "cl-extra" "\
102Not documented 102
103 103
104\(fn FRAME VAL)" nil nil) 104\(fn FRAME VAL)" nil nil)
105 105
106(autoload 'cl-progv-before "cl-extra" "\ 106(autoload 'cl-progv-before "cl-extra" "\
107Not documented 107
108 108
109\(fn SYMS VALUES)" nil nil) 109\(fn SYMS VALUES)" nil nil)
110 110
@@ -180,7 +180,11 @@ Return t if OBJECT is a random-state object.
180\(fn OBJECT)" nil nil) 180\(fn OBJECT)" nil nil)
181 181
182(autoload 'cl-float-limits "cl-extra" "\ 182(autoload 'cl-float-limits "cl-extra" "\
183Not documented 183Initialize the Common Lisp floating-point parameters.
184This sets the values of: `most-positive-float', `most-negative-float',
185`least-positive-float', `least-negative-float', `float-epsilon',
186`float-negative-epsilon', `least-positive-normalized-float', and
187`least-negative-normalized-float'.
184 188
185\(fn)" nil nil) 189\(fn)" nil nil)
186 190
@@ -228,12 +232,12 @@ PROPLIST is a list of the sort returned by `symbol-plist'.
228\(fn PROPLIST PROPNAME &optional DEFAULT)" nil nil) 232\(fn PROPLIST PROPNAME &optional DEFAULT)" nil nil)
229 233
230(autoload 'cl-set-getf "cl-extra" "\ 234(autoload 'cl-set-getf "cl-extra" "\
231Not documented 235
232 236
233\(fn PLIST TAG VAL)" nil nil) 237\(fn PLIST TAG VAL)" nil nil)
234 238
235(autoload 'cl-do-remf "cl-extra" "\ 239(autoload 'cl-do-remf "cl-extra" "\
236Not documented 240
237 241
238\(fn PLIST TAG)" nil nil) 242\(fn PLIST TAG)" nil nil)
239 243
@@ -267,7 +271,7 @@ This also does some trivial optimizations to make the form prettier.
267\(fn FORM &optional ENV)" nil nil) 271\(fn FORM &optional ENV)" nil nil)
268 272
269(autoload 'cl-prettyexpand "cl-extra" "\ 273(autoload 'cl-prettyexpand "cl-extra" "\
270Not documented 274
271 275
272\(fn FORM &optional FULL)" nil nil) 276\(fn FORM &optional FULL)" nil nil)
273 277
diff --git a/lisp/emacs-lisp/cl.el b/lisp/emacs-lisp/cl.el
index 526475eb1bd..16eb31c1209 100644
--- a/lisp/emacs-lisp/cl.el
+++ b/lisp/emacs-lisp/cl.el
@@ -333,15 +333,51 @@ always returns nil."
333 333
334(defvar *random-state* (vector 'cl-random-state-tag -1 30 (cl-random-time))) 334(defvar *random-state* (vector 'cl-random-state-tag -1 30 (cl-random-time)))
335 335
336;; The following are actually set by cl-float-limits. 336(defconst most-positive-float nil
337(defconst most-positive-float nil) 337 "The largest value that a Lisp float can hold.
338(defconst most-negative-float nil) 338If your system supports infinities, this is the largest finite value.
339(defconst least-positive-float nil) 339For IEEE machines, this is approximately 1.79e+308.
340(defconst least-negative-float nil) 340Call `cl-float-limits' to set this.")
341(defconst least-positive-normalized-float nil) 341
342(defconst least-negative-normalized-float nil) 342(defconst most-negative-float nil
343(defconst float-epsilon nil) 343 "The largest negative value that a Lisp float can hold.
344(defconst float-negative-epsilon nil) 344This is simply -`most-positive-float'.
345Call `cl-float-limits' to set this.")
346
347(defconst least-positive-float nil
348 "The smallest value greater than zero that a Lisp float can hold.
349For IEEE machines, it is about 4.94e-324 if denormals are supported,
350or 2.22e-308 if they are not.
351Call `cl-float-limits' to set this.")
352
353(defconst least-negative-float nil
354 "The smallest value less than zero that a Lisp float can hold.
355This is simply -`least-positive-float'.
356Call `cl-float-limits' to set this.")
357
358(defconst least-positive-normalized-float nil
359 "The smallest normalized Lisp float greater than zero.
360This is the smallest value for which IEEE denormalization does not lose
361precision. For IEEE machines, this value is about 2.22e-308.
362For machines that do not support the concept of denormalization
363and gradual underflow, this constant equals `least-positive-float'.
364Call `cl-float-limits' to set this.")
365
366(defconst least-negative-normalized-float nil
367 "The smallest normalized Lisp float less than zero.
368This is simply -`least-positive-normalized-float'.
369Call `cl-float-limits' to set this.")
370
371(defconst float-epsilon nil
372 "The smallest positive float that adds to 1.0 to give a distinct value.
373Adding a number less than this to 1.0 returns 1.0 due to roundoff.
374For IEEE machines, epsilon is about 2.22e-16.
375Call `cl-float-limits' to set this.")
376
377(defconst float-negative-epsilon nil
378 "The smallest positive float that subtracts from 1.0 to give a distinct value.
379For IEEE machines, it is about 1.11e-16.
380Call `cl-float-limits' to set this.")
345 381
346 382
347;;; Sequence functions. 383;;; Sequence functions.
diff --git a/lisp/emacs-lisp/derived.el b/lisp/emacs-lisp/derived.el
index 81932f9940a..55ea102ed2a 100644
--- a/lisp/emacs-lisp/derived.el
+++ b/lisp/emacs-lisp/derived.el
@@ -230,7 +230,7 @@ No problems result if this variable is not bound.
230 ; Run the parent. 230 ; Run the parent.
231 (delay-mode-hooks 231 (delay-mode-hooks
232 232
233 (,(or parent 'fundamental-mode)) 233 (,(or parent 'kill-all-local-variables))
234 ; Identify the child mode. 234 ; Identify the child mode.
235 (setq major-mode (quote ,child)) 235 (setq major-mode (quote ,child))
236 (setq mode-name ,name) 236 (setq mode-name ,name)
diff --git a/lisp/emacs-lisp/easy-mmode.el b/lisp/emacs-lisp/easy-mmode.el
index b1cb0615e43..bf9f2c9d6ed 100644
--- a/lisp/emacs-lisp/easy-mmode.el
+++ b/lisp/emacs-lisp/easy-mmode.el
@@ -94,8 +94,9 @@ Optional LIGHTER is displayed in the modeline when the mode is on.
94Optional KEYMAP is the default keymap bound to the mode keymap. 94Optional KEYMAP is the default keymap bound to the mode keymap.
95 If non-nil, it should be a variable name (whose value is a keymap), 95 If non-nil, it should be a variable name (whose value is a keymap),
96 or an expression that returns either a keymap or a list of 96 or an expression that returns either a keymap or a list of
97 arguments for `easy-mmode-define-keymap'. If KEYMAP is not a symbol, 97 arguments for `easy-mmode-define-keymap'. If you supply a KEYMAP
98 this also defines the variable MODE-map. 98 argument that is not a symbol, this macro defines the variable
99 MODE-map and gives it the value that KEYMAP specifies.
99 100
100BODY contains code to execute each time the mode is enabled or disabled. 101BODY contains code to execute each time the mode is enabled or disabled.
101 It is executed after toggling the mode, and before running MODE-hook. 102 It is executed after toggling the mode, and before running MODE-hook.
@@ -367,11 +368,13 @@ See `%s' for more information on %s."
367 (progn 368 (progn
368 (add-hook 'after-change-major-mode-hook 369 (add-hook 'after-change-major-mode-hook
369 ',MODE-enable-in-buffers) 370 ',MODE-enable-in-buffers)
370 (add-hook 'fundamental-mode-hook ',MODE-enable-in-buffers) 371 (add-hook 'change-major-mode-after-body-hook
372 ',MODE-enable-in-buffers)
371 (add-hook 'find-file-hook ',MODE-check-buffers) 373 (add-hook 'find-file-hook ',MODE-check-buffers)
372 (add-hook 'change-major-mode-hook ',MODE-cmhh)) 374 (add-hook 'change-major-mode-hook ',MODE-cmhh))
373 (remove-hook 'after-change-major-mode-hook ',MODE-enable-in-buffers) 375 (remove-hook 'after-change-major-mode-hook ',MODE-enable-in-buffers)
374 (remove-hook 'fundamental-mode-hook ',MODE-enable-in-buffers) 376 (remove-hook 'change-major-mode-after-body-hook
377 ',MODE-enable-in-buffers)
375 (remove-hook 'find-file-hook ',MODE-check-buffers) 378 (remove-hook 'find-file-hook ',MODE-check-buffers)
376 (remove-hook 'change-major-mode-hook ',MODE-cmhh)) 379 (remove-hook 'change-major-mode-hook ',MODE-cmhh))
377 380
diff --git a/lisp/facemenu.el b/lisp/facemenu.el
index 54b17d58f33..4f9db02b5e1 100644
--- a/lisp/facemenu.el
+++ b/lisp/facemenu.el
@@ -645,6 +645,8 @@ a list of colors that the current display can handle."
645 ;; text in menu entries) and `SystemWindowText' (the default 645 ;; text in menu entries) and `SystemWindowText' (the default
646 ;; color w32 uses for the text in windows and dialogs) may 646 ;; color w32 uses for the text in windows and dialogs) may
647 ;; be the same display color and be adjacent in the list. 647 ;; be the same display color and be adjacent in the list.
648 ;; These system colors all have names prefixed with "System",
649 ;; which is hardcoded in w32fns.c (SYSTEM_COLOR_PREFIX).
648 ;; This makes them different to any other color. Bug#9722 650 ;; This makes them different to any other color. Bug#9722
649 (not (and (eq system-type 'windows-nt) 651 (not (and (eq system-type 'windows-nt)
650 (string-match-p "^System" (car (car l)))))) 652 (string-match-p "^System" (car (car l))))))
diff --git a/lisp/files.el b/lisp/files.el
index 3ed9bd5a272..40e2df14c1b 100644
--- a/lisp/files.el
+++ b/lisp/files.el
@@ -3682,7 +3682,11 @@ the old visited file has been renamed to the new name FILENAME."
3682 (get major-mode 'mode-class) 3682 (get major-mode 'mode-class)
3683 ;; Don't change the mode if the local variable list specifies it. 3683 ;; Don't change the mode if the local variable list specifies it.
3684 (hack-local-variables t) 3684 (hack-local-variables t)
3685 (set-auto-mode t)) 3685 ;; TODO consider making normal-mode handle this case.
3686 (let ((old major-mode))
3687 (set-auto-mode t)
3688 (or (eq old major-mode)
3689 (hack-local-variables))))
3686 (error nil))) 3690 (error nil)))
3687 3691
3688(defun write-file (filename &optional confirm) 3692(defun write-file (filename &optional confirm)
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog
index 592d0671c26..7519252f037 100644
--- a/lisp/gnus/ChangeLog
+++ b/lisp/gnus/ChangeLog
@@ -1,8 +1,19 @@
12011-10-26 Stefan Monnier <monnier@iro.umontreal.ca>
2
3 * message.el (message-completion-function): Make sure
4 message-tab-body-function is not attempted if one of
5 message-completion-alist fails to find a completion (bug#9158).
6
72011-10-26 Daiki Ueno <ueno@unixuser.org>
8
9 * mml.el (mml-quote-region): Quote <#secure> tag.
10 (mml-generate-mime-1): Unquote <#secure> tag.
11
12011-10-20 Chong Yidong <cyd@gnu.org> 122011-10-20 Chong Yidong <cyd@gnu.org>
2 13
3 * gnus-cite.el (gnus-message-citation-mode): Doc fix (in Emacs 24, 14 * gnus-cite.el (gnus-message-citation-mode): Doc fix (in Emacs 24,
4 calling a minor mode from Lisp with nil arg enables it, so we have to 15 calling a minor mode from Lisp with nil arg enables it, so we have to
5 make the working a bit ambiguous here). 16 make the wording a bit ambiguous here).
6 17
72011-10-18 Teodor Zlatanov <tzz@lifelogs.com> 182011-10-18 Teodor Zlatanov <tzz@lifelogs.com>
8 19
@@ -18548,7 +18559,7 @@
18548 gnus-requst-update-info with explicit code to sync the in-memory 18559 gnus-requst-update-info with explicit code to sync the in-memory
18549 info read flags with the marks being sync'd to the backend. 18560 info read flags with the marks being sync'd to the backend.
18550 18561
18551 *gnus-util.el (gnus-pp): Add optional stream to match pp API. 18562 * gnus-util.el (gnus-pp): Add optional stream to match pp API.
18552 18563
185532004-09-28 Teodor Zlatanov <tzz@lifelogs.com> 185642004-09-28 Teodor Zlatanov <tzz@lifelogs.com>
18554 18565
diff --git a/lisp/gnus/message.el b/lisp/gnus/message.el
index 948892d1e13..723f8fb72b5 100644
--- a/lisp/gnus/message.el
+++ b/lisp/gnus/message.el
@@ -7888,7 +7888,11 @@ those headers."
7888 (let ((mail-abbrev-mode-regexp (caar alist))) 7888 (let ((mail-abbrev-mode-regexp (caar alist)))
7889 (not (mail-abbrev-in-expansion-header-p)))) 7889 (not (mail-abbrev-in-expansion-header-p))))
7890 (setq alist (cdr alist))) 7890 (setq alist (cdr alist)))
7891 (cdar alist))) 7891 (when (cdar alist)
7892 (lexical-let ((fun (cdar alist)))
7893 ;; Even if completion fails, return a non-nil value, so as to avoid
7894 ;; falling back to message-tab-body-function.
7895 (lambda () (funcall fun) 'completion-attempted)))))
7892 7896
7893(eval-and-compile 7897(eval-and-compile
7894 (condition-case nil 7898 (condition-case nil
diff --git a/lisp/gnus/mml.el b/lisp/gnus/mml.el
index 0d2ae2a845a..352fa329e3e 100644
--- a/lisp/gnus/mml.el
+++ b/lisp/gnus/mml.el
@@ -525,7 +525,7 @@ If MML is non-nil, return the buffer up till the correspondent mml tag."
525 ;; Remove quotes from quoted tags. 525 ;; Remove quotes from quoted tags.
526 (goto-char (point-min)) 526 (goto-char (point-min))
527 (while (re-search-forward 527 (while (re-search-forward
528 "<#!+/?\\(part\\|multipart\\|external\\|mml\\)" 528 "<#!+/?\\(part\\|multipart\\|external\\|mml\\|secure\\)"
529 nil t) 529 nil t)
530 (delete-region (+ (match-beginning 0) 2) 530 (delete-region (+ (match-beginning 0) 2)
531 (+ (match-beginning 0) 3)))))) 531 (+ (match-beginning 0) 3))))))
@@ -1232,7 +1232,7 @@ If not set, `default-directory' will be used."
1232 (goto-char (point-min)) 1232 (goto-char (point-min))
1233 ;; Quote parts. 1233 ;; Quote parts.
1234 (while (re-search-forward 1234 (while (re-search-forward
1235 "<#!*/?\\(multipart\\|part\\|external\\|mml\\)" nil t) 1235 "<#!*/?\\(multipart\\|part\\|external\\|mml\\|secure\\)" nil t)
1236 ;; Insert ! after the #. 1236 ;; Insert ! after the #.
1237 (goto-char (+ (match-beginning 0) 2)) 1237 (goto-char (+ (match-beginning 0) 2))
1238 (insert "!"))))) 1238 (insert "!")))))
diff --git a/lisp/ido.el b/lisp/ido.el
index 88599013ce6..fda4c0316f7 100644
--- a/lisp/ido.el
+++ b/lisp/ido.el
@@ -3457,8 +3457,6 @@ This is to make them appear as if they were \"virtual buffers\"."
3457 (nconc ido-temp-list items) 3457 (nconc ido-temp-list items)
3458 (setq ido-temp-list items))) 3458 (setq ido-temp-list items)))
3459 3459
3460(declare-function tramp-tramp-file-p "tramp" (name))
3461
3462(defun ido-file-name-all-completions-1 (dir) 3460(defun ido-file-name-all-completions-1 (dir)
3463 (cond 3461 (cond
3464 ((ido-nonreadable-directory-p dir) '()) 3462 ((ido-nonreadable-directory-p dir) '())
@@ -3466,8 +3464,6 @@ This is to make them appear as if they were \"virtual buffers\"."
3466 ;; Caller must have done that if necessary. 3464 ;; Caller must have done that if necessary.
3467 3465
3468 ((and ido-enable-tramp-completion 3466 ((and ido-enable-tramp-completion
3469 (or (fboundp 'tramp-completion-mode-p)
3470 (require 'tramp nil t))
3471 (string-match "\\`/[^/]+[:@]\\'" dir)) 3467 (string-match "\\`/[^/]+[:@]\\'" dir))
3472 ;; Strip method:user@host: part of tramp completions. 3468 ;; Strip method:user@host: part of tramp completions.
3473 ;; Tramp completions do not include leading slash. 3469 ;; Tramp completions do not include leading slash.
@@ -3480,7 +3476,9 @@ This is to make them appear as if they were \"virtual buffers\"."
3480 ;; /ftp:user@host:./ => ok 3476 ;; /ftp:user@host:./ => ok
3481 (and 3477 (and
3482 (not (string= "/ftp:" dir)) 3478 (not (string= "/ftp:" dir))
3483 (tramp-tramp-file-p dir) 3479 (file-remote-p dir)
3480 ;; tramp-ftp-file-name-p is available only when tramp
3481 ;; has been loaded.
3484 (fboundp 'tramp-ftp-file-name-p) 3482 (fboundp 'tramp-ftp-file-name-p)
3485 (funcall 'tramp-ftp-file-name-p dir) 3483 (funcall 'tramp-ftp-file-name-p dir)
3486 (string-match ":\\'" dir) 3484 (string-match ":\\'" dir)
diff --git a/lisp/info.el b/lisp/info.el
index 4ccbeba2a47..b8deb3c9c7f 100644
--- a/lisp/info.el
+++ b/lisp/info.el
@@ -2015,7 +2015,7 @@ Submatch 1 is the complete node name.
2015Submatch 2 if non-nil is the parenthesized file name part of the node name. 2015Submatch 2 if non-nil is the parenthesized file name part of the node name.
2016Submatch 3 is the local part of the node name. 2016Submatch 3 is the local part of the node name.
2017End of submatch 0, 1, and 3 are the same, so you can safely concat." 2017End of submatch 0, 1, and 3 are the same, so you can safely concat."
2018 (concat "[ \t]*" ;Skip leading space. 2018 (concat "[ \t\n]*" ;Skip leading space.
2019 "\\(\\(([^)]+)\\)?" ;Node name can start with a file name. 2019 "\\(\\(([^)]+)\\)?" ;Node name can start with a file name.
2020 "\\([" (or allowedchars "^,\t\n") "]*" ;Any number of allowed chars. 2020 "\\([" (or allowedchars "^,\t\n") "]*" ;Any number of allowed chars.
2021 "[" (or allowedchars "^,\t\n") " ]" ;The last char can't be a space. 2021 "[" (or allowedchars "^,\t\n") " ]" ;The last char can't be a space.
diff --git a/lisp/international/mule-conf.el b/lisp/international/mule-conf.el
index 9ba95e4d11a..870f2bece28 100644
--- a/lisp/international/mule-conf.el
+++ b/lisp/international/mule-conf.el
@@ -708,7 +708,7 @@
708(define-charset-alias 'cp866u 'cp1125) 708(define-charset-alias 'cp866u 'cp1125)
709 709
710;; Fixme: C.f. iconv, http://czyborra.com/charsets/codepages.html 710;; Fixme: C.f. iconv, http://czyborra.com/charsets/codepages.html
711;; shows this as not ASCII comptaible, with various graphics in 711;; shows this as not ASCII compatible, with various graphics in
712;; 0x01-0x1F. 712;; 0x01-0x1F.
713(define-charset 'cp437 713(define-charset 'cp437
714 "CP437 (MS-DOS United States, Australia, New Zealand, South Africa)" 714 "CP437 (MS-DOS United States, Australia, New Zealand, South Africa)"
diff --git a/lisp/isearch.el b/lisp/isearch.el
index 6cfcce59672..6bb23916da3 100644
--- a/lisp/isearch.el
+++ b/lisp/isearch.el
@@ -1452,7 +1452,7 @@ string. NLINES has the same meaning as in `occur'."
1452 ;; Set `search-upper-case' to nil to not call 1452 ;; Set `search-upper-case' to nil to not call
1453 ;; `isearch-no-upper-case-p' in `occur-1'. 1453 ;; `isearch-no-upper-case-p' in `occur-1'.
1454 (search-upper-case nil) 1454 (search-upper-case nil)
1455 (search-spaces-regexp search-whitespace-regexp)) 1455 (search-spaces-regexp (if isearch-regexp search-whitespace-regexp)))
1456 (occur regexp nlines))) 1456 (occur regexp nlines)))
1457 1457
1458(declare-function hi-lock-read-face-name "hi-lock" ()) 1458(declare-function hi-lock-read-face-name "hi-lock" ())
diff --git a/lisp/net/tramp-cache.el b/lisp/net/tramp-cache.el
index 9397025cb60..b35ca3bbd18 100644
--- a/lisp/net/tramp-cache.el
+++ b/lisp/net/tramp-cache.el
@@ -383,7 +383,8 @@ for all methods. Resulting data are derived from connection history."
383 ;; When "emacs -Q" has been called, both variables are nil. 383 ;; When "emacs -Q" has been called, both variables are nil.
384 ;; We do not load the persistency file then, in order to 384 ;; We do not load the persistency file then, in order to
385 ;; have a clean test environment. 385 ;; have a clean test environment.
386 (or init-file-user site-run-file)) 386 (or (and (boundp 'init-file-user) (symbol-value 'init-file-user))
387 (and (boundp 'site-run-file) (symbol-value 'site-run-file))))
387 (condition-case err 388 (condition-case err
388 (with-temp-buffer 389 (with-temp-buffer
389 (insert-file-contents tramp-persistency-file-name) 390 (insert-file-contents tramp-persistency-file-name)
diff --git a/lisp/net/tramp-sh.el b/lisp/net/tramp-sh.el
index 56424f79476..55732194bc8 100644
--- a/lisp/net/tramp-sh.el
+++ b/lisp/net/tramp-sh.el
@@ -1594,17 +1594,14 @@ and gid of the corresponding user is taken. Both parameters must be integers."
1594 1594
1595(defun tramp-sh-handle-file-directory-p (filename) 1595(defun tramp-sh-handle-file-directory-p (filename)
1596 "Like `file-directory-p' for Tramp files." 1596 "Like `file-directory-p' for Tramp files."
1597 ;; Care must be taken that this function returns `t' for symlinks
1598 ;; pointing to directories. Surely the most obvious implementation
1599 ;; would be `test -d', but that returns false for such symlinks.
1600 ;; CCC: Stefan Monnier says that `test -d' follows symlinks. And
1601 ;; I now think he's right. So we could be using `test -d', couldn't
1602 ;; we?
1603 ;;
1604 ;; Alternatives: `cd %s', `test -d %s'
1605 (with-parsed-tramp-file-name filename nil 1597 (with-parsed-tramp-file-name filename nil
1606 (with-file-property v localname "file-directory-p" 1598 ;; `file-directory-p' is used as predicate for filename completion.
1607 (tramp-run-test "-d" filename)))) 1599 ;; Sometimes, when a connection is not established yet, it is
1600 ;; desirable to return t immediately for "/method:foo:". It can
1601 ;; be expected that this is always a directory.
1602 (or (zerop (length localname))
1603 (with-file-property v localname "file-directory-p"
1604 (tramp-run-test "-d" filename)))))
1608 1605
1609(defun tramp-sh-handle-file-writable-p (filename) 1606(defun tramp-sh-handle-file-writable-p (filename)
1610 "Like `file-writable-p' for Tramp files." 1607 "Like `file-writable-p' for Tramp files."
diff --git a/lisp/net/trampver.el b/lisp/net/trampver.el
index 5492441ac77..fc0c936c407 100644
--- a/lisp/net/trampver.el
+++ b/lisp/net/trampver.el
@@ -31,7 +31,7 @@
31;; should be changed only there. 31;; should be changed only there.
32 32
33;;;###tramp-autoload 33;;;###tramp-autoload
34(defconst tramp-version "2.2.3-pre" 34(defconst tramp-version "2.2.3-24.1"
35 "This version of Tramp.") 35 "This version of Tramp.")
36 36
37;;;###tramp-autoload 37;;;###tramp-autoload
@@ -44,7 +44,7 @@
44 (= emacs-major-version 21) 44 (= emacs-major-version 21)
45 (>= emacs-minor-version 4))) 45 (>= emacs-minor-version 4)))
46 "ok" 46 "ok"
47 (format "Tramp 2.2.3-pre is not fit for %s" 47 (format "Tramp 2.2.3-24.1 is not fit for %s"
48 (when (string-match "^.*$" (emacs-version)) 48 (when (string-match "^.*$" (emacs-version))
49 (match-string 0 (emacs-version))))))) 49 (match-string 0 (emacs-version)))))))
50 (unless (string-match "\\`ok\\'" x) (error "%s" x))) 50 (unless (string-match "\\`ok\\'" x) (error "%s" x)))
diff --git a/lisp/notifications.el b/lisp/notifications.el
index 42cd40df36b..a4e7fdd5425 100644
--- a/lisp/notifications.el
+++ b/lisp/notifications.el
@@ -30,6 +30,9 @@
30;; 30;;
31;; (require 'notifications) 31;; (require 'notifications)
32 32
33;; For proper usage, Emacs must be started in an environment with an
34;; active D-Bus session bus.
35
33;;; Code: 36;;; Code:
34(eval-when-compile 37(eval-when-compile
35 (require 'cl)) 38 (require 'cl))
diff --git a/lisp/org/ChangeLog b/lisp/org/ChangeLog
index 9fbeb9f1882..ae150621dc0 100644
--- a/lisp/org/ChangeLog
+++ b/lisp/org/ChangeLog
@@ -1871,7 +1871,7 @@
1871 1871
1872 * org-list.el (org-list-separating-blank-lines-number): Fix 1872 * org-list.el (org-list-separating-blank-lines-number): Fix
1873 confusion between point and item beginning. Now, if no 1873 confusion between point and item beginning. Now, if no
1874 information is avalaible, truly follow user preference when it 1874 information is available, truly follow user preference when it
1875 inserts blank lines manually. 1875 inserts blank lines manually.
1876 (org-list-insert-item): Send correct argument to the preceding 1876 (org-list-insert-item): Send correct argument to the preceding
1877 function. 1877 function.
diff --git a/lisp/progmodes/octave-inf.el b/lisp/progmodes/octave-inf.el
index cb64b2436c6..421f476016e 100644
--- a/lisp/progmodes/octave-inf.el
+++ b/lisp/progmodes/octave-inf.el
@@ -4,7 +4,7 @@
4 4
5;; Author: Kurt Hornik <Kurt.Hornik@wu-wien.ac.at> 5;; Author: Kurt Hornik <Kurt.Hornik@wu-wien.ac.at>
6;; Author: John Eaton <jwe@bevo.che.wisc.edu> 6;; Author: John Eaton <jwe@bevo.che.wisc.edu>
7;; Maintainer: Kurt Hornik <Kurt.Hornik@wu-wien.ac.at> 7;; Maintainer: FSF
8;; Keywords: languages 8;; Keywords: languages
9;; Package: octave-mod 9;; Package: octave-mod
10 10
@@ -68,7 +68,8 @@ mode, set this to (\"-q\" \"--traditional\")."
68 (define-key map "\C-c\C-l" 'inferior-octave-dynamic-list-input-ring) 68 (define-key map "\C-c\C-l" 'inferior-octave-dynamic-list-input-ring)
69 (define-key map [menu-bar inout list-history] 69 (define-key map [menu-bar inout list-history]
70 '("List Input History" . inferior-octave-dynamic-list-input-ring)) 70 '("List Input History" . inferior-octave-dynamic-list-input-ring))
71 (define-key map "\C-c\C-h" 'octave-help) 71 ;; FIXME: free C-h so it can do the describe-prefix-bindings.
72 (define-key map "\C-c\C-h" 'info-lookup-symbol)
72 map) 73 map)
73 "Keymap used in Inferior Octave mode.") 74 "Keymap used in Inferior Octave mode.")
74 75
diff --git a/lisp/progmodes/octave-mod.el b/lisp/progmodes/octave-mod.el
index 183347cdeca..28e25a35c70 100644
--- a/lisp/progmodes/octave-mod.el
+++ b/lisp/progmodes/octave-mod.el
@@ -4,7 +4,7 @@
4 4
5;; Author: Kurt Hornik <Kurt.Hornik@wu-wien.ac.at> 5;; Author: Kurt Hornik <Kurt.Hornik@wu-wien.ac.at>
6;; Author: John Eaton <jwe@octave.org> 6;; Author: John Eaton <jwe@octave.org>
7;; Maintainer: Kurt Hornik <Kurt.Hornik@wu-wien.ac.at> 7;; Maintainer: FSF
8;; Keywords: languages 8;; Keywords: languages
9 9
10;; This file is part of GNU Emacs. 10;; This file is part of GNU Emacs.
@@ -223,6 +223,7 @@ parenthetical grouping.")
223 (define-key map "\C-c]" 'smie-close-block) 223 (define-key map "\C-c]" 'smie-close-block)
224 (define-key map "\C-c/" 'smie-close-block) 224 (define-key map "\C-c/" 'smie-close-block)
225 (define-key map "\C-c\C-f" 'octave-insert-defun) 225 (define-key map "\C-c\C-f" 'octave-insert-defun)
226 ;; FIXME: free C-h so it can do the describe-prefix-bindings.
226 (define-key map "\C-c\C-h" 'info-lookup-symbol) 227 (define-key map "\C-c\C-h" 'info-lookup-symbol)
227 (define-key map "\C-c\C-il" 'octave-send-line) 228 (define-key map "\C-c\C-il" 'octave-send-line)
228 (define-key map "\C-c\C-ib" 'octave-send-block) 229 (define-key map "\C-c\C-ib" 'octave-send-block)
@@ -236,6 +237,7 @@ parenthetical grouping.")
236 (define-key map "\C-c\C-i\C-f" 'octave-send-defun) 237 (define-key map "\C-c\C-i\C-f" 'octave-send-defun)
237 (define-key map "\C-c\C-i\C-r" 'octave-send-region) 238 (define-key map "\C-c\C-i\C-r" 'octave-send-region)
238 (define-key map "\C-c\C-i\C-s" 'octave-show-process-buffer) 239 (define-key map "\C-c\C-i\C-s" 'octave-show-process-buffer)
240 ;; FIXME: free C-h so it can do the describe-prefix-bindings.
239 (define-key map "\C-c\C-i\C-h" 'octave-hide-process-buffer) 241 (define-key map "\C-c\C-i\C-h" 'octave-hide-process-buffer)
240 (define-key map "\C-c\C-i\C-k" 'octave-kill-process) 242 (define-key map "\C-c\C-i\C-k" 'octave-kill-process)
241 map) 243 map)
@@ -655,14 +657,6 @@ including a reproducible test case and send the message."
655 657
656 (easy-menu-add octave-mode-menu) 658 (easy-menu-add octave-mode-menu)
657 (octave-initialize-completions)) 659 (octave-initialize-completions))
658
659(defvar info-lookup-mode)
660
661(defun octave-help ()
662 "Get help on Octave symbols from the Octave info files.
663Look up symbol in the function, operator and variable indices of the info files."
664 (let ((info-lookup-mode 'octave-mode))
665 (call-interactively 'info-lookup-symbol)))
666 660
667;;; Miscellaneous useful functions 661;;; Miscellaneous useful functions
668 662
diff --git a/lisp/simple.el b/lisp/simple.el
index 79de6aea3dd..90d22c817b0 100644
--- a/lisp/simple.el
+++ b/lisp/simple.el
@@ -349,7 +349,8 @@ location."
349Other major modes are defined by comparison with this one." 349Other major modes are defined by comparison with this one."
350 (interactive) 350 (interactive)
351 (kill-all-local-variables) 351 (kill-all-local-variables)
352 (run-mode-hooks 'fundamental-mode-hook)) 352 (unless delay-mode-hooks
353 (run-hooks 'after-change-major-mode-hook)))
353 354
354;; Special major modes to view specially formatted data rather than files. 355;; Special major modes to view specially formatted data rather than files.
355 356
diff --git a/lisp/subr.el b/lisp/subr.el
index 05ac198dd13..f3cd4dabe20 100644
--- a/lisp/subr.el
+++ b/lisp/subr.el
@@ -116,8 +116,6 @@ BODY should be a list of Lisp expressions.
116 ;; depend on backquote.el. 116 ;; depend on backquote.el.
117 (list 'function (cons 'lambda cdr))) 117 (list 'function (cons 'lambda cdr)))
118 118
119;; Partial application of functions (similar to "currying").
120;; This function is here rather than in subr.el because it uses CL.
121(defun apply-partially (fun &rest args) 119(defun apply-partially (fun &rest args)
122 "Return a function that is a partial application of FUN to ARGS. 120 "Return a function that is a partial application of FUN to ARGS.
123ARGS is a list of the first N arguments to pass to FUN. 121ARGS is a list of the first N arguments to pass to FUN.
@@ -1366,18 +1364,26 @@ All symbols are bound before the VALUEFORMs are evalled."
1366 ,@(mapcar (lambda (binder) `(setq ,@binder)) binders) 1364 ,@(mapcar (lambda (binder) `(setq ,@binder)) binders)
1367 ,@body)) 1365 ,@body))
1368 1366
1369(defmacro with-wrapper-hook (var args &rest body) 1367(defmacro with-wrapper-hook (hook args &rest body)
1370 "Run BODY wrapped with the VAR hook. 1368 "Run BODY, using wrapper functions from HOOK with additional ARGS.
1371VAR is a special hook: its functions are called with a first argument 1369HOOK is an abnormal hook. Each hook function in HOOK \"wraps\"
1372which is the \"original\" code (the BODY), so the hook function can wrap 1370around the preceding ones, like a set of nested `around' advices.
1373the original function, or call it any number of times (including not calling 1371
1374it at all). This is similar to an `around' advice. 1372Each hook function should accept an argument list consisting of a
1375VAR is normally a symbol (a variable) in which case it is treated like 1373function FUN, followed by the additional arguments in ARGS.
1376a hook, with a buffer-local and a global part. But it can also be an 1374
1377arbitrary expression. 1375The FUN passed to the first hook function in HOOK performs BODY,
1378ARGS is a list of variables which will be passed as additional arguments 1376if it is called with arguments ARGS. The FUN passed to each
1379to each function, after the initial argument, and which the first argument 1377successive hook function is defined based on the preceding hook
1380expects to receive when called." 1378functions; if called with arguments ARGS, it does what the
1379`with-wrapper-hook' call would do if the preceding hook functions
1380were the only ones present in HOOK.
1381
1382In the function definition of each hook function, FUN can be
1383called any number of times (including not calling it at all).
1384That function definition is then used to construct the FUN passed
1385to the next hook function, if any. The last (or \"outermost\")
1386FUN is then called once."
1381 (declare (indent 2) (debug (form sexp body))) 1387 (declare (indent 2) (debug (form sexp body)))
1382 ;; We need those two gensyms because CL's lexical scoping is not available 1388 ;; We need those two gensyms because CL's lexical scoping is not available
1383 ;; for function arguments :-( 1389 ;; for function arguments :-(
@@ -1406,11 +1412,11 @@ expects to receive when called."
1406 ;; Once there are no more functions on the hook, run 1412 ;; Once there are no more functions on the hook, run
1407 ;; the original body. 1413 ;; the original body.
1408 (apply (lambda ,args ,@body) ,argssym))))) 1414 (apply (lambda ,args ,@body) ,argssym)))))
1409 (funcall ,runrestofhook ,var 1415 (funcall ,runrestofhook ,hook
1410 ;; The global part of the hook, if any. 1416 ;; The global part of the hook, if any.
1411 ,(if (symbolp var) 1417 ,(if (symbolp hook)
1412 `(if (local-variable-p ',var) 1418 `(if (local-variable-p ',hook)
1413 (default-value ',var))) 1419 (default-value ',hook)))
1414 (list ,@args))))) 1420 (list ,@args)))))
1415 1421
1416(defun add-to-list (list-var element &optional append compare-fn) 1422(defun add-to-list (list-var element &optional append compare-fn)
@@ -1524,6 +1530,9 @@ if it is empty or a duplicate."
1524(make-variable-buffer-local 'delayed-mode-hooks) 1530(make-variable-buffer-local 'delayed-mode-hooks)
1525(put 'delay-mode-hooks 'permanent-local t) 1531(put 'delay-mode-hooks 'permanent-local t)
1526 1532
1533(defvar change-major-mode-after-body-hook nil
1534 "Normal hook run in major mode functions, before the mode hooks.")
1535
1527(defvar after-change-major-mode-hook nil 1536(defvar after-change-major-mode-hook nil
1528 "Normal hook run at the very end of major mode functions.") 1537 "Normal hook run at the very end of major mode functions.")
1529 1538
@@ -1540,7 +1549,7 @@ FOO-mode-hook."
1540 ;; Normal case, just run the hook as before plus any delayed hooks. 1549 ;; Normal case, just run the hook as before plus any delayed hooks.
1541 (setq hooks (nconc (nreverse delayed-mode-hooks) hooks)) 1550 (setq hooks (nconc (nreverse delayed-mode-hooks) hooks))
1542 (setq delayed-mode-hooks nil) 1551 (setq delayed-mode-hooks nil)
1543 (apply 'run-hooks hooks) 1552 (apply 'run-hooks (cons 'change-major-mode-after-body-hook hooks))
1544 (run-hooks 'after-change-major-mode-hook))) 1553 (run-hooks 'after-change-major-mode-hook)))
1545 1554
1546(defmacro delay-mode-hooks (&rest body) 1555(defmacro delay-mode-hooks (&rest body)
diff --git a/lisp/term/w32-win.el b/lisp/term/w32-win.el
index e4bf031d422..b7f2a69e77b 100644
--- a/lisp/term/w32-win.el
+++ b/lisp/term/w32-win.el
@@ -85,6 +85,7 @@
85(define-obsolete-function-alias 'w32-select-font 'x-select-font "23.1") 85(define-obsolete-function-alias 'w32-select-font 'x-select-font "23.1")
86 86
87(defvar w32-color-map) ;; defined in w32fns.c 87(defvar w32-color-map) ;; defined in w32fns.c
88(make-obsolete 'w32-default-color-map nil "24.1")
88 89
89(declare-function w32-send-sys-command "w32fns.c") 90(declare-function w32-send-sys-command "w32fns.c")
90(declare-function set-message-beep "w32console.c") 91(declare-function set-message-beep "w32console.c")
diff --git a/lisp/textmodes/reftex.el b/lisp/textmodes/reftex.el
index 6f6993980db..cef8a3d1548 100644
--- a/lisp/textmodes/reftex.el
+++ b/lisp/textmodes/reftex.el
@@ -1522,7 +1522,7 @@ Valid actions are: readable, restore, read, kill, write."
1522;;; (while all 1522;;; (while all
1523;;; (when (and (eq (car (car all)) 'bof) 1523;;; (when (and (eq (car (car all)) 'bof)
1524;;; (not (file-regular-p (nth 1 (car all))))) 1524;;; (not (file-regular-p (nth 1 (car all)))))
1525;;; (message "File %s in saved parse info not avalable" (cdr (car all))) 1525;;; (message "File %s in saved parse info not available" (cdr (car all)))
1526;;; (error "File not found")) 1526;;; (error "File not found"))
1527;;; (setq all (cdr all)))) 1527;;; (setq all (cdr all))))
1528 ) 1528 )