[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/lisp/emacs-lisp/find-func.el,v
From: |
Martin Rudalics |
Subject: |
[Emacs-diffs] Changes to emacs/lisp/emacs-lisp/find-func.el,v |
Date: |
Fri, 25 Jan 2008 17:46:27 +0000 |
CVSROOT: /sources/emacs
Module name: emacs
Changes by: Martin Rudalics <m061211> 08/01/25 17:46:27
Index: find-func.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/emacs-lisp/find-func.el,v
retrieving revision 1.86
retrieving revision 1.87
diff -u -b -r1.86 -r1.87
--- find-func.el 8 Jan 2008 20:45:33 -0000 1.86
+++ find-func.el 25 Jan 2008 17:46:26 -0000 1.87
@@ -200,11 +200,17 @@
(let* ((path (cons (or find-function-source-path load-path)
(find-library-suffixes)))
(def (if (eq (function-called-at-point) 'require)
+ ;; `function-called-at-point' may return 'require
+ ;; with `point' anywhere on this line. So wrap the
+ ;; `save-excursion' below in a `condition-case' to
+ ;; avoid reporting a scan-error here.
+ (condition-case nil
(save-excursion
(backward-up-list)
(forward-char)
- (backward-sexp -2)
+ (forward-sexp 2)
(thing-at-point 'symbol))
+ (error nil))
(thing-at-point 'symbol))))
(when def
(setq def (and (locate-file-completion def path 'test) def)))