+2004-09-20 Luc Teirlinck <teirllm@auburn.edu>
+
+ * subr.el (run-mode-hooks): Run `after-change-major-mode-hook'
+ after the mode-hooks instead of before. Doc fix.
+
2004-09-20 Jason Rumney <jasonr@gnu.org>
* startup.el (command-line) [windows-nt]: Try .emacs first, then
* eshell/esh-ext.el (eshell-explicit-command-char): Doc fix.
- * progmodes/make-mode.el (makefile-fill-paragraph):
+ * progmodes/make-mode.el (makefile-fill-paragraph):
Don't insist on spaces when looking for comments. # is enough.
-
+
* files.el (hack-local-variables): Copy the variables list
to another buffer, strip prefixes and suffixes there, then read.
(enable-local-eval): Doc fix.
(defun run-mode-hooks (&rest hooks)
"Run mode hooks `delayed-mode-hooks' and HOOKS, or delay HOOKS.
Execution is delayed if `delay-mode-hooks' is non-nil.
+If `delay-mode-hooks' is nil, run `after-change-major-mode-hook'
+after running the mode hooks.
Major mode functions should use this."
(if delay-mode-hooks
;; Delaying case.
;; Normal case, just run the hook as before plus any delayed hooks.
(setq hooks (nconc (nreverse delayed-mode-hooks) hooks))
(setq delayed-mode-hooks nil)
- (run-hooks 'after-change-major-mode-hook)
- (apply 'run-hooks hooks)))
+ (apply 'run-hooks hooks)
+ (run-hooks 'after-change-major-mode-hook)))
(defmacro delay-mode-hooks (&rest body)
"Execute BODY, but delay any `run-mode-hooks'.