aboutsummaryrefslogtreecommitdiffstats
path: root/lisp/help-mode.el
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/help-mode.el')
-rw-r--r--lisp/help-mode.el10
1 files changed, 7 insertions, 3 deletions
diff --git a/lisp/help-mode.el b/lisp/help-mode.el
index f15ae633edc..47fa3590177 100644
--- a/lisp/help-mode.el
+++ b/lisp/help-mode.el
@@ -501,9 +501,13 @@ buffer after following a reference. INTERACTIVE-P is non-nil if the
501calling command was invoked interactively. In this case the stack of 501calling command was invoked interactively. In this case the stack of
502items for help buffer \"back\" buttons is cleared. 502items for help buffer \"back\" buttons is cleared.
503 503
504This should be called very early, before the output buffer is cleared, 504This function also re-enables the major mode of the buffer, thus
505because we want to record the \"previous\" position of point so we can 505resetting local variables to the values set by the mode and running the
506restore it properly when going back." 506mode hooks.
507
508So this should be called very early, before the output buffer is
509cleared, also because we want to record the \"previous\" position of
510point so we can restore it properly when going back."
507 (with-current-buffer (help-buffer) 511 (with-current-buffer (help-buffer)
508 ;; Re-enable major mode, killing all unrelated local vars. 512 ;; Re-enable major mode, killing all unrelated local vars.
509 (funcall major-mode) 513 (funcall major-mode)