Bug 3822 - Debugger ignores breakpoints when executing a statement from the immediate window
Summary: Debugger ignores breakpoints when executing a statement from the immediate wi...
Status: RESOLVED NOT_ON_ROADMAP
Alias: None
Product: Xamarin Studio
Classification: Desktop
Component: Debugger ()
Version: unspecified
Hardware: All All
: Low enhancement
Target Milestone: ---
Assignee: Jeffrey Stedfast
URL:
Depends on:
Blocks:
 
Reported: 2012-03-09 09:47 UTC by Alan McGovern
Modified: 2015-02-24 14:34 UTC (History)
4 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED NOT_ON_ROADMAP

Description Alan McGovern 2012-03-09 09:47:43 UTC
For code like:

if (workingTreeIterator.IsModified(dirCacheIterator.GetDirCacheEntry(), true))
{
  DoStuff ()
}

it can be really handy to put a breakpoint on DoStuff (). When the breakpoint is hit you then put a breakpoint in 'IsModified' and execute the contents of the 'if' statement in the immediate window. This allows you to easily break execution after something fails/succeeds which shouldn't and then step through the statement by re-executing it.

However when the statement is exceuted from the immediate window, monodevelop ignores the breakpoints.
Comment 1 Jeffrey Stedfast 2012-03-09 13:47:41 UTC
I think this must be runtime?
Comment 2 Zoltan Varga 2013-09-16 15:26:39 UTC
This happens because md requests it by passing InvokeOptions.DisableBreakpoints to InvokeMethod ().
Comment 3 Jeffrey Stedfast 2014-01-14 12:48:14 UTC
I'm tempted to say that this is by design... but perhaps there can be a setting for whether or not the runtime should break when evaluating a statement in the Immediate Window (you wouldn't want this behavior in the Watch window, for example)