changeset 100002:eda94c1ba359

(eldoc-docstring-first-line): Don't match any but the first "*" in a doc-string.
author Martin Rudalics <rudalics@gmx.at>
date Fri, 28 Nov 2008 10:22:53 +0000
parents 28d216f71b5a
children 756daf14a419
files lisp/emacs-lisp/eldoc.el
diffstat 1 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/emacs-lisp/eldoc.el	Fri Nov 28 05:40:36 2008 +0000
+++ b/lisp/emacs-lisp/eldoc.el	Fri Nov 28 10:22:53 2008 +0000
@@ -367,7 +367,9 @@
   (and (stringp doc)
        (substitute-command-keys
         (save-match-data
-          (let ((start (if (string-match "^\\*" doc) (match-end 0) 0)))
+	  ;; Don't use "^" in the regexp below since it may match
+	  ;; anywhere in the doc-string.
+	  (let ((start (if (string-match "\\`\\*" doc) (match-end 0) 0)))
             (cond ((string-match "\n" doc)
                    (substring doc start (match-beginning 0)))
                   ((zerop start) doc)