[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/lisp/bookmark.el
From: |
Karl Fogel |
Subject: |
[Emacs-diffs] Changes to emacs/lisp/bookmark.el |
Date: |
Wed, 12 Jun 2002 17:44:33 -0400 |
Index: emacs/lisp/bookmark.el
diff -c emacs/lisp/bookmark.el:1.61 emacs/lisp/bookmark.el:1.62
*** emacs/lisp/bookmark.el:1.61 Sat Jun 8 06:42:54 2002
--- emacs/lisp/bookmark.el Wed Jun 12 17:44:33 2002
***************
*** 1072,1090 ****
(defun bookmark-file-or-variation-thereof (file)
! "Return FILE (a string) or a reasonable variation that exists, else nil.
! Reasonable variations of the name are made by appending suffixes defined
! in `Info-suffix-list'."
(if (file-exists-p file)
file
! (require 'info) ; ensure Info-suffix-list is bound
! (catch 'found
! (mapc (lambda (elt)
! (let ((suffixed-file (concat file (car elt))))
! (if (file-exists-p suffixed-file)
! (throw 'found suffixed-file))))
! Info-suffix-list)
! nil)))
(defun bookmark-jump-noselect (str)
;; a leetle helper for bookmark-jump :-)
--- 1072,1096 ----
(defun bookmark-file-or-variation-thereof (file)
! "Return FILE (a string) if it exists, or return a reasonable
! variation of FILE if that exists. Reasonable variations are checked
! by appending suffixes defined in `Info-suffix-list'. If cannot find FILE
! nor a reasonable variation thereof, then still return FILE if it can
! be retrieved from a VC backend, else return nil."
(if (file-exists-p file)
file
! (or
! (progn (require 'info) ; ensure Info-suffix-list is bound
! (catch 'found
! (mapc (lambda (elt)
! (let ((suffixed-file (concat file (car elt))))
! (if (file-exists-p suffixed-file)
! (throw 'found suffixed-file))))
! Info-suffix-list)
! nil))
! ;; Last possibility: try VC
! (if (vc-backend file) file))))
!
(defun bookmark-jump-noselect (str)
;; a leetle helper for bookmark-jump :-)