Browse Source

fix stepping in inner types

pull/191/merge
Eusebiu Marcu 15 years ago
parent
commit
6f290435b8
  1. 9
      Debugger/ILSpy.Debugger/Services/Debugger/WindowsDebugger.cs

9
Debugger/ILSpy.Debugger/Services/Debugger/WindowsDebugger.cs

@ -306,13 +306,15 @@ namespace ILSpy.Debugger.Services @@ -306,13 +306,15 @@ namespace ILSpy.Debugger.Services
StackFrame frame;
var map = GetCurrentCodeMapping(out frame, out isMatch);
if (map == null) {
return debuggedProcess.SelectedThread.MostRecentStackFrame;
frame = debuggedProcess.SelectedThread.MostRecentStackFrame;
frame.ILRanges = new [] { 0, 1 };
} else {
//var frame = debuggedProcess.SelectedThread.MostRecentStackFrame;
frame.SourceCodeLine = map.SourceCodeLine;
frame.ILRanges = map.ToArray(isMatch);
return frame;
}
return frame;
}
public void StepInto()
@ -817,7 +819,8 @@ namespace ILSpy.Debugger.Services @@ -817,7 +819,8 @@ namespace ILSpy.Debugger.Services
int line;
TypeDefinition type;
if (CodeMappingsStorage.GetSourceCodeFromMetadataTokenAndOffset(frame.MethodInfo.DeclaringType.FullName, token, ilOffset, out type, out line)) {
if (CodeMappingsStorage.GetSourceCodeFromMetadataTokenAndOffset(frame.MethodInfo.DeclaringType.FullName, token, ilOffset, out type, out line)
&& type.DeclaringType == null) {
DebuggerService.RemoveCurrentLineMarker();
DebuggerService.JumpToCurrentLine(type, line, 0, line, 0);
} else {

Loading…
Cancel
Save