In C#, VS 2010, is there a keyboard shortcut to see from where did the breakpoint was hit when you debug?
For example, if I have a breakpoint in a method called myMethod(), and it was hit, how to see from what line was it called?
In C#, VS 2010, is there a keyboard shortcut to see from where did the breakpoint was hit when you debug?
For example, if I have a breakpoint in a method called myMethod(), and it was hit, how to see from what line was it called?
If you open up the Call Stack window you can see the chain of method calls leading to the current line.
If you've got one of the fancier versions of Visual Studio, you might also take a look at Debugger Canvas.
In simple cases the "Call stack" Window will show this.
If the compiler used tail call optimization or method inlining, it can give an unexpected result. But that shouldn't happen while debugging, because that (by default) disables those optimizations.
yield-iterators and async methods show from where they were resumed, and not where they were originally called.