Debugging your application can be an intriguing task. And analyzing what happens in your application, and what went wrong (or maybe right), often requires the developer to keep an eye on quite a lot of data.
Sometimes that means not only to look at the data as it is on the current step of execution, but also to compare it to what it was on the previous step(s).
Lazarus does now provide a history overview for watched values, locals, and call-stack. Each time your application stops, a record of this data is made and stored.
By default Watches and Locals are recorded for the current stack-frame/thread. But if you browse other frames or threads by selecting them in the stack or threads overview windows, then Lazarus will notice this and keep track of those too.
A new debug window "History" provides access to all recorded values. Currently this is up to 25 history entries. And you can even browse the history after you program terminated.
If you have a history entry selected, you can use the stack-window to change the current stack. If any data was collected for the selected frame, it will be shown. Currently data for extra stack frames is only collected if the frame was selected, while your app was running, and if the watches or locals window where open and active.
There is however a little twist to it. Collecting all the data takes some time. To avoid any slowdown of the debugger, this new feature works on idle time only. It collects data, only if the debugger has no other work. This even means that you can continue the execution of your application, without having to wait the full time it would have taken to get all the data. In this case the snapshot will be incomplete.
If you want to ensure complete snapshots, you can open the watches, locals and stack window, and observe when the information has been fully fetched, as it gets displayed to you.
This feature is available in Lazarus 0.9.31
4 comments:
Hey guys, I've just downloaded Lazarus today, and I'm TOTALLY IMPRESSED !!! I couldn't believe how great it is !! Keep doing good job !
This was a nice post and I think it is pretty easy to see from the other comments as well that this post is well written and informative. Thanks a lot.
source: www.wbupdates.com
... and it's stil very far to GDB 7
Nashev, Lazarus uses GDB 7 for debugging.
Post a Comment