1
0
Fork 0
mirror of git://git.code.sf.net/p/zsh/code synced 2024-05-12 10:36:17 +02:00

49572: Let _expand preserve array form w/out zstyle glob

This commit is contained in:
Marlon Richert 2021-11-12 21:52:18 +02:00 committed by Oliver Kiddle
parent 9c515a5a2f
commit c7f4634549
3 changed files with 16 additions and 1 deletions

View File

@ -1,5 +1,9 @@
2021-11-12 Oliver Kiddle <opk@zsh.org>
* Marlon: 49572: Completion/Base/Completer/_expand,
Test/Y01completion.ztst: Let _expand preserve array form w/out
zstyle glob
* unposted: Completion/Unix/Command/_ansible: fix case statement
fall-through for ansible-galaxy role completion

View File

@ -105,7 +105,7 @@ subd=("$exp[@]")
# We need to come out of this with consistent quoting, by hook or by crook.
integer done_quote
local orig_exp=$exp
local -a orig_exp=( $exp )
if [[ "$force" = *g* ]] || zstyle -T ":completion:${curcontext}:" glob; then
eval 'exp=( ${~exp//(#b)\\([ \"'"\'"'
])/$match[1]} ); exp=( ${(q)exp} )' 2>/dev/null && (( $#exp )) && done_quote=1

View File

@ -62,6 +62,17 @@
>line: {: dir1 dir2 file1 file2 }{}
>line: {: *}{}
comptesteval $'zstyle \'*\' glob no'
comptesteval $'typeset -g tst=(*)'
comptest $': $tst\C-D'
0:_expand preserves array form
>DESCRIPTION:{expansions}
>NO:{dir1}
>NO:{dir2}
>NO:{file1}
>NO:{file2}
comptesteval $'zstyle -d \'*\' glob'
comptesteval '_users () { compadd user1 user2 }'
comptest $': ~\t\t\t\t\t'
0:tilde