[Geany-Devel] Python tags

Enrico Tröger enrico.troeger at xxxxx
Thu Jan 9 22:00:17 UTC 2014

On 09/01/14 21:57, Johann SAUNIER wrote:
> Hi all,
> Code navigation in Python language is a pain due to the fact that the
> action "go to symbol definition" on classes or methods don't go to the
> actual definition, but rather heads to the import line at the top of the
> file. I am a bit surprised that no one complains about that...

I'm annoyed by this as well, beaten by it almost every day.

> The guilty is the call to parseImports() in tagmanager/ctags/python.c.

Ah, my code :(.
More seriously, I once debugged this quite a bit and the import parsing
is only the symptom, the real cause is deeper. Unfortunately, I don't
remember all the details because at some point I gave up on this issue
because I didn't find a way to fix it.

Not parsing the imports doesn't solve the problem, it rather just makes
it not happen. I personally like parsed imports and also want to get to
the real symbol definition instead of the import, obviously.

I'll try to recapture what I've found once and/or debug it again and
then ask Colomban for his great wisdom about tag parsing :).

> Would it be possible to only delete the line in Geany's source code ? or is
> anyone more interested in being redirected to the import line rather than
> the actual definition ?

No, surely not.


Get my GPG key from http://www.uvena.de/pub.asc

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: OpenPGP digital signature
URL: <http://lists.geany.org/pipermail/devel/attachments/20140109/8c269bd8/attachment.pgp>

More information about the Devel mailing list