From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 907 invoked from network); 17 Dec 1998 09:27:28 -0000 Received: from math.gatech.edu (list@130.207.146.50) by ns1.primenet.com.au with SMTP; 17 Dec 1998 09:27:28 -0000 Received: (from list@localhost) by math.gatech.edu (8.9.1/8.9.1) id EAA29195; Thu, 17 Dec 1998 04:18:44 -0500 (EST) Resent-Date: Thu, 17 Dec 1998 04:18:44 -0500 (EST) Date: Thu, 17 Dec 1998 10:16:58 +0100 (MET) Message-Id: <199812170916.KAA06674@beta.informatik.hu-berlin.de> From: Sven Wischnowsky To: zsh-workers@math.gatech.edu In-reply-to: Phil Pennock's message of Tue, 15 Dec 1998 15:04:50 +0000 Subject: Re: Bug in completing named dirs (pws-3)? Resent-Message-ID: <"2k67E3.0.387.qnCUs"@math> Resent-From: zsh-workers@math.gatech.edu X-Mailing-List: archive/latest/4828 X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu Phil Pennock wrote: > > Using 3.1.5-pws-3, there seems to be something curious with named dirs > completion. Tab completion removes the tilde. And the same for completion after `='. Below is the fix (I forgot to put ic in ipre ;-). Bye Sven P.S.: ic is the `ignored character' known from older versions, ipre is the `ignored prefix' added for the or'ing stuff. diff -c os/Zle/zle_tricky.c Src/Zle/zle_tricky.c *** os/Zle/zle_tricky.c Wed Dec 16 11:48:23 1998 --- Src/Zle/zle_tricky.c Thu Dec 17 10:12:05 1998 *************** *** 3801,3815 **** /* Completion after `~', maketildelist adds the usernames * * and named directories. */ ! if (ic == Tilde) maketildelist(); ! else if (ic == Equals) { /* Completion after `=', get the command names from * * the cmdnamtab and aliases from aliastab. */ if (isset(HASHLISTALL)) cmdnamtab->filltable(cmdnamtab); dumphashtable(cmdnamtab, -7); dumphashtable(aliastab, -2); } else { /* Normal file completion... */ if (ispattern & 1) { --- 3801,3823 ---- /* Completion after `~', maketildelist adds the usernames * * and named directories. */ ! if (ic == Tilde) { ! char *oi = ipre; ! ! ipre = (ipre ? dyncat("~", ipre) : "~"); maketildelist(); ! ipre = oi; ! } else if (ic == Equals) { /* Completion after `=', get the command names from * * the cmdnamtab and aliases from aliastab. */ + char *oi = ipre; + + ipre = (ipre ? dyncat("=", ipre) : "="); if (isset(HASHLISTALL)) cmdnamtab->filltable(cmdnamtab); dumphashtable(cmdnamtab, -7); dumphashtable(aliastab, -2); + ipre = oi; } else { /* Normal file completion... */ if (ispattern & 1) { -- Sven Wischnowsky wischnow@informatik.hu-berlin.de