Insert a printf inside each function call with vim

233 Views Asked by At

I am debugging C code for embedded systems (backtrace is no option) and I have this repetitive task which consists in putting a printf for each function call to find the real caller of my function in a specific time of code execution.

I am using cscope tool along with CCtree vim plugin to find the callers and it would be really helpful If someone already wrote a vimrc configuration for this or if there is some magical vim plugin that does this.

1

There are 1 best solutions below

0
On

You can use the cscope vim plugin from CSCOPE_MAPS.

For more details on using cscope and vim refer cscope and vim