mirror of
https://github.com/zdharma-continuum/history-search-multi-word
synced 2024-11-22 03:13:09 +00:00
Optimization: initialize highlighting's cache only once per run
This commit is contained in:
parent
eefe1f1149
commit
2e4c70638c
1 changed files with 1 additions and 1 deletions
|
@ -42,6 +42,7 @@ _hsmw_main() {
|
|||
zstyle -s ":plugin:history-search-multi-word" synhl __hsmw_synhl || __hsmw_synhl="yes"
|
||||
zstyle -s ":plugin:history-search-multi-word" active __hsmw_active || __hsmw_active="underline"
|
||||
[[ "$__hsmw_synhl" != "1" && "$__hsmw_synhl" != "yes" && "$__hsmw_synhl" != "true" ]] && __hsmw_synhl="no" || __hsmw_synhl="yes"
|
||||
-hsmw-highlight-init
|
||||
fi
|
||||
|
||||
# '0' will get changed into $to_display limit
|
||||
|
@ -128,7 +129,6 @@ _hsmw_main() {
|
|||
|
||||
region_highlight=( )
|
||||
if [[ "$__hsmw_synhl" = "yes" ]]; then
|
||||
-hsmw-highlight-init
|
||||
integer pre_index=0
|
||||
local line
|
||||
for line in "${disp_list[@]}"; do
|
||||
|
|
Loading…
Reference in a new issue