From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 788 invoked from network); 23 Feb 2000 15:48:45 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 23 Feb 2000 15:48:45 -0000 Received: (qmail 881 invoked by alias); 23 Feb 2000 15:48:35 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 9844 Received: (qmail 874 invoked from network); 23 Feb 2000 15:48:35 -0000 Date: Wed, 23 Feb 2000 16:48:33 +0100 (MET) Message-Id: <200002231548.QAA14791@beta.informatik.hu-berlin.de> From: Sven Wischnowsky To: zsh-workers@sunsite.auc.dk In-reply-to: "Bart Schaefer"'s message of Wed, 23 Feb 2000 15:42:30 +0000 Subject: Re: PATCH: Corrected style test in prediction Bart Schaefer wrote: > } The number of colons is still correct, but the original context name > } was correct, too. The `predict' was stored in the `function' field of > } the context name, indicating that completion was called from predict. > > But in insert-and-predict we have: > > local crs curcontext="${curcontext}" > > [[ -z "$curcontext" ]] && curcontext=::: > curcontext="${curcontext#*:}predict:" > > which makes the context be :completion:::predict::, with `predict' in > the `command' field. Surely the two should be the same? If not, why > not? Ouch. Thanks for the hint. Bye Sven diff -ru ../z.old/Functions/Zle/predict-on Functions/Zle/predict-on --- ../z.old/Functions/Zle/predict-on Wed Feb 23 14:44:05 2000 +++ Functions/Zle/predict-on Wed Feb 23 16:47:41 2000 @@ -56,7 +56,7 @@ local crs curcontext="${curcontext}" [[ -z "$curcontext" ]] && curcontext=::: - curcontext="${curcontext#*:}predict:" + curcontext="predict:${curcontext#*:}" comppostfuncs=( predict-limit-list ) zle complete-word -- Sven Wischnowsky wischnow@informatik.hu-berlin.de