User Profile
Collapse
-
I am doing it in GDB from outside the python code. I have a python script which does the string match on .cc code. I am calling the function in .py from outside the code using the syntax above. I do all this in GDB. I am not sure if the syntax is right, as it doesn't work. -
How to do partial matches in GDB using python scripts
Hi,
I have .cc code with singleton instances. Now I want to write a python script which runs on .cc code and does string match. The string to be matched is given outside the .py code by calling the function with the string. The script should then print the address of the string for me. I want to how do we do this in GDB. Also how to call functions of the .py script from outside the code. because I do something like below and it gives me error.... -
The problem is it doesn't show me the output the way I want it to be for <list>. Other than that, for vector,map,mult imap and all other STL it prints the output properly. I have the similar representation for vector as well in the .cc code and it works fine.
You can find the output in the attachment.
<<Note : I used pretty printers for STL objects in my .gdbinit file>>...Leave a comment:
-
Printing all STL objects of .cc code in GDB
I have required setup in my .gdbinit file to print all STL objects. I copied code from https://gist.github.com/skyscribe/3978082 to .gdbinit. Then, I run my .cc code, which print all STL objects, other than std::List. It gives some data which is not understandable. Can somebody suggest what I am doing wrong.
I just have 2 lines in my .cc code for list
m_IntList.push_ back(17);
m_IntList.push_ back(66);
No activity results to display
Show More
Leave a comment: