Fix ido-enable-dot-prefix for empty choice (Bug#26997)

* lisp/ido.el (ido-set-matches-1): Only check first character of
item if it's non-empty.

Copyright-paperwork-exempt: yes
This commit is contained in:
Ryan 2017-05-19 11:07:57 -04:00 committed by Noam Postavsky
parent 547f78c813
commit f422b46eb1

View file

@ -3802,9 +3802,10 @@ frame, rather than all frames, regardless of value of `ido-all-frames'."
(lambda (item)
(let ((name (ido-name item)))
(if (and (or non-prefix-dot
(and (> (length name) 0)
(if (= (aref ido-text 0) ?.)
(= (aref name 0) ?.)
(/= (aref name 0) ?.)))
(/= (aref name 0) ?.))))
(string-match re name))
(cond
((and (eq ido-cur-item 'buffer)