tags:

views:

707

answers:

1

I am a big fan of ctags Hence I am wondering if I have cscope, will I benefit more there two programs. Seems like the latter has the same features as ctags, namely, facilitating the finding of symbols.

What are the features scope offers that can further increase my productivity with VIM?

Thanks

+7  A: 

cscope can certainly improve your productivity.

ctags only allows you to navigate to the declaration of a symbol (one-way lookup).

cscope allows you to:

  • Go to the declaration of a symbol
  • Show a selectable list of all references to a symbol
  • Search for any global definition
  • Functions called by a function
  • Functions calling a function
  • Search for a text string
  • Search for a regular expression pattern
  • Find a file
  • Find all files including a file

Tutorials:

Related SO questions:

Tim Henigan
Tim - as a long-time cscope user (maybe close to 20 years?) I've never had great success using it with C++ projects. Not the "hello world" kind of projects, but industrial-grade C++ with heavy use of polymorphism, templates, etc... I'm wondering if you've used it with "heavyweight" C++ and what your experience has been.Unfortunately I can't give specific examples of problems, just things like not finding symbols/definitions, etc...
Dan
@Dan: My experience with cscope has been limited to use with C ... mostly on projects that involve embedded systems.
Tim Henigan