summaryrefslogtreecommitdiff
path: root/lisp/speedbar.el
diff options
context:
space:
mode:
authorLeo Liu <sdl.web@gmail.com>2014-08-13 11:21:43 +0800
committerLeo Liu <sdl.web@gmail.com>2014-08-13 11:21:43 +0800
commite131e4ffae3b2b31906c9b73ed5e7a621ccfa7c9 (patch)
tree1db5a6a17962fd8fff74603fe04fd429c2aab6d2 /lisp/speedbar.el
parent2b0cb8b177eff6a4aaf14f5c728be3f22aa4b75e (diff)
downloademacs-e131e4ffae3b2b31906c9b73ed5e7a621ccfa7c9.tar.gz
* speedbar.el (speedbar-generic-list-tag-p): Allow special
elements from imenu.
Diffstat (limited to 'lisp/speedbar.el')
-rw-r--r--lisp/speedbar.el9
1 files changed, 6 insertions, 3 deletions
diff --git a/lisp/speedbar.el b/lisp/speedbar.el
index 084767893e4..68970407247 100644
--- a/lisp/speedbar.el
+++ b/lisp/speedbar.el
@@ -2123,9 +2123,10 @@ cell of the form ( 'DIRLIST . 'FILELIST )."
;; in order to make it look nice.
;;
;; A generic list is of the form:
-;; ( ("name" . marker-or-number) <-- one tag at this level
-;; ("name" ("name" . mon) ("name" . mon) ) <-- one group of tags
-;; ("name" mon ("name" . mon) ) <-- group w/ a position and tags
+;; ( ("name" . marker-or-number) <-- one tag at this level
+;; ("name" marker-or-number goto-fun . args) <-- one tag at this level
+;; ("name" ("name" . mon) ("name" . mon) ) <-- one group of tags
+;; ("name" mon ("name" . mon) ) <-- group w/ a position and tags
(defun speedbar-generic-list-group-p (sublst)
"Non-nil if SUBLST is a group.
Groups may optionally contain a position."
@@ -2156,6 +2157,8 @@ Groups may optionally contain a position."
(and (stringp (car-safe sublst))
(or (and (number-or-marker-p (cdr-safe sublst))
(not (cdr-safe (cdr-safe sublst))))
+ (ignore-errors (and (number-or-marker-p (nth 1 sublst))
+ (functionp (nth 2 sublst))))
;; For semantic/bovine items, this is needed
(symbolp (car-safe (cdr-safe sublst))))
))