mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2024-11-21 06:55:39 +00:00
* lisp/info-xref.el (info-xref-subfile-p): Avoid false positives. (Bug#68428)
This commit is contained in:
parent
43612103c2
commit
2ef3111b13
@ -79,9 +79,11 @@ If removing the last \"-<NUM>\" from the filename gives a file
|
||||
which exists, then consider FILENAME a subfile. This is an
|
||||
imperfect test, probably ought to open up the purported top file
|
||||
and see what subfiles it says."
|
||||
(and (string-match "\\`\\(\\([^-]*-\\)*[^-]*\\)-[0-9]+\\(.*\\)\\'" filename)
|
||||
(file-exists-p (concat (match-string 1 filename)
|
||||
(match-string 3 filename)))))
|
||||
(let ((nondir (file-name-nondirectory filename)))
|
||||
(and (string-match "\\`\\(\\([^-]*-\\)*[^-]*\\)-[0-9]+\\(.*\\)\\'" nondir)
|
||||
(file-exists-p (concat (file-name-directory filename)
|
||||
(match-string 1 nondir)
|
||||
(match-string 3 nondir))))))
|
||||
|
||||
(defmacro info-xref-with-file (filename &rest body)
|
||||
;; checkdoc-params: (filename body)
|
||||
|
Loading…
Reference in New Issue
Block a user