X-Git-Url: https://code.delx.au/gnu-emacs/blobdiff_plain/c07bb40b73856e3c40daf1dc6007ea13e3870912..aaf34461ff5804e5cebe163b31e535da72e81d87:/lisp/help-mode.el diff --git a/lisp/help-mode.el b/lisp/help-mode.el index 075b893ad6..1435eb019e 100644 --- a/lisp/help-mode.el +++ b/lisp/help-mode.el @@ -10,7 +10,7 @@ ;; GNU Emacs is free software; you can redistribute it and/or modify ;; it under the terms of the GNU General Public License as published by -;; the Free Software Foundation; either version 2, or (at your option) +;; the Free Software Foundation; either version 3, or (at your option) ;; any later version. ;; GNU Emacs is distributed in the hope that it will be useful, @@ -461,9 +461,11 @@ that." ;; An obvious case of a key substitution: (save-excursion (while (re-search-forward - ;; Assume command name is only word characters - ;; and dashes to get things like `use M-x foo.'. - "\\bar'. + ;; Command required to end with word constituent + ;; to avoid `.' at end of a sentence. + "\\= (current-column) col) - (looking-at "\\(\\sw\\|-\\)+$")) + (looking-at "\\(\\sw\\|\\s_\\)+$")) (let ((sym (intern-soft (match-string 0)))) (if (fboundp sym) (help-xref-button 0 'help-function sym))))