Author Topic: Can't get breakpoint to work  (Read 5354 times)

Offline andrewp

  • Single posting newcomer
  • *
  • Posts: 2
Can't get breakpoint to work
« on: September 03, 2012, 03:36:42 am »
I just started using codeblocks and I am having trouble getting the debugger to work.
Here is the program  followed by the output when F8 is pressed.  What's wrong?

#include <iostream>

using namespace std;

int main()
{
    cout << "Hello\tI am your computer talking." << endl;  //breakpoint set here!
    return 0;     
}

<<<<this is the output from F8>>>>>

Registered new type: STL Vector
Setting breakpoints
Debugger name and version: GNU gdb (GDB) 7.4
Child process PID: 920
Error in re-setting breakpoint 2: Function "C:/C++ Book/BookI/Chapter01/FirstProject/SayHello/main.cpp:8" not defined.

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13406
    • Travis build status
Re: Can't get breakpoint to work
« Reply #1 on: September 03, 2012, 09:44:39 am »
Have you read this: http://wiki.codeblocks.org/index.php?title=Debugging_with_Code::Blocks
See the notes at the end, I think you're affected by one of them.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline andrewp

  • Single posting newcomer
  • *
  • Posts: 2
Re: Can't get breakpoint to work
« Reply #2 on: September 03, 2012, 04:20:39 pm »
I couldn't resolve the problem from that information!

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13406
    • Travis build status
Re: Can't get breakpoint to work
« Reply #3 on: September 03, 2012, 09:28:47 pm »
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]