Tags Vim

I've written earlier about some problems I was having with the cscope tool for browsing Python code in Vim. Well, it turns out I was using an older version of pycscope for some reason, and the latest version actually does play well with cscope.

Interestingly, cscope wasn't really designed to support languages other than C. I've had an interesting email exchange with one of its maintainers, and I think the following quote from him is conclusive:

The program's name is "cscope" for a reason. It's not called c++scope, not javacscope, not pythoncsope, and certainly not "every programming language under the sun"scope.

Asked about the database format of cscope, he said that it's not documented by design, to make sure all tools go through cscope itself. Fair enough, I guess.

The author of pycscope, however, perused the code of cscope (open source FTW!) to understand the DB format and generate a compatible cscope.out file from his script, which made it possible to use the integration of cscope in Vim after all.

That said, I'm still not sure whether cscope is more convenient for Python than EasyGrep - I need more time to decide.