Details
Description
- Create a new project using "File" -> "New File or Project..." -> "Non-Qt Project" -> "Plain C++ Project".
- At the begin of the main function, add a variable declaration:
#include <iostream> using namespace std; int main() { int i; // <- added line cout << "Hello World!" << endl; return 0; }
- Add a breakpoint at the variable declaration.
- Run this in the debugger.
The debugger won't stop at the breakpoint. - Comment out the line with the variable declaration.
- Run this in the debugger.
Now the breakpoint will be moved to the next line and the debugger will stop there.
When execution passes a breakpoint, the program should stop there or at least nearby.