Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

suffix removal again



-----BEGIN PGP SIGNED MESSAGE-----

Even after my previous two patches on the subject, there is still one
remaining bug in suffix removal, that has taken me a while to reproduce.
The symptom is that when menu completing parameter names (after a $),
inserting space or a character such as `:' (that must go immediately
after the parameter name) causes the last character of the parameter
name to be deleted.  What is happening is that zsh is attempting to
delete the space it added following the parameter name, not realising
that it already deleted that for the purpose of menu completion.

This patch must be applied on top of the others.  If anyone notices any
further problems in this area, please let me know.

 -zefram

 *** Src/Zle/zle_main.c	1997/03/19 15:47:09	1.27
 --- Src/Zle/zle_main.c	1997/03/21 23:52:51
 ***************
 *** 513,521 ****
   {
       if(addedsuffix) {
   	backdel(addedsuffix);
 ! 	addedsuffix = complexpect = 0;
   	invalidatelist();
       }
   }
   
   /* initialise command modifiers */
 --- 513,522 ----
   {
       if(addedsuffix) {
   	backdel(addedsuffix);
 ! 	addedsuffix = 0;
   	invalidatelist();
       }
 +     complexpect = 0;
   }
   
   /* initialise command modifiers */
 *** Src/Zle/zle_tricky.c	1997/03/18 23:56:50	1.23
 --- Src/Zle/zle_tricky.c	1997/03/21 23:49:03
 ***************
 *** 3328,3333 ****
 --- 3328,3334 ----
   	    backdel(1);
   	    if (ccs != inscs)
   	      cs = ccs;
 + 	    addedsuffix--;
   	} else
   	    cs--;
       }

-----BEGIN PGP SIGNATURE-----
Version: 2.6.3ia
Charset: ascii

iQCVAwUBMzMh8HD/+HJTpU/hAQEHvwQAoEvzpuXxVKoX2JiudINQ4fmfOJPoZWQB
2SjbxOJf5vvRO1s5S1FFlvggcP8V5yJ1YEVtFDUuCTzyzclVZrLEjcAxv5hJ+9SG
g27GBpmIiXJUf8hHripE+WAjU59kNjsRB+heMmzhtcj4czlhll8ha/nm1UR6v3Br
K0+TdROUr5U=
=9jtV
-----END PGP SIGNATURE-----



Messages sorted by: Reverse Date, Date, Thread, Author