Subject: Re: bug#49776: 28.0.50; Incorrect username completion results reported by `read-file-name-interal`

From: Daniel Mendler <[email-masked]>
Date: Mon, 2 Aug 2021 13:57:43 +0200

On 7/31/21 2:07 PM, Lars Ingebrigtsen wrote:
> ustring here is "~man", and the boundary is 1, so completion--twq-all
> returns "/foo/~man" (because it stripped off 1 character at the start).
> 
> But it should have stripped off "~/foo/~", I think?  Somehow?

Yes. I think the problem here is the wrong completion boundary. The
completion boundary should be placed such that the shadowed path is not
part of the completion. In this case the completion boundary should be
behind the second "~".

Daniel