main: Do not highlight empty region between two adjacent $()

Should fix #624
This commit is contained in:
Matthew Martin
2019-07-08 17:05:42 -05:00
parent ab4b6f5823
commit 83249e1b23
2 changed files with 46 additions and 1 deletions

View File

@@ -1238,7 +1238,7 @@ _zsh_highlight_main_highlighter_highlight_double_quote()
saved_reply=($reply)
reply=()
for 1 2 in $breaks; do
reply+=($1 $2 $style)
(( $1 != $2 )) && reply+=($1 $2 $style)
done
reply+=($saved_reply)
REPLY=$i