From 1b1712d065fae345cc5658318757348e9fb298d0 Mon Sep 17 00:00:00 2001 From: Peter Stephenson Date: Mon, 7 Jul 2008 09:15:44 +0000 Subject: unposted: fix warn_create_global warnings in copy-earlier-word --- Functions/Zle/copy-earlier-word | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'Functions') diff --git a/Functions/Zle/copy-earlier-word b/Functions/Zle/copy-earlier-word index 63e7edaef..90e862da3 100644 --- a/Functions/Zle/copy-earlier-word +++ b/Functions/Zle/copy-earlier-word @@ -6,7 +6,9 @@ # the current line. emulate -L zsh +setopt typesetsilent +typeset -g __copyword if (( ${NUMERIC:-0} )); then # 1 means last word, 2 second last, etc. (( __copyword = ${NUMERIC:-0} )) @@ -15,7 +17,7 @@ elif [[ -n $__copyword && $WIDGET = $LASTWIDGET ]]; then (( __copyword-- )) elif [[ $LASTWIDGET = *insert-last-word ]]; then __copyword=-2 - __copywidget=$LASTWIDGET + typeset -g __copywidget=$LASTWIDGET else __copyword=-1 zstyle -s :$WIDGET widget __copywidget -- cgit 1.4.1