Does cscope has search history or search query stack feature?
Asked Answered
S

3

9

I usually dig in the c source code with cscope from method to method more than 4-5 level and I have to step between the methods back and forth.

How can I see the search history in cscope so I don't have to remember the previous method name. or it will be better if it's a stack.

Shashaban answered 10/3, 2010 at 8:32 Comment(1)
if any answer helped you solve your problem, it is customary to "accept" the answer. I guess @Shrinidhi 's is a perfect one.Crossroads
S
27

Yes it does. The help explains this. [ Press ? in the main window.]

Ctrl+b - Step back in search history.

Ctrl+f - Step forward in search history.

Stultify answered 23/7, 2010 at 10:14 Comment(0)
D
2

I primarily use the cbrowser GUI frontend http://sourceforge.net/projects/cbrowser/ to cscope and it has a drop-down box where it remembers the last 15 queries.

Alternatively, if you use the Vim or Emacs/XEmacs editors they have cscope support built-in. I'm not familiar with how the Emacs integration works but in Vim it works pretty much like a regular tag-stack in that you can jump to symbol and then pop back to a previous symbol. Here's some information on the Vim integration http://cscope.sourceforge.net/cscope_vim_tutorial.html. There is some information on the emacs integration on the main cscope page http://cscope.sourceforge.net/.

Diadiabase answered 10/3, 2010 at 21:24 Comment(0)
N
2

At the cscope prompt you can type Ctrl-b to go back to your previous searches. If you move to another field say "symbol search" from "definition search", you can repeat the query for the same symbol by pressing Ctrl-y. HTH.

Nolin answered 31/5, 2010 at 21:50 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.