'main': Let the type determination ignore global aliases when it ignores regular ones.

This commit is contained in:
Daniel Shahaf 2020-03-19 05:28:17 +00:00
parent e2dddb91c6
commit 08839bbd87
2 changed files with 2 additions and 2 deletions

View File

@ -180,7 +180,7 @@ _zsh_highlight_main__type() {
if (( $+aliases[(e)$1] )); then
may_cache=0
fi
if (( ${+galiases[(e)$1]} )); then
if (( ${+galiases[(e)$1]} )) && (( aliases_allowed )); then
REPLY='global alias'
elif (( $+aliases[(e)$1] )) && (( aliases_allowed )); then
REPLY=alias

View File

@ -34,5 +34,5 @@ local s=x
BUFFER=$'$s'
expected_region_highlight=(
'1 2 unknown-token "fixed in the next commit"' # $s
'1 2 unknown-token' # $s
)