Breakpoints hit when in release mode (vs2008)

  • Thread starter Thread starter Leon
  • Start date Start date
L

Leon

hi there,

i am just having a strange problem with my project. i've set a few
breakpoints to debug my program while in debug mode. usally when i switch
to release mode and start the application, those breakpoints are just
being ignored.

but now, the program stops at the breakpoints even when set to release
mode. is there any setting that i might have changed for this behaviour??

i tried restarting visual studio several times and even rebooting the pc.

any ideas??

tx.
 
i am just having a strange problem with my project. i've set a few
breakpoints to debug my program while in debug mode. usally when i switch
to release mode and start the application, those breakpoints are just
being ignored.

but now, the program stops at the breakpoints even when set to release
mode. is there any setting that i might have changed for this behaviour??

i tried restarting visual studio several times and even rebooting the pc.

any ideas??

So if you don't want to debug at all how about just hitting Ctrl+F5 (or
Debug | Start Without Debugging) instead of plain old F5 or clicking the
green triangle?
 
hi there,

i am just having a strange problem with my project. i've set a few
breakpoints to debug my program while in debug mode. usally when i
switch to release mode and start the application, those breakpoints are
just being ignored.

but now, the program stops at the breakpoints even when set to release
mode. is there any setting that i might have changed for this behaviour??

i tried restarting visual studio several times and even rebooting the pc.

any ideas??

Jeff's suggestion seems like the most appropriate one. If you don't want
to hit breakpoints, don't run with the debugger attached.

But as far as the specific question goes, not stopping at breakpoints when
debugging the release build isn't a feature. At worst, that'd be a bug.
At best, it may be a side-effect of a practical problem: the release build
may not have a one-to-one correspondence between your C# program
statements and the generated code. So it's possible to set a breakpoint
on a program statement that doesn't actually generate any code tied to
that statement in the release build, so there's no place for the debugger
to break.

Pete
 
well because i was always good with just hitting F5 :) I thought when you
select release and then hit F5 it would be the same like hitting ctrl F5.
but i will try this.

thx.
 
Back
Top