Fix: invalid symbol-overlay segment.

The API symbol-overlay-get-list was changed in ad77d6cd1e.
This commit is contained in:
Vincent Zhang 2019-03-07 15:19:54 +07:00
parent df2397bcc5
commit 729e61a386
2 changed files with 8 additions and 5 deletions

View file

@ -30,6 +30,9 @@
(require 'subr-x)
(require 'doom-modeline-core)
;; Externals
(defvar python-shell-interpreter)
;; Show version string for multi-version managers like rvm, rbenv, pyenv, etc.
(defvar-local doom-modeline-env--version nil
"The version to display with major-mode in mode-line.

View file

@ -1020,14 +1020,14 @@ Requires `anzu', also `evil-anzu' if using `evil-mode' for compatibility with
(defsubst doom-modeline--symbol-overlay ()
"Show the number of matches for symbol overlay."
(when (and (bound-and-true-p symbol-overlay-keywords-alist)
(when (and (doom-modeline--active)
(bound-and-true-p symbol-overlay-keywords-alist)
(not (bound-and-true-p symbol-overlay-temp-symbol))
(not (bound-and-true-p iedit-mode)))
(let* ((keyword (symbol-overlay-assoc
(ignore-errors (symbol-overlay-get-symbol))))
(let* ((keyword (symbol-overlay-assoc (symbol-overlay-get-symbol)))
(symbol (car keyword))
(before (symbol-overlay-get-list symbol 'car))
(after (symbol-overlay-get-list symbol 'cdr))
(before (symbol-overlay-get-list -1 symbol))
(after (symbol-overlay-get-list 1 symbol))
(count (length before)))
(if (symbol-overlay-assoc symbol)
(propertize