From 62b586bf9ffc142a5fb2a55707d14d9d02242947 Mon Sep 17 00:00:00 2001 From: Peter Stephenson Date: Wed, 9 Apr 2008 13:06:47 +0000 Subject: 24806: more assoc subscript completion + typos --- ChangeLog | 3 +++ Completion/Zsh/Context/_subscript | 2 +- Doc/Zsh/params.yo | 4 ++-- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 990f8214a..7a1582150 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ 2008-04-09 Peter Stephenson + * 24806: Doc/Zsh/params.yo, Completion/Zsh/Context/_subscript: fix + typos, completing of * and @. + * 24804: Completion/Zsh/Context/_subscript: quoting of associative array keys for subscripts was wrong. diff --git a/Completion/Zsh/Context/_subscript b/Completion/Zsh/Context/_subscript index ba398ffa5..0b23c1cac 100644 --- a/Completion/Zsh/Context/_subscript +++ b/Completion/Zsh/Context/_subscript @@ -70,7 +70,7 @@ elif [[ ${(Pt)${compstate[parameter]}} = assoc* ]]; then local suf MATCH MBEGIN MEND local -a keys keys=(${${(kP)compstate[parameter]}//(#m)[\$\\\[\]\(\)\[\{\}]/\\$MATCH}) - + keys=(${keys//#%(#m)[*@]/(e)$MATCH}) [[ "$RBUFFER" != (|\\)\]* ]] && suf="$osuf" _wanted association-keys expl 'association key' \ diff --git a/Doc/Zsh/params.yo b/Doc/Zsh/params.yo index 9fd21ab5d..dedde051f 100644 --- a/Doc/Zsh/params.yo +++ b/Doc/Zsh/params.yo @@ -344,8 +344,8 @@ The same rule applies to parentheses (`tt(LPAR())' and `tt(RPAR())') and braces (`tt({)' and `tt(})'): they must appear either in balanced pairs or preceded by a backslash, and backslashes that protect parentheses or braces are removed during parsing. This is because parameter expansions -may be surrounded balanced braces, and subscript flags are introduced by -balanced parenthesis. +may be surrounded by balanced braces, and subscript flags are introduced by +balanced parentheses. The second difference is that a double-quote (`tt(")') may appear as part of a subscript expression without being preceded by a backslash, and -- cgit 1.4.1