Catch the imenu-unavailable error in sh-mode completion table
* lisp/progmodes/sh-script.el (sh--cmd-completion-table): Catch the imenu-unavailable error (bug#24238).
This commit is contained in:
parent
993acb5088
commit
55ebb708cf
1 changed files with 4 additions and 1 deletions
|
@ -1741,7 +1741,10 @@ This adds rules for comments and assignments."
|
|||
(defun sh--cmd-completion-table (string pred action)
|
||||
(let ((cmds
|
||||
(append (when (fboundp 'imenu--make-index-alist)
|
||||
(mapcar #'car (imenu--make-index-alist)))
|
||||
(mapcar #'car
|
||||
(condition-case nil
|
||||
(imenu--make-index-alist)
|
||||
(imenu-unavailable nil))))
|
||||
(mapcar (lambda (v) (concat v "="))
|
||||
(sh--vars-before-point))
|
||||
(locate-file-completion-table
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue