GNU bug report logs -
#61283
29.0.60; pcomplete-completions-at-point loses text properties, breaking pcomplete-from-help annotations
Previous Next
Full log
View this message in rfc822 format
> Date: Wed, 17 May 2023 23:44:17 -0700
> Cc: liuhui1610 <at> gmail.com, arstoffel <at> gmail.com, monnier <at> iro.umontreal.ca,
> 61283 <at> debbugs.gnu.org
> From: Jim Porter <jporterbugs <at> gmail.com>
>
> > And why do we have to fix this in Emacs 29.1? This only affects
> > Eshell, AFAIU, is that true?
>
> It affects M-x shell for me too. Maybe I'm just doing something wrong
> though. I tried this:
>
> emacs -Q -f shell
> ls -<TAB>
>
> From that, I get completions like "--block-size=", which doesn't show
> the annotation. With the annotation, it should be "--block-size=SIZE".
>
> Currently, Pcomplete passes the annotation around by propertizing the
> first character of the candidate string. That ends up not working, since
> the completion code uses the characters in the buffer and concats the
> suffix from Pcomplete. So then the pcomplete-annotation almost always
> gets thrown out.
>
> I think a safe (but incomplete) fix would be to put the annotation on
> the *last* character of the candidate string. Then it usually wouldn't
> get thrown out. It won't work in *every* case, but it would only fail in
> rare edge cases.
Maybe that's better.
The other part of "safe" is whether completion--twq-all is called only
when these annotations are needed, or also in other cases. If the
latter, which use cases the proposed change could affect?
This bug report was last modified 1 year and 277 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.