Subject: bug#21934: 24.5; find-tag: reading TAGS file incorrectly

From: Dmitry Gutov <[email-masked]>
Date: Sun, 22 Nov 2015 18:54:40 +0200

On 11/22/2015 06:12 PM, Eli Zaretskii wrote:
> Completion is not an integral part of find-tag.

It's not an integral part of xref-find-definitions either.

> As I said, completion in M-. in Emacs 25 works worse than in find-tag
> in this case: it doesn't even succeed to complete "Rec TAB" into
> "Rectangle".  I don't know why.

I didn't see any difference between them. Anyway, it should be fixed now.

>> Is it really any different? M-x find-tag RET TAB doesn't show anything
>> beginning with "Rectangle" either. I only get "getPos" as a completion
>> either way.
>
> It's different if you type "Rec TAB".

If I revert 51fd4a01395885077909c60b17ae3d7d42b8bb0a and reopen the TAGS 
file, the only completion I get is "getPos", either way.

It *is* different if you type "Rec RET", however, because in the end 
"Rec" gets a match via `tag-any-match-p', which 
etags--xref-find-definitions doesn't use.

But the user can add it to etags-xref-find-definitions-tag-order, if 
they want.

> My main point is that it's easy to solve the completion case, but that
> hardly help in using TAGS with Lua and the new xref commands.
> Something else is missing.

I believe I've addressed that.

And if I understand Andreas right, etags should output two tags for each 
such definition. Just like we do for C++.