[Github-comments] [geany/geany] Enable local variable and function parameter tag reporting for C/C++ (PR #3175)

Jiří Techet notifications at github.com
Sun Apr 24 12:28:47 UTC 2022


> pit is a local, I thought you had sorted them first (my understanding from (5) in the OP), so I was pointing out pid_t showed before it, and its definitely not a local, in fact its from the C/C++ global tagfile IIUC.

It was about ordering tags before processing them by the scope autocompletion code, not about ordering results. The biggest problem for larger projects is to pick the right tag, especially for often used names like "data", "id", "name", etc. and the heuristic tries to pick the nearest one to the current position (i.e. local > from current file > from its header > workspace tags > global tags).

(If you have some bigger C++ project around it would be interesting to see how the autocompletion behaves for it when you load all its tags e.g. using ProjectOrganizer.)

Sorting local variables above the rest of the tags would be possible for non-scope autocompletion (with scope autocompletion you get members which are never local). On the other hand this is the "stupid but predicable" autocompletion which always pops up a list of all tags sorted alphabetically and I don't know if having 2 groups each sorted alphabetically in the list wouldn't be confusing.

> Well, its not a C function call, but it is a C++ function call, (have I mentioned not all languages are C?). If the problem is in determining function calls and not in finding the operator function tag then for sure its not part of this PR.

It's not really a function code, it's an object with operator () that is callable thanks to this. And the tooltip code doesn't take this into account.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3175#issuecomment-1107831415
You are receiving this because you are subscribed to this thread.

Message ID: <geany/geany/pull/3175/c1107831415 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.geany.org/pipermail/github-comments/attachments/20220424/46dea356/attachment-0001.htm>


More information about the Github-comments mailing list