diff options
| -rw-r--r-- | lisp/imenu.el | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/lisp/imenu.el b/lisp/imenu.el index 84731d50066..42af2a0a1e1 100644 --- a/lisp/imenu.el +++ b/lisp/imenu.el | |||
| @@ -459,12 +459,14 @@ This function is called after the function pointed out by | |||
| 459 | (lambda (item) | 459 | (lambda (item) |
| 460 | (cond | 460 | (cond |
| 461 | ((listp (cdr item)) | 461 | ((listp (cdr item)) |
| 462 | (append (list (incf counter) (car item) 'keymap (car item)) | 462 | (append (list (setq counter (1+ counter)) |
| 463 | (car item) 'keymap (car item)) | ||
| 463 | (imenu--create-keymap-2 (cdr item) (+ counter 10) commands))) | 464 | (imenu--create-keymap-2 (cdr item) (+ counter 10) commands))) |
| 464 | (t | 465 | (t |
| 465 | (let ((end (if commands (list 'lambda 'nil '(interactive) | 466 | (let ((end (if commands `(lambda () (interactive) |
| 466 | (list 'imenu--menubar-select item)) | 467 | (imenu--menubar-select ',item)) |
| 467 | (cons '(nil) t)))) | 468 | (cons '(nil) t)))) |
| 469 | (setq foo end) | ||
| 468 | (cons (car item) | 470 | (cons (car item) |
| 469 | (cons (car item) end)))) | 471 | (cons (car item) end)))) |
| 470 | ))) | 472 | ))) |