diff options
author | Sebastian Gniazdowski <sgniazdowski@gmail.com> | 2015-12-15 09:35:29 +0100 |
---|---|---|
committer | Sebastian Gniazdowski <sgniazdowski@gmail.com> | 2015-12-15 11:02:10 +0100 |
commit | d30a501b1c6b8e8164b266318e26ce6d2e4719cf (patch) | |
tree | 08643b1983e8307fd1339decd94c5e63cb50f934 /plugins/zsh-navigation-tools/n-list | |
parent | 357d57c541970f59dd673df38ce166e9454c6da8 (diff) | |
download | zsh-d30a501b1c6b8e8164b266318e26ce6d2e4719cf.tar.gz zsh-d30a501b1c6b8e8164b266318e26ce6d2e4719cf.tar.bz2 zsh-d30a501b1c6b8e8164b266318e26ce6d2e4719cf.zip |
znt: more optimizing workarounds for 5.0.6 <= zsh < 5.2
Diffstat (limited to 'plugins/zsh-navigation-tools/n-list')
-rw-r--r-- | plugins/zsh-navigation-tools/n-list | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/plugins/zsh-navigation-tools/n-list b/plugins/zsh-navigation-tools/n-list index d13e048bf..388712bd0 100644 --- a/plugins/zsh-navigation-tools/n-list +++ b/plugins/zsh-navigation-tools/n-list @@ -243,7 +243,9 @@ while (( 1 )); do # Take all elements, including duplicates and non-selectables typeset +U list - list=( "$@" ) + repeat 1; do + list=( "$@" ) + done # Remove non-selectable elements [ "$#NLIST_NONSELECTABLE_ELEMENTS" -gt 0 ] && for i in "${(nO)NLIST_NONSELECTABLE_ELEMENTS[@]}"; do @@ -309,7 +311,9 @@ while (( 1 )); do # Take all elements, including duplicates and non-selectables typeset +U list - list=( "$@" ) + repeat 1; do + list=( "$@" ) + done # Remove non-selectable elements only when in uniq mode [ "$NLIST_IS_UNIQ_MODE" -eq 1 ] && [ "$#NLIST_NONSELECTABLE_ELEMENTS" -gt 0 ] && |