avy.el (avy-read): Update avy-current-path before returning

Re #226
This commit is contained in:
Oleh Krehel 2017-12-10 09:44:23 +01:00
parent ddf3c580e7
commit 4af1993290

7
avy.el
View File

@ -468,10 +468,11 @@ multiple DISPLAY-FN invocations."
branch) branch)
(funcall cleanup-fn) (funcall cleanup-fn)
(if (setq branch (assoc char tree)) (if (setq branch (assoc char tree))
(if (eq (car (setq tree (cdr branch))) 'leaf) (progn
(throw 'done (cdr tree))
(setq avy-current-path (setq avy-current-path
(concat avy-current-path (string (avy--key-to-char char))))) (concat avy-current-path (string (avy--key-to-char char))))
(when (eq (car (setq tree (cdr branch))) 'leaf)
(throw 'done (cdr tree))))
(funcall avy-handler-function char)))))) (funcall avy-handler-function char))))))
(defun avy-read-de-bruijn (lst keys) (defun avy-read-de-bruijn (lst keys)