* man.el (Man-reference-regexp): Allow matching possible

word-wrapped references (bug#6289).
parent ce1438d6
2011-07-03 Lars Magne Ingebrigtsen <larsi@gnus.org>
* man.el (Man-reference-regexp): Allow matching possible
word-wrapped references (bug#6289).
* vc/vc.el (vc-modify-change-comment): Change *VC-log* to *vc-log*
for consistency with the other vc buffers (bug#6197).
(vc-checkin): Ditto.
......
......@@ -276,7 +276,9 @@ This regexp should not start with a `^' character.")
This regular expression should start with a `^' character.")
(defvar Man-reference-regexp
(concat "\\(" Man-name-regexp "\\)[ \t]*(\\(" Man-section-regexp "\\))")
(concat "\\(" Man-name-regexp
"\\(\n[ \t]+" Man-name-regexp "\\)*\\)[ \t]*(\\("
Man-section-regexp "\\))")
"Regular expression describing a reference to another manpage.")
(defvar Man-apropos-regexp
......@@ -597,8 +599,8 @@ and the `Man-section-translations-alist' variables)."
(cond
;; "chmod(2V)" case ?
((string-match (concat "^" Man-reference-regexp "$") ref)
(setq name (match-string 1 ref)
section (match-string 2 ref)))
(setq name (replace-regexp-in-string "[\n\t ]" "" (match-string 1 ref))
section (match-string 3 ref)))
;; "2v chmod" case ?
((string-match (concat "^\\(" Man-section-regexp
"\\) +\\(" Man-name-regexp "\\)$") ref)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment