I have Delphi 2006. Suddenly it has started behaving erratically. If I run to a breakpoint, it stops, but the next time I start it, the program runs but ignores breakpoints. If I reset the debugger and run the program from start again, the breakpoint works again, but only once.
If I attempt any function like setting a variable watch after it has stopped at a breakpoint, the IDE hangs. Task manager shows no memory or I/O activity on BSD.EXE but the CPU is stuck firmly at 50% (presumably one of my 2 cores in a tight loop).
So I can reproduce the problem by:
- starting Delphi
- loading my project
- full build
- set breakpoint on first line
- run (program breaks on first line)
- select a variable name in the source and drag it onto the watch window
- BOOM!
This behaviour is confined to one particular program being debugged, and happens after a PC/IDE restart.
The app is several 100,000 lines.
Something must be damaged, but where do I start? It points to something my program is doing damaging the IDE, but I can reproduce the problem by breaking on the first line of the DPR file!
Could it be that the compiler is choking on some piece of code I have recently added?
I guess the next step is to start walking backwards, removing the stuff I have added until the problem goes away, but I'm hoping someone can shed some light first.