zsh-workers
 help / color / mirror / code / Atom feed
* multi-line history storing bug (beta13)
@ 1996-01-15 14:45 Geoff Wing
  1996-01-15 15:21 ` Zefram
  1996-01-15 16:10 ` Peter Stephenson
  0 siblings, 2 replies; 5+ messages in thread
From: Geoff Wing @ 1996-01-15 14:45 UTC (permalink / raw)
  To: zsh-list

Heyla, doing this on my machine loses the last line in the history list.

% for I in test
do echo hi
#test
done
%

It seems to happen in multiline editing when I put in a comment. Anyone else
get this?
-- 
Mason [G.C.W]  mason@werple.mira.net.au    "Hurt...Agony...Pain...LOVE-IT"


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: multi-line history storing bug (beta13)
  1996-01-15 14:45 multi-line history storing bug (beta13) Geoff Wing
@ 1996-01-15 15:21 ` Zefram
  1996-01-15 16:10 ` Peter Stephenson
  1 sibling, 0 replies; 5+ messages in thread
From: Zefram @ 1996-01-15 15:21 UTC (permalink / raw)
  To: Geoff Wing; +Cc: zsh-workers

>% for I in test
>do echo hi
>#test
>done
>%
>
>It seems to happen in multiline editing when I put in a comment. Anyone else
>get this?

I have been seeing similar things happen with no comment involved, but
the comment is the only reproducible pattern I've seen.  This needs
fixing, urgently.

-zefram


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: multi-line history storing bug (beta13)
  1996-01-15 14:45 multi-line history storing bug (beta13) Geoff Wing
  1996-01-15 15:21 ` Zefram
@ 1996-01-15 16:10 ` Peter Stephenson
  1996-01-16  5:07   ` yamagata
  1 sibling, 1 reply; 5+ messages in thread
From: Peter Stephenson @ 1996-01-15 16:10 UTC (permalink / raw)
  To: Zsh hackers list

mason@werple.net.au wrote:
> Heyla, doing this on my machine loses the last line in the history list.
> 
> % for I in test
> do echo hi
> #test
> done
> %
> 
> It seems to happen in multiline editing when I put in a comment. Anyone else
> get this?

It needs to pretend the newline character at the end of the comment is
a word, like other newlines.  (If it doesn't count the newline as a
word, it'll assume that the text ends with the previous word.)  I
didn't do that much detailed checking with multi line buffers, or with
interactivecomments.

*** Src/lex.c.icom	Thu Dec 21 23:44:21 1995
--- Src/lex.c	Mon Jan 15 16:49:00 1996
***************
*** 379,384 ****
--- 379,385 ----
  	    peek = LEXERR;
  	else {
  	    hwend();
+ 	    hwbegin(0);
  	    hwaddc('\n');
  	    peek = NEWLIN;
  	}


-- 
Peter Stephenson <pws@ifh.de>       Tel: +49 33762 77366
WWW:  http://www.ifh.de/~pws/       Fax: +49 33762 77330
Deutches Electronen-Synchrotron --- Institut fuer Hochenergiephysik Zeuthen
DESY-IfH, 15735 Zeuthen, Germany.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: multi-line history storing bug (beta13)
  1996-01-15 16:10 ` Peter Stephenson
@ 1996-01-16  5:07   ` yamagata
  1996-01-16  9:10     ` yamagata
  0 siblings, 1 reply; 5+ messages in thread
From: yamagata @ 1996-01-16  5:07 UTC (permalink / raw)
  To: zsh-workers

Hello,

>> Heyla, doing this on my machine loses the last line in the history list.
>> 
>> % for I in test
>> do echo hi
>> #test
>> done
>> %
>> 
>> It seems to happen in multiline editing when I put in a comment. Anyone else
>> get this?

> It needs to pretend the newline character at the end of the comment is
> a word, like other newlines.  (If it doesn't count the newline as a
> word, it'll assume that the text ends with the previous word.)  I
> didn't do that much detailed checking with multi line buffers, or with
> interactivecomments.

I applied this patch, but still
zsh loss all lines except last, like this.
% sed '
s/:.*//
s/!.*//
' .newsrc

--
yamagata


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: multi-line history storing bug (beta13)
  1996-01-16  5:07   ` yamagata
@ 1996-01-16  9:10     ` yamagata
  0 siblings, 0 replies; 5+ messages in thread
From: yamagata @ 1996-01-16  9:10 UTC (permalink / raw)
  To: yamagata; +Cc: zsh-workers

Sorry, this is only my mistake.

When I make zsh using gcc for pentium optimizing (gcc-2.6.3i) with -O3
option, it lose line.

Zsh made using gcc of FreeBSD doesnt produse this.

>> It needs to pretend the newline character at the end of the comment is
>> a word, like other newlines.  (If it doesn't count the newline as a
>> word, it'll assume that the text ends with the previous word.)  I
>> didn't do that much detailed checking with multi line buffers, or with
>> interactivecomments.

> I applied this patch, but still
> zsh loss all lines except last, like this.
> % sed '
> s/:.*//
> s/!.*//
> ' .newsrc

-
yamagata


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~1996-01-16  9:37 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1996-01-15 14:45 multi-line history storing bug (beta13) Geoff Wing
1996-01-15 15:21 ` Zefram
1996-01-15 16:10 ` Peter Stephenson
1996-01-16  5:07   ` yamagata
1996-01-16  9:10     ` yamagata

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).