From: Leo Liu Date: Fri, 7 Jun 2013 13:00:47 +0000 (+0800) Subject: * progmodes/octave.el (octave-function-header-regexp): Fix. X-Git-Tag: emacs-24.3.90~173^2^2~42^2~45^2~387^2~2026^2~42 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=ce8209d4fe5fef08a4d7e835066770e6ead28a43;p=emacs.git * progmodes/octave.el (octave-function-header-regexp): Fix. (octave-help-mode-finish-hook, octave-help-mode-finish): Remove. Just use temp-buffer-show-hook. Fixes: debbugs:14570 --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b6d934e95c4..4ff6a28ae9c 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -2,6 +2,9 @@ * progmodes/octave.el (octave-mode): Set comment-use-global-state to t. (Bug#14303) + (octave-function-header-regexp): Fix. (Bug#14570) + (octave-help-mode-finish-hook, octave-help-mode-finish): + Remove. Just use temp-buffer-show-hook. * newcomment.el (comment-search-backward): Revert last change. (Bug#14434) diff --git a/lisp/progmodes/octave.el b/lisp/progmodes/octave.el index 14d04b0d03c..5281af60b5d 100644 --- a/lisp/progmodes/octave.el +++ b/lisp/progmodes/octave.el @@ -89,7 +89,7 @@ Used in `octave-mode' and `inferior-octave-mode' buffers.") (defvar octave-function-header-regexp (concat "^\\s-*\\_<\\(function\\)\\_>" - "\\([^=;\n]*=[ \t]*\\|[ \t]*\\)\\(\\(?:\\w\\|\\s_\\)+\\)\\_>") + "\\([^=;(\n]*=[ \t]*\\|[ \t]*\\)\\(\\(?:\\w\\|\\s_\\)+\\)\\_>") "Regexp to match an Octave function header. The string `function' and its name are given by the first and third parenthetical grouping.") @@ -1607,15 +1607,6 @@ if ismember(exist(\"%s\"), [2 3 5 103]) print_usage(\"%s\") endif\n" (when (or help-xref-stack help-xref-forward-stack) (insert "\n")))) -(defvar octave-help-mode-finish-hook nil - "Octave specific hook for `temp-buffer-show-hook'.") - -(defun octave-help-mode-finish () - (when (eq major-mode 'octave-help-mode) - (run-hooks 'octave-help-mode-finish-hook))) - -(add-hook 'temp-buffer-show-hook 'octave-help-mode-finish) - (defun octave-help (fn) "Display the documentation of FN." (interactive (list (octave-completing-read)))