Dear devs,
it's me again. (Oh no! :lol:)
I've studied the latest changes and improvements concerning the debugger plugin. Great! In a recent post (
http://forums.codeblocks.org/index.php/topic,1317.0.html) I have proposed a patch that allows a user to load a GDB script including commands that are being sent to the debugger line-by-line. With the recent changes I had another (for my purposes even better) idea that I've implemented:
I have extended the menu of the debugger tree with another option "Add watch script". This allows a user to load a file that contains watches on variables line-by-line. When is it useful? Imagine you have a program and use (e.g.) std::vector and want to watch specific or all element(s) of this vector. You would have to add each of them using "Add watch" which takes time. Furthermore the watches are lost after the restart of Code::Blocks. With my patch you can load the file and all watches listed there will be added automatically.
I would like to hear you comments on that.
Morten.
ToDo:
- Currently each watch is imported as WatchType "Unspecified" this should be changed so that the file contain another column with the type.
- Allow the user to save the list of (current) active watches to a file in the "Watch script" (XML?) format for easy re-loading
- With the current implementation sometimes the debugger tree gets weird. Maybe I am adding the watches too fast... ;-)
- (...)
[attachment deleted by admin]