[Bug 70815] editing file while in debuger tracks new line numbers but doesn't clear old
Jens Dagerbo
jens.dagerbo at swipnet.se
Wed May 19 18:04:03 UTC 2004
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
http://bugs.kde.org/show_bug.cgi?id=70815
jens.dagerbo swipnet se changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
everconfirmed|0 |1
------- Additional Comments From jens.dagerbo swipnet se 2004-05-19 18:03 -------
I already took a brief look at it (I guess I should have confirmed it.) It's not a trivial thing to solve at all. I'm not even sure it can be solved.
The solution could be expected to be to listen to KTextEditor::MarkInterface::marksChanged() only when the debugger is not running, and KTextEditor::MarkInterfaceExtension::markChanged() when it is.
The problem with this is that markChanged() (which is emitted when a mark is added or removed) won't give us sensible results unless we also track marksChanged() (which is emitted at any mark change, such as the moving of marks as a result of inserting lines)
(The breakpoints widget would need to know that the mark just removed from line 6 is in fact the mark that used to be in line 4, and tell this to the debugger.)
A further problem is that the breakpoints widget is generic and doesn't know either which debugger it frontends for the moment, or if this debugger is currently running.
Now, the thing is, we don't really want to both have breakpoints in running code and edit it at the same time. The debugger can't be expected to step correctly through nonrunning code no matter how smart we attempt to be.
I think the best solution (one that might actually work) would be to simply not allow editing while debugging!
More information about the KDevelop-devel
mailing list