about summary refs log tree commit diff
path: root/Completion/Core/_sep_parts
diff options
context:
space:
mode:
authorTanaka Akira <akr@users.sourceforge.net>1999-09-22 12:53:49 +0000
committerTanaka Akira <akr@users.sourceforge.net>1999-09-22 12:53:49 +0000
commitc17448c2765f64df856d6f0d620d410c32a734b9 (patch)
tree677461a6d709ff3216ef17a4b34f85d2bda472a7 /Completion/Core/_sep_parts
parenteda0e496969f1eb06eec47501fce74f608d34704 (diff)
downloadzsh-c17448c2765f64df856d6f0d620d410c32a734b9.tar.gz
zsh-c17448c2765f64df856d6f0d620d410c32a734b9.tar.xz
zsh-c17448c2765f64df856d6f0d620d410c32a734b9.zip
zsh-workers/7959
Diffstat (limited to 'Completion/Core/_sep_parts')
-rw-r--r--Completion/Core/_sep_parts6
1 files changed, 5 insertions, 1 deletions
diff --git a/Completion/Core/_sep_parts b/Completion/Core/_sep_parts
index 6f2595120..0a8cae28f 100644
--- a/Completion/Core/_sep_parts
+++ b/Completion/Core/_sep_parts
@@ -18,7 +18,7 @@
 # `-X explanation' options.
 
 local str arr sep test testarr tmparr prefix suffixes matchers autosuffix
-local matchflags opt group expl nm=$compstate[nmatches]
+local matchflags opt group expl nm=$compstate[nmatches] opre osuf
 
 # Get the options.
 
@@ -34,6 +34,8 @@ shift OPTIND-1
 
 # Get the string from the line.
 
+opre="$PREFIX"
+osuf="$SUFFIX"
 str="$PREFIX$SUFFIX"
 SUFFIX=""
 prefix=""
@@ -144,6 +146,8 @@ done
 
 # Add the matches for each of the suffixes.
 
+PREFIX="$pre"
+SUFFIX="$suf"
 for i in "$suffixes[@]"; do
   compadd -U "$group[@]" "$expl[@]" "$matchers[@]" "$autosuffix[@]" \
           -i "$IPREFIX" -I "$ISUFFIX" -p "$prefix" -s "$i" - "$testarr[@]"