about summary refs log tree commit diff
path: root/Functions/Zle/delete-whole-word-match
diff options
context:
space:
mode:
Diffstat (limited to 'Functions/Zle/delete-whole-word-match')
-rw-r--r--Functions/Zle/delete-whole-word-match3
1 files changed, 1 insertions, 2 deletions
diff --git a/Functions/Zle/delete-whole-word-match b/Functions/Zle/delete-whole-word-match
index 65e0cf044..978b95ee7 100644
--- a/Functions/Zle/delete-whole-word-match
+++ b/Functions/Zle/delete-whole-word-match
@@ -49,8 +49,7 @@ if [[ $WIDGET = *kill* ]]; then
   if [[ $LASTWIDGET = *kill* ]]; then
     CUTBUFFER="$CUTBUFFER$word"
   else
-    killring=("$CUTBUFFER" "${(@)killring[1,-2]}")
-    CUTBUFFER=$word
+    zle copy-region-as-kill "$word"
   fi
 fi
 BUFFER="${BUFFER[1,pos1]}${BUFFER[pos2,-1]}"