main: Expand paths before removing quoting

Fixes highlighting of `ls \~`. Closes #328.
This commit is contained in:
Matthew Martin 2017-12-12 07:58:35 -06:00
parent 6a6d40208c
commit 2411195c20

View File

@ -923,7 +923,7 @@ _zsh_highlight_main_highlighter_expand_path()
# The $~1 syntax normally performs filename generation, but not when it's on the right-hand side of ${x:=y}.
setopt localoptions nonomatch
unset REPLY
: ${REPLY:=${(Q)~1}}
: ${REPLY:=${(Q)${~1}}}
}
# -------------------------------------------------------------------------------------------------