Developer forums (C::B DEVELOPMENT STRICTLY!) > Development
Splitting debugger in two - specific debugger and common GUI
dmoore:
I need some help with the watches interface. How do I specify that a watch object is expandable without adding children? In python, everything is an object, so it should be possible to expand and see the child members of the object, but I don't want to actually add any children until the user expands the item.
Thx.
EDIT: Would also help if cbWatch included an easy way to recursively iterate through all children of a watch.
oBFusCATed:
--- Quote from: dmoore on February 18, 2011, 03:38:33 am ---I need some help with the watches interface. How do I specify that a watch object is expandable without adding children? In python, everything is an object, so it should be possible to expand and see the child members of the object, but I don't want to actually add any children until the user expands the item.
--- End quote ---
Implement:
--- Code: --- virtual void ExpandWatch(cbWatch *watch) = 0;
virtual void CollapseWatch(cbWatch *watch) = 0;
--- End code ---
These are called when the user expands and collapses specific watch, see how it is done in the gdb/mi.
I think you should add dummy initial children (updating in progress for example)...
--- Quote from: dmoore on February 18, 2011, 03:38:33 am ---EDIT: Would also help if cbWatch included an easy way to recursively iterate through all children of a watch.
--- End quote ---
Patches welcome or please specify the requirement better :)
oBFusCATed:
Next patch: http://smrt.is-a-geek.org/codeblocks/patches/dbg/dbg_refactor0019.3.patch
What it does:
1. Removes "Debug-> Edit Watches...", it was unused;
2. Fixed the OnUpdateUI methods: if there was no active debugger all controls were active, now all controls are disabled;
Pecan:
--- Quote from: oBFusCATed on February 17, 2011, 08:34:56 pm ---Pecan: I should try it on windows... can you try the latest debugger's branch nightly?
Also next patch is here: http://smrt.is-a-geek.org/codeblocks/patches/dbg/dbg_refactor0019.2.patch
What it does:
1. Don't show the breakpoints for the inactive debuggers in the editor's margin. It is refreshed, when the active debugger changes;
2. Extract, some code from CompilerFinished, so it is simpler to implement and less error prone;
3. Document CompilerFinished;
4. Add some logging, when we try to interrupt the debugger;
5. Reorder the source files in the test project file (C::B wants to do it)
--- End quote ---
RE: "Step Into" does not break the program as a means to start the debugging session.
I tried the latest nightly *and* the latest debugger branch with the same results. I.e., using Step Into to start the pgm and break on the first statement does not do so. It acts like "run" instead.
This is a simple console "Hello World" generated by the wizard.
svn build rev 7017 (2011-02-19 13:44:32) gcc 4.5.1 Windows/unicode - 32 bit
I should also mention that the same problem occurs for me in the regular SVN branch. (windows)
If starting the debugging session with "Step Into" was never intended to work, it should be disabled.
Debugger Log:
--- Code: ---Building to ensure sources are up-to-date
Selecting target:
Debug
Adding source dir: C:\temp\test\
Adding source dir: C:\temp\test\
Adding file: .\debug\StepIntoTest.exe
Starting debugger:
done
Registered new type: wxString
Registered new type: STL String
Registered new type: STL Vector
Setting breakpoints
Debugger name and version: GNU gdb (GDB) 7.0
Child process PID: 5116
Program exited normally.
Debugger finished with status 0
--- End code ---
Debuggers Debug Log:
--- Code: ---PATH=.;C:\Usr\mingw431\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;c:\Program Files (x86)\ATI Technologies\ATI.ACE\Core-Static;C:\Program Files\Dell\Dell Wireless WLAN Card;C:\Program Files (x86)\Common Files\Roxio Shared\DLLShared\;C:\usr\bin;C:\Program Files (x86)\CollabNet Subversion;C:\Program Files (x86)\TortoiseSVN\bin;C:\Program Files\TortoiseSVN\bin;C:\Program Files (x86)\Common Files\Adobe\AGL
Command-line: C:\Usr\mingw431\bin\gdb.exe -nx -fullname -quiet -args ./debug/StepIntoTest.exe
Working dir : C:\temp\test\
> set prompt >>>>>>cb_gdb:
Reading symbols from C:\temp\test/./debug/StepIntoTest.exe...done.
(gdb) >>>>>>cb_gdb:
> show version
GNU gdb (GDB) 7.0
Copyright (C) 2009 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "mingw32".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
>>>>>>cb_gdb:
> set confirm off
>>>>>>cb_gdb:
> set width 0
>>>>>>cb_gdb:
> set height 0
>>>>>>cb_gdb:
> set breakpoint pending on
>>>>>>cb_gdb:
> set print asm-demangle on
>>>>>>cb_gdb:
> set unwindonsignal on
>>>>>>cb_gdb:
> set print elements -1
>>>>>>cb_gdb:
> set debugevents on
>>>>>>cb_gdb:
> set new-console on
>>>>>>cb_gdb:
> set disassembly-flavor att
>>>>>>cb_gdb:
> source c:\temp\Nightly\share\codeblocks/scripts/stl-views-1.0.3.gdb
>>>>>>cb_gdb:
> directory C:/temp/test/
>>>>>>cb_gdb:
> run
gdb: windows_init_thread_list
[New Thread 5116.0xca8]
Error: dll starting at 0x77440000 not found.
Error: dll starting at 0x75ff0000 not found.
Error: dll starting at 0x77440000 not found.
Error: dll starting at 0x77560000 not found.
Program exited normally.
>>>>>>cb_gdb:
> set debugevents off
>>>>>>cb_gdb:
> quit
--- End code ---
oBFusCATed:
Next patch (it doesn't apply for me, but should show you what should be done): http://smrt.is-a-geek.org/codeblocks/patches/dbg/dbg_refactor0019.4.patch
What it does: it removes the debuggertree.h/cpp from svn and the projects (unix only).
Next patch (main patch for the post): http://smrt.is-a-geek.org/codeblocks/patches/dbg/dbg_refactor0020.0.patch
What it does: Reimplement the settings GUI/API for the debuggers;
This patch is intended as a preview, to show the direction I'm going. Dmoore and Morten please take a look at it.
I'm applying it on my main build of C::B and will test it in the next few days then I'll write the complete commit message...
p.s. tested only on linux, so you should modify the windows project if you want C::B to compile :)
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version