How to start to debug when a condition happend

Vladimir Prus ghost at cs.msu.su
Mon Nov 23 19:13:55 GMT 2009


On Monday 23 November 2009 21:09:56 Leonel Florín Selles wrote:

> for example inside the code when a condition is met, like
> 
> for (int i=0; i<10; i++)
>     if (i ==7) ---> "then start to debug"

and what do you mean by "then start to debug"? If your program was run in debug
mode in the first place, you can set a breakpoint at that line, and use "i==7"
as condition of breakpoint. If the program was not run in debug mode initially,
then I don't think you can do this. If a program was run in debug mode, there
are some ways to make it stop in debugger, without setting a breakpoint, but
it's not clear you should try that.

- Volodya




More information about the KDevelop mailing list