Hi
What the hell could be causing this....
I'm developing my C# 3.5 ASP.NET MVC web app, same as I do all day every day. Not doing anything clever, just standard methods on classes calling other methods...
I build my project, fire up a url in Chrome, and get the response I expect. I attach the debugger to w3wp.exe, set a breakpoint and f5 in Chrome. The debugger stops at the breakpoint as I'd expect....
I hit f11 to step through the code, and it will move to the next line/part line, do it a few times and it will randomly skip to an arbitrary line in the execution path!!!
The line it skips to is a line that would have been executed, it doesn't skip to any old line, it just decides to miss out a whole bunch of lines in between??!!!
I've never seen this before, how the hell do I debug what's going on???
For a while I thought perhaps Chrome is making two requests, and the debugger isnt really skipping, its just swapping between request threads making it look like its jumping about, but thats not it! If i set a breakpoint on every single line i can partially prevent it, but take the following:
1. public string Method()
2. {
3. string s;
4. s = OtherMethod();
5. return s;
6.
7. }
the type of behaviour im seeing (with a breakpoint on every line above) is 1,2,3,4,5,6,7 (i.e. it wont step into OtherMethod();
Other behaviour im seeing is 1,2,3 and then thats it, off back to wherever called Method() or even further away :s
Thanks