From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from euclid.skiles.gatech.edu (list@euclid.skiles.gatech.edu [130.207.146.50]) by coral.primenet.com.au (8.7.5/8.7.3) with ESMTP id HAA04760 for ; Wed, 31 Jul 1996 07:07:25 +1000 (EST) Received: (from list@localhost) by euclid.skiles.gatech.edu (8.7.3/8.7.3) id RAA15130; Tue, 30 Jul 1996 17:05:17 -0400 (EDT) Resent-Date: Tue, 30 Jul 1996 17:05:17 -0400 (EDT) Date: Tue, 30 Jul 1996 13:18:31 +0400 (MOW) From: Andrej Borsenkow X-Sender: bor@itsrm1 Reply-To: borsenkow.msk@sni.de To: Zsh workers mailing list Subject: BUG: accept-and-menu-complete prepends glob pattern to next word Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Resent-Message-ID: <"A8oiE3.0.Li3.Cad_n"@euclid> Resent-From: zsh-workers@math.gatech.edu X-Mailing-List: archive/latest/1841 X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu Hi! I use `globcomplete' and `menucomplete'; is bound as usual to `expand-or-complete'; ^J is bound to `accept-and-menu-complete'. It gives following effect: % ls *.c % ls ansi2knr.c^J % ls ansi2knr.c *.cbuiltin.c ^^^ It happens only if completing at the word end; if `completeinword' is set and I complete in the middle, it works O.K.; completeion at the end still gives error. The proposed patch is just crude and empirical hack; probably, it should really be fixed somewhere else - I failed to find where :-( greetings ------------------------------------------------------------------------- Andrej Borsenkow Fax: +7 (095) 252 01 05 SNI ITS Moscow Tel: +7 (095) 252 13 88 NERV: borsenkow.msk E-Mail: borsenkow.msk@sni.de ------------------------------------------------------------------------- ============================================================= --- zsh-3.0-pre4/Src/zle_tricky.c Mon Jul 29 18:00:17 1996 +++ zsh.current/Src/zle_tricky.c Tue Jul 30 12:09:15 1996 @@ -353,7 +353,7 @@ inststrlen(" ", 1, 1); if (qparampre) inststrlen(qparampre, 1, qparprelen); - if (lpre) + if (lpre && !ispattern) inststrlen(lpre, 1, -1); if (lsuf) inststrlen(lsuf, 0, -1);