Browse Source

Rename Function to StackFrame

git-svn-id: svn://svn.sharpdevelop.net/sharpdevelop/trunk@2784 1ccf3a8d-04fe-1044-b7c0-cef0b8235c61
shortcuts
David Srbecký 18 years ago
parent
commit
fc672f7a57
  1. 2
      src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Debugger.AddIn.csproj
  2. 6
      src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Pads/CallStackPad.cs
  3. 4
      src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Pads/LocalVarPad.cs
  4. 6
      src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Pads/RunningThreadsPad.cs
  5. 12
      src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Service/WindowsDebugger.cs
  6. 18
      src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Variables/StackFrameItem.cs
  7. 2
      src/AddIns/Misc/Debugger/Debugger.Core/Project/Debugger.Core.csproj
  8. 6
      src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Debugger/Internal/ManagedCallback.cs
  9. 14
      src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Debugger/Process-StateControl.cs
  10. 10
      src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Threads/Exception.cs
  11. 14
      src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Threads/Process.cs
  12. 56
      src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Threads/StackFrame.cs
  13. 20
      src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Threads/Stepper.cs
  14. 85
      src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Threads/Thread.cs
  15. 2
      src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Variables/Evals/Eval.cs
  16. 6
      src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Variables/Expressions/EvaluateAstVisitor.cs
  17. 8
      src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Variables/Expressions/Expression.Create.cs
  18. 2
      src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Variables/Expressions/Expression.Evaluate.cs
  19. 6
      src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Variables/Values/Value.Object.cs
  20. 74
      src/AddIns/Misc/Debugger/Debugger.Tests/Project/Src/DebuggerTests.cs
  21. 24
      src/AddIns/Misc/Debugger/Debugger.Tests/Project/Src/TestPrograms/Callstack.xml
  22. 36
      src/AddIns/Misc/Debugger/Debugger.Tests/Project/Src/TestPrograms/FunctionArgumentVariables.xml
  23. 38
      src/AddIns/Misc/Debugger/Debugger.Tests/Project/Src/TestPrograms/FunctionLifetime.xml
  24. 6
      src/AddIns/Misc/Debugger/Debugger.Tests/Project/Src/TestPrograms/FunctionLocalVariables.xml
  25. 48
      src/AddIns/Misc/Debugger/Debugger.Tests/Project/Src/TestPrograms/Generics.xml
  26. 54
      src/AddIns/Misc/Debugger/Debugger.Tests/Project/Src/TestPrograms/Stepping.xml

2
src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Debugger.AddIn.csproj

@ -69,7 +69,7 @@
<Compile Include="Src\Variables\FixedItem.cs" /> <Compile Include="Src\Variables\FixedItem.cs" />
<Compile Include="Src\Variables\ListItem.cs" /> <Compile Include="Src\Variables\ListItem.cs" />
<Compile Include="Src\Variables\ListItemEventArgs.cs" /> <Compile Include="Src\Variables\ListItemEventArgs.cs" />
<Compile Include="Src\Variables\FunctionItem.cs" /> <Compile Include="Src\Variables\StackFrameItem.cs" />
<Compile Include="Src\Variables\TreeViewNode.cs" /> <Compile Include="Src\Variables\TreeViewNode.cs" />
<Compile Include="Src\Variables\ValueItem.cs" /> <Compile Include="Src\Variables\ValueItem.cs" />
</ItemGroup> </ItemGroup>

6
src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Pads/CallStackPad.cs

@ -106,10 +106,10 @@ namespace ICSharpCode.SharpDevelop.Gui.Pads
void CallStackListItemActivate(object sender, EventArgs e) void CallStackListItemActivate(object sender, EventArgs e)
{ {
if (debuggedProcess.IsPaused) { if (debuggedProcess.IsPaused) {
Function f = (Function)(callStackList.SelectedItems[0].Tag); StackFrame f = (StackFrame)(callStackList.SelectedItems[0].Tag);
if (f.HasSymbols) { if (f.HasSymbols) {
if (debuggedProcess.SelectedThread != null) { if (debuggedProcess.SelectedThread != null) {
debuggedProcess.SelectedThread.SelectedFunction = f; debuggedProcess.SelectedThread.SelectedStackFrame = f;
debuggedProcess.OnDebuggeeStateChanged(); // Force refresh of pads debuggedProcess.OnDebuggeeStateChanged(); // Force refresh of pads
} }
} else { } else {
@ -131,7 +131,7 @@ namespace ICSharpCode.SharpDevelop.Gui.Pads
callStackList.BeginUpdate(); callStackList.BeginUpdate();
callStackList.Items.Clear(); callStackList.Items.Clear();
if (debuggedProcess != null && debuggedProcess.SelectedThread != null && debuggedProcess.IsPaused) { if (debuggedProcess != null && debuggedProcess.SelectedThread != null && debuggedProcess.IsPaused) {
foreach (Function f in debuggedProcess.SelectedThread.Callstack) { foreach (StackFrame f in debuggedProcess.SelectedThread.Callstack) {
ListViewItem item; ListViewItem item;
if (f.HasSymbols || showExternalMethods) { if (f.HasSymbols || showExternalMethods) {
// Show the method in the list // Show the method in the list

4
src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Pads/LocalVarPad.cs

@ -176,8 +176,8 @@ namespace ICSharpCode.SharpDevelop.Gui.Pads
public override void RefreshPad() public override void RefreshPad()
{ {
DateTime start = Debugger.Util.HighPrecisionTimer.Now; DateTime start = Debugger.Util.HighPrecisionTimer.Now;
if (debuggedProcess != null && debuggedProcess.SelectedFunction != null) { if (debuggedProcess != null && debuggedProcess.SelectedStackFrame != null) {
TreeViewNode.UpdateNodes(localVarList, localVarList.Root.Children, new FunctionItem(debuggedProcess.SelectedFunction).SubItems); TreeViewNode.UpdateNodes(localVarList, localVarList.Root.Children, new StackFrameItem(debuggedProcess.SelectedStackFrame).SubItems);
} else { } else {
TreeViewNode.UpdateNodes(localVarList, localVarList.Root.Children, new ListItem[0]); TreeViewNode.UpdateNodes(localVarList, localVarList.Root.Children, new ListItem[0]);
} }

6
src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Pads/RunningThreadsPad.cs

@ -159,11 +159,11 @@ namespace ICSharpCode.SharpDevelop.Gui.Pads
item.Text = thread.ID.ToString(); item.Text = thread.ID.ToString();
item.Tag = thread; item.Tag = thread;
item.SubItems.Add(thread.Name); item.SubItems.Add(thread.Name);
Function location = null; StackFrame location = null;
if (thread.Process.IsPaused) { if (thread.Process.IsPaused) {
location = thread.LastFunctionWithLoadedSymbols; location = thread.LastStackFrameWithLoadedSymbols;
if (location == null) { if (location == null) {
location = thread.LastFunction; location = thread.LastStackFrame;
} }
} }
if (location != null) { if (location != null) {

12
src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Service/WindowsDebugger.cs

@ -198,7 +198,7 @@ namespace ICSharpCode.SharpDevelop.Services
MessageService.ShowMessage(errorNotDebugging, "${res:XML.MainMenu.DebugMenu.StepInto}"); MessageService.ShowMessage(errorNotDebugging, "${res:XML.MainMenu.DebugMenu.StepInto}");
return; return;
} }
if (debuggedProcess.SelectedFunction == null || debuggedProcess.IsRunning) { if (debuggedProcess.SelectedStackFrame == null || debuggedProcess.IsRunning) {
MessageService.ShowMessage(errorCannotStepNoActiveFunction, "${res:XML.MainMenu.DebugMenu.StepInto}"); MessageService.ShowMessage(errorCannotStepNoActiveFunction, "${res:XML.MainMenu.DebugMenu.StepInto}");
} else { } else {
debuggedProcess.StepInto(); debuggedProcess.StepInto();
@ -211,7 +211,7 @@ namespace ICSharpCode.SharpDevelop.Services
MessageService.ShowMessage(errorNotDebugging, "${res:XML.MainMenu.DebugMenu.StepOver}"); MessageService.ShowMessage(errorNotDebugging, "${res:XML.MainMenu.DebugMenu.StepOver}");
return; return;
} }
if (debuggedProcess.SelectedFunction == null || debuggedProcess.IsRunning) { if (debuggedProcess.SelectedStackFrame == null || debuggedProcess.IsRunning) {
MessageService.ShowMessage(errorCannotStepNoActiveFunction, "${res:XML.MainMenu.DebugMenu.StepOver}"); MessageService.ShowMessage(errorCannotStepNoActiveFunction, "${res:XML.MainMenu.DebugMenu.StepOver}");
} else { } else {
debuggedProcess.StepOver(); debuggedProcess.StepOver();
@ -224,7 +224,7 @@ namespace ICSharpCode.SharpDevelop.Services
MessageService.ShowMessage(errorNotDebugging, "${res:XML.MainMenu.DebugMenu.StepOut}"); MessageService.ShowMessage(errorNotDebugging, "${res:XML.MainMenu.DebugMenu.StepOut}");
return; return;
} }
if (debuggedProcess.SelectedFunction == null || debuggedProcess.IsRunning) { if (debuggedProcess.SelectedStackFrame == null || debuggedProcess.IsRunning) {
MessageService.ShowMessage(errorCannotStepNoActiveFunction, "${res:XML.MainMenu.DebugMenu.StepOut}"); MessageService.ShowMessage(errorCannotStepNoActiveFunction, "${res:XML.MainMenu.DebugMenu.StepOut}");
} else { } else {
debuggedProcess.StepOut(); debuggedProcess.StepOut();
@ -289,8 +289,8 @@ namespace ICSharpCode.SharpDevelop.Services
public bool CanSetInstructionPointer(string filename, int line, int column) public bool CanSetInstructionPointer(string filename, int line, int column)
{ {
if (debuggedProcess != null && debuggedProcess.IsPaused && debuggedProcess.SelectedFunction != null) { if (debuggedProcess != null && debuggedProcess.IsPaused && debuggedProcess.SelectedStackFrame != null) {
SourcecodeSegment seg = debuggedProcess.SelectedFunction.CanSetIP(filename, line, column); SourcecodeSegment seg = debuggedProcess.SelectedStackFrame.CanSetIP(filename, line, column);
return seg != null; return seg != null;
} else { } else {
return false; return false;
@ -300,7 +300,7 @@ namespace ICSharpCode.SharpDevelop.Services
public bool SetInstructionPointer(string filename, int line, int column) public bool SetInstructionPointer(string filename, int line, int column)
{ {
if (CanSetInstructionPointer(filename, line, column)) { if (CanSetInstructionPointer(filename, line, column)) {
SourcecodeSegment seg = debuggedProcess.SelectedFunction.SetIP(filename, line, column); SourcecodeSegment seg = debuggedProcess.SelectedStackFrame.SetIP(filename, line, column);
return seg != null; return seg != null;
} else { } else {
return false; return false;

18
src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Variables/FunctionItem.cs → src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Variables/StackFrameItem.cs

@ -42,13 +42,13 @@ using System.Collections.Generic;
namespace Debugger namespace Debugger
{ {
public class FunctionItem: ListItem public class StackFrameItem: ListItem
{ {
Function function; StackFrame stackFrame;
public Function Function { public StackFrame StackFrame {
get { get {
return function; return stackFrame;
} }
} }
@ -60,7 +60,7 @@ namespace Debugger
public override string Name { public override string Name {
get { get {
return function.MethodInfo.Name; return stackFrame.MethodInfo.Name;
} }
} }
@ -91,17 +91,17 @@ namespace Debugger
public override IList<ListItem> SubItems { public override IList<ListItem> SubItems {
get { get {
List<ListItem> ret = new List<ListItem>(); List<ListItem> ret = new List<ListItem>();
foreach(Value val in function.LocalVariables) { foreach(Value val in stackFrame.LocalVariables) {
ret.Add(new ValueItem(val)); ret.Add(new ValueItem(val));
} }
return ret.AsReadOnly(); return ret.AsReadOnly();
} }
} }
public FunctionItem(Function function) public StackFrameItem(StackFrame stackFrame)
{ {
this.function = function; this.stackFrame = stackFrame;
this.function.Process.DebuggeeStateChanged += delegate { this.stackFrame.Process.DebuggeeStateChanged += delegate {
this.OnChanged(new ListItemEventArgs(this)); this.OnChanged(new ListItemEventArgs(this));
}; };
} }

2
src/AddIns/Misc/Debugger/Debugger.Core/Project/Debugger.Core.csproj

@ -203,7 +203,7 @@
<Compile Include="Src\Threads\Exception.cs" /> <Compile Include="Src\Threads\Exception.cs" />
<Compile Include="Src\Threads\ExceptionType.cs" /> <Compile Include="Src\Threads\ExceptionType.cs" />
<Compile Include="Src\Threads\FrameID.cs" /> <Compile Include="Src\Threads\FrameID.cs" />
<Compile Include="Src\Threads\Function.cs" /> <Compile Include="Src\Threads\StackFrame.cs" />
<Compile Include="Src\Threads\NDebugger-Processes.cs" /> <Compile Include="Src\Threads\NDebugger-Processes.cs" />
<Compile Include="Src\Threads\Process-Threads.cs" /> <Compile Include="Src\Threads\Process-Threads.cs" />
<Compile Include="Src\Threads\Process.cs" /> <Compile Include="Src\Threads\Process.cs" />

6
src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Debugger/Internal/ManagedCallback.cs

@ -115,14 +115,14 @@ namespace Debugger
stepper.OnStepComplete(); stepper.OnStepComplete();
if (stepper.PauseWhenComplete) { if (stepper.PauseWhenComplete) {
if (process.SelectedThread.LastFunction.HasSymbols) { if (process.SelectedThread.LastStackFrame.HasSymbols) {
ExitCallback_Paused(); ExitCallback_Paused();
} else { } else {
// This can only happen when JMC is disabled (ie NET1.1 or StepOut) // This can only happen when JMC is disabled (ie NET1.1 or StepOut)
if (stepper.Operation == Stepper.StepperOperation.StepOut) { if (stepper.Operation == Stepper.StepperOperation.StepOut) {
// Create new stepper and keep going // Create new stepper and keep going
process.TraceMessage(" - stepping out of code without symbols at " + process.SelectedThread.LastFunction.ToString()); process.TraceMessage(" - stepping out of code without symbols at " + process.SelectedThread.LastStackFrame.ToString());
new Stepper(process.SelectedThread.LastFunction, "Stepper out of code without symbols").StepOut(); new Stepper(process.SelectedThread.LastStackFrame, "Stepper out of code without symbols").StepOut();
ExitCallback_Continue(); ExitCallback_Continue();
} else { } else {
// NET1.1: There is extra step over stepper, just keep going // NET1.1: There is extra step over stepper, just keep going

14
src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Debugger/Process-StateControl.cs

@ -62,12 +62,12 @@ namespace Debugger
} }
} }
public Function SelectedFunction { public StackFrame SelectedStackFrame {
get { get {
if (SelectedThread == null) { if (SelectedThread == null) {
return null; return null;
} else { } else {
return SelectedThread.SelectedFunction; return SelectedThread.SelectedStackFrame;
} }
} }
} }
@ -99,12 +99,12 @@ namespace Debugger
} }
if (this.SelectedThread != null) { if (this.SelectedThread != null) {
// Disable all steppers - do not Deactivate since function tracking still needs them // Disable all steppers - do not Deactivate since stack frame tracking still needs them
foreach(Stepper s in this.SelectedThread.Steppers) { foreach(Stepper s in this.SelectedThread.Steppers) {
s.PauseWhenComplete = false; s.PauseWhenComplete = false;
} }
this.SelectedThread.SelectedFunction = this.SelectedThread.LastFunctionWithLoadedSymbols; this.SelectedThread.SelectedStackFrame = this.SelectedThread.LastStackFrameWithLoadedSymbols;
} }
if (debuggeeStateChanged) { if (debuggeeStateChanged) {
@ -151,17 +151,17 @@ namespace Debugger
public void StepInto() public void StepInto()
{ {
SelectedFunction.StepInto(); SelectedStackFrame.StepInto();
} }
public void StepOver() public void StepOver()
{ {
SelectedFunction.StepOver(); SelectedStackFrame.StepOver();
} }
public void StepOut() public void StepOut()
{ {
SelectedFunction.StepOut(); SelectedStackFrame.StepOut();
} }
} }
} }

10
src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Threads/Exception.cs

@ -39,20 +39,20 @@ namespace Debugger
Value runtimeValue = new Value(process, corValue); Value runtimeValue = new Value(process, corValue);
message = runtimeValue.GetMember("_message").AsString; message = runtimeValue.GetMember("_message").AsString;
if (thread.LastFunctionWithLoadedSymbols != null) { if (thread.LastStackFrameWithLoadedSymbols != null) {
location = thread.LastFunctionWithLoadedSymbols.NextStatement; location = thread.LastStackFrameWithLoadedSymbols.NextStatement;
} }
callstack = ""; callstack = "";
int callstackItems = 0; int callstackItems = 0;
foreach(Function function in thread.Callstack) { foreach(StackFrame stackFrame in thread.Callstack) {
if (callstackItems >= 100) { if (callstackItems >= 100) {
callstack += "...\n"; callstack += "...\n";
break; break;
} }
SourcecodeSegment loc = function.NextStatement; SourcecodeSegment loc = stackFrame.NextStatement;
callstack += function.MethodInfo.Name + "()"; callstack += stackFrame.MethodInfo.Name + "()";
if (loc != null) { if (loc != null) {
callstack += " - " + loc.SourceFullFilename + ":" + loc.StartLine + "," + loc.StartColumn; callstack += " - " + loc.SourceFullFilename + ":" + loc.StartLine + "," + loc.StartColumn;
} }

14
src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Threads/Process.cs

@ -232,32 +232,32 @@ namespace Debugger
public SourcecodeSegment NextStatement { public SourcecodeSegment NextStatement {
get { get {
if (SelectedFunction == null || IsRunning) { if (SelectedStackFrame == null || IsRunning) {
return null; return null;
} else { } else {
return SelectedFunction.NextStatement; return SelectedStackFrame.NextStatement;
} }
} }
} }
public ValueCollection LocalVariables { public ValueCollection LocalVariables {
get { get {
if (SelectedFunction == null || IsRunning) { if (SelectedStackFrame == null || IsRunning) {
return ValueCollection.Empty; return ValueCollection.Empty;
} else { } else {
return SelectedFunction.Variables; return SelectedStackFrame.Variables;
} }
} }
} }
/// <summary> Gets value of given name which is accessible from selected function </summary> /// <summary> Gets value of given name which is accessible from selected stack frame </summary>
/// <returns> Null if not found </returns> /// <returns> Null if not found </returns>
public Value GetValue(string name) public Value GetValue(string name)
{ {
if (SelectedFunction == null || IsRunning) { if (SelectedStackFrame == null || IsRunning) {
return null; return null;
} else { } else {
return SelectedFunction.GetValue(name); return SelectedStackFrame.GetValue(name);
} }
} }
} }

56
src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Threads/Function.cs → src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Threads/StackFrame.cs

@ -16,10 +16,10 @@ using Debugger.Wrappers.MetaData;
namespace Debugger namespace Debugger
{ {
/// <summary> /// <summary>
/// A function (or also a method or frame) which is being executed on /// A stack frame which is being executed on some thread.
/// some thread. Use to obtain arguments or local variables. /// Use to obtain arguments or local variables.
/// </summary> /// </summary>
public class Function: DebuggerObject, IExpirable public class StackFrame: DebuggerObject, IExpirable
{ {
Process process; Process process;
@ -35,7 +35,7 @@ namespace Debugger
Thread thread; Thread thread;
FrameID frameID; FrameID frameID;
/// <summary> The process in which this function is executed </summary> /// <summary> The process in which this stack frame is executed </summary>
[Debugger.Tests.Ignore] [Debugger.Tests.Ignore]
public Process Process { public Process Process {
get { get {
@ -48,7 +48,7 @@ namespace Debugger
get { return methodInfo; } get { return methodInfo; }
} }
/// <summary> A thread in which the function is executed </summary> /// <summary> A thread in which the stack frame is executed </summary>
[Debugger.Tests.Ignore] [Debugger.Tests.Ignore]
public Thread Thread { public Thread Thread {
get { get {
@ -56,7 +56,7 @@ namespace Debugger
} }
} }
/// <summary> True if the function has symbols defined. /// <summary> True if the stack frame has symbols defined.
/// (That is has accesss to the .pdb file) </summary> /// (That is has accesss to the .pdb file) </summary>
public bool HasSymbols { public bool HasSymbols {
get { get {
@ -64,29 +64,29 @@ namespace Debugger
} }
} }
/// <summary> True if function stepped out and is not longer valid. </summary> /// <summary> True if stack frame stepped out and is not longer valid. </summary>
public bool HasExpired { public bool HasExpired {
get { get {
return steppedOut || this.MethodInfo.Module.Unloaded; return steppedOut || this.MethodInfo.Module.Unloaded;
} }
} }
/// <summary> Occurs when function expires and is no longer usable </summary> /// <summary> Occurs when stack frame expires and is no longer usable </summary>
public event EventHandler Expired; public event EventHandler Expired;
/// <summary> Is called when function expires and is no longer usable </summary> /// <summary> Is called when stack frame expires and is no longer usable </summary>
internal protected virtual void OnExpired(EventArgs e) internal protected virtual void OnExpired(EventArgs e)
{ {
if (!steppedOut) { if (!steppedOut) {
steppedOut = true; steppedOut = true;
process.TraceMessage("Function " + this.ToString() + " expired"); process.TraceMessage("StackFrame " + this.ToString() + " expired");
if (Expired != null) { if (Expired != null) {
Expired(this, e); Expired(this, e);
} }
} }
} }
internal Function(Thread thread, FrameID frameID, ICorDebugILFrame corILFrame) internal StackFrame(Thread thread, FrameID frameID, ICorDebugILFrame corILFrame)
{ {
this.process = thread.Process; this.process = thread.Process;
this.thread = thread; this.thread = thread;
@ -102,12 +102,12 @@ namespace Debugger
MethodProps methodProps = process.GetModule(corFunction.Module).MetaData.GetMethodProps(corFunction.Token); MethodProps methodProps = process.GetModule(corFunction.Module).MetaData.GetMethodProps(corFunction.Token);
this.methodInfo = new MethodInfo(debugType, methodProps); this.methodInfo = new MethodInfo(debugType, methodProps);
// Force some callback when function steps out so that we can expire it // Force some callback when stack frame steps out so that we can expire it
stepOutStepper = new Stepper(this, "Function Tracker"); stepOutStepper = new Stepper(this, "StackFrame Tracker");
stepOutStepper.StepOut(); stepOutStepper.StepOut();
stepOutStepper.PauseWhenComplete = false; stepOutStepper.PauseWhenComplete = false;
process.TraceMessage("Function " + this.ToString() + " created"); process.TraceMessage("StackFrame " + this.ToString() + " created");
} }
/// <summary> Returns diagnostic description of the frame </summary> /// <summary> Returns diagnostic description of the frame </summary>
@ -118,7 +118,7 @@ namespace Debugger
internal ICorDebugILFrame CorILFrame { internal ICorDebugILFrame CorILFrame {
get { get {
if (HasExpired) throw new DebuggerException("Function has expired"); if (HasExpired) throw new DebuggerException("StackFrame has expired");
if (corILFramePauseSession != process.PauseSession) { if (corILFramePauseSession != process.PauseSession) {
CorILFrame = thread.GetFrameAt(frameID).As<ICorDebugILFrame>(); CorILFrame = thread.GetFrameAt(frameID).As<ICorDebugILFrame>();
} }
@ -151,10 +151,10 @@ namespace Debugger
Step(false); Step(false);
} }
/// <summary> Step out of the function </summary> /// <summary> Step out of the stack frame </summary>
public void StepOut() public void StepOut()
{ {
new Stepper(this, "Function step out").StepOut(); new Stepper(this, "StackFrame step out").StepOut();
process.Continue(); process.Continue();
} }
@ -172,12 +172,12 @@ namespace Debugger
} }
if (stepIn) { if (stepIn) {
new Stepper(this, "Function step in").StepIn(nextSt.StepRanges); new Stepper(this, "StackFrame step in").StepIn(nextSt.StepRanges);
// Without JMC step in which ends in code without symblols is cotinued. // Without JMC step in which ends in code without symblols is cotinued.
// The next step over ensures that we at least do step over. // The next step over ensures that we at least do step over.
new Stepper(this, "Safety step over").StepOver(nextSt.StepRanges); new Stepper(this, "Safety step over").StepOver(nextSt.StepRanges);
} else { } else {
new Stepper(this, "Function step over").StepOver(nextSt.StepRanges); new Stepper(this, "StackFrame step over").StepOver(nextSt.StepRanges);
} }
process.Continue(); process.Continue();
@ -328,7 +328,7 @@ namespace Debugger
} }
} }
/// <summary> Gets value of given name which is accessible from this function </summary> /// <summary> Gets value of given name which is accessible from this stack frame </summary>
/// <returns> Null if not found </returns> /// <returns> Null if not found </returns>
public Value GetValue(string name) public Value GetValue(string name)
{ {
@ -348,7 +348,7 @@ namespace Debugger
} }
/// <summary> /// <summary>
/// Gets all variables in the lexical scope of the function. /// Gets all variables in the lexical scope of the stack frame.
/// That is, arguments, local variables and varables of the containing class. /// That is, arguments, local variables and varables of the containing class.
/// </summary> /// </summary>
[Debugger.Tests.Ignore] // Accessible though others [Debugger.Tests.Ignore] // Accessible though others
@ -392,7 +392,7 @@ namespace Debugger
ICorDebugValue ThisCorValue { ICorDebugValue ThisCorValue {
get { get {
if (this.HasExpired) throw new CannotGetValueException("Function has expired"); if (this.HasExpired) throw new CannotGetValueException("StackFrame has expired");
try { try {
return CorILFrame.GetArgument(0); return CorILFrame.GetArgument(0);
} catch (COMException e) { } catch (COMException e) {
@ -404,7 +404,7 @@ namespace Debugger
} }
/// <summary> /// <summary>
/// Gets all accessible members of the class that defines this function. /// Gets all accessible members of the class that defines this stack frame.
/// </summary> /// </summary>
public ValueCollection ContaingClassVariables { public ValueCollection ContaingClassVariables {
get { get {
@ -438,10 +438,10 @@ namespace Debugger
ICorDebugValue GetArgumentCorValue(int index) ICorDebugValue GetArgumentCorValue(int index)
{ {
if (this.HasExpired) throw new CannotGetValueException("Function has expired"); if (this.HasExpired) throw new CannotGetValueException("StackFrame has expired");
try { try {
// Non-static functions include 'this' as first argument // Non-static methods include 'this' as first argument
return CorILFrame.GetArgument((uint)(this.MethodInfo.IsStatic? index : (index + 1))); return CorILFrame.GetArgument((uint)(this.MethodInfo.IsStatic? index : (index + 1)));
} catch (COMException e) { } catch (COMException e) {
if ((uint)e.ErrorCode == 0x80131304) throw new CannotGetValueException("Unavailable in optimized code"); if ((uint)e.ErrorCode == 0x80131304) throw new CannotGetValueException("Unavailable in optimized code");
@ -451,7 +451,7 @@ namespace Debugger
ValueCollection argumentsCache; ValueCollection argumentsCache;
/// <summary> Gets all arguments of the function. </summary> /// <summary> Gets all arguments of the stack frame. </summary>
public ValueCollection Arguments { public ValueCollection Arguments {
get { get {
if (argumentsCache == null) { if (argumentsCache == null) {
@ -476,7 +476,7 @@ namespace Debugger
ValueCollection localVariablesCache; ValueCollection localVariablesCache;
/// <summary> Gets all local variables of the function. </summary> /// <summary> Gets all local variables of the stack frame. </summary>
public ValueCollection LocalVariables { public ValueCollection LocalVariables {
get { get {
if (localVariablesCache == null) { if (localVariablesCache == null) {
@ -501,7 +501,7 @@ namespace Debugger
ICorDebugValue GetCorValueOfLocalVariable(ISymUnmanagedVariable symVar) ICorDebugValue GetCorValueOfLocalVariable(ISymUnmanagedVariable symVar)
{ {
if (this.HasExpired) throw new CannotGetValueException("Function has expired"); if (this.HasExpired) throw new CannotGetValueException("StackFrame has expired");
try { try {
return CorILFrame.GetLocalVariable((uint)symVar.AddressField1); return CorILFrame.GetLocalVariable((uint)symVar.AddressField1);

20
src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Threads/Stepper.cs

@ -15,7 +15,7 @@ namespace Debugger
{ {
public enum StepperOperation {Idle, StepIn, StepOver, StepOut}; public enum StepperOperation {Idle, StepIn, StepOver, StepOut};
Function function; StackFrame stackFrame;
string name; string name;
ICorDebugStepper corStepper; ICorDebugStepper corStepper;
StepperOperation operation = StepperOperation.Idle; StepperOperation operation = StepperOperation.Idle;
@ -26,13 +26,13 @@ namespace Debugger
[Debugger.Tests.Ignore] [Debugger.Tests.Ignore]
public Process Process { public Process Process {
get { get {
return function.Process; return stackFrame.Process;
} }
} }
public Function Function { public StackFrame StackFrame {
get { get {
return function; return stackFrame;
} }
} }
@ -66,20 +66,20 @@ namespace Debugger
} }
} }
public Stepper(Function function, string name): this(function) public Stepper(StackFrame stackFrame, string name): this(stackFrame)
{ {
this.name = name; this.name = name;
} }
public Stepper(Function function) public Stepper(StackFrame stackFrame)
{ {
this.function = function; this.stackFrame = stackFrame;
corStepper = function.CorILFrame.CreateStepper(); corStepper = stackFrame.CorILFrame.CreateStepper();
JustMyCode = true; JustMyCode = true;
function.Thread.Steppers.Add(this); stackFrame.Thread.Steppers.Add(this);
} }
protected internal virtual void OnStepComplete() { protected internal virtual void OnStepComplete() {
@ -114,7 +114,7 @@ namespace Debugger
public override string ToString() public override string ToString()
{ {
return string.Format("{0} in {1} pause={2} \"{3}\"", Operation, Function.ToString(), PauseWhenComplete, name); return string.Format("{0} in {1} pause={2} \"{3}\"", Operation, StackFrame.ToString(), PauseWhenComplete, name);
} }
} }
} }

85
src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Threads/Thread.cs

@ -7,7 +7,6 @@
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Diagnostics;
using System.Runtime.InteropServices; using System.Runtime.InteropServices;
using System.Threading; using System.Threading;
@ -34,7 +33,7 @@ namespace Debugger
bool hasExpired = false; bool hasExpired = false;
bool nativeThreadExited = false; bool nativeThreadExited = false;
Function selectedFunction; StackFrame selectedFunction;
public event EventHandler Expired; public event EventHandler Expired;
public event EventHandler<ThreadEventArgs> NativeThreadExited; public event EventHandler<ThreadEventArgs> NativeThreadExited;
@ -103,7 +102,7 @@ namespace Debugger
void Expire() void Expire()
{ {
Debug.Assert(!this.hasExpired); System.Diagnostics.Debug.Assert(!this.hasExpired);
process.TraceMessage("Thread " + this.ID + " expired"); process.TraceMessage("Thread " + this.ID + " expired");
this.hasExpired = true; this.hasExpired = true;
@ -184,10 +183,10 @@ namespace Debugger
public bool InterceptCurrentException() public bool InterceptCurrentException()
{ {
if (!CorThread.Is<ICorDebugThread2>()) return false; // Is the debuggee .NET 2.0? if (!CorThread.Is<ICorDebugThread2>()) return false; // Is the debuggee .NET 2.0?
if (LastFunction == null) return false; // Is frame available? It is not at StackOverflow if (LastStackFrame == null) return false; // Is frame available? It is not at StackOverflow
try { try {
CorThread.CastTo<ICorDebugThread2>().InterceptCurrentException(LastFunction.CorILFrame.CastTo<ICorDebugFrame>()); CorThread.CastTo<ICorDebugThread2>().InterceptCurrentException(LastStackFrame.CorILFrame.CastTo<ICorDebugFrame>());
return true; return true;
} catch (COMException e) { } catch (COMException e) {
// 0x80131C02: Cannot intercept this exception // 0x80131C02: Cannot intercept this exception
@ -236,13 +235,13 @@ namespace Debugger
} }
} }
public IList<Function> Callstack { public IList<StackFrame> Callstack {
get { get {
return new List<Function>(CallstackEnum).AsReadOnly(); return new List<StackFrame>(CallstackEnum).AsReadOnly();
} }
} }
IEnumerable<Function> CallstackEnum { IEnumerable<StackFrame> CallstackEnum {
get { get {
process.AssertPaused(); process.AssertPaused();
@ -250,31 +249,31 @@ namespace Debugger
if (corChain.IsManaged == 0) continue; // Only managed ones if (corChain.IsManaged == 0) continue; // Only managed ones
foreach(ICorDebugFrame corFrame in corChain.EnumerateFrames().Enumerator) { foreach(ICorDebugFrame corFrame in corChain.EnumerateFrames().Enumerator) {
if (corFrame.Is<ICorDebugILFrame>()) { if (corFrame.Is<ICorDebugILFrame>()) {
Function function; StackFrame stackFrame;
try { try {
function = GetFunctionFromCache(new FrameID(corChain.Index, corFrame.Index), corFrame.As<ICorDebugILFrame>()); stackFrame = GetStackFrameFromCache(new FrameID(corChain.Index, corFrame.Index), corFrame.As<ICorDebugILFrame>());
} catch (COMException) { // TODO } catch (COMException) { // TODO
continue; continue;
}; };
yield return function; yield return stackFrame;
} }
} }
} }
} }
} }
Dictionary<FrameID, Function> functionCache = new Dictionary<FrameID, Function>(); Dictionary<FrameID, StackFrame> functionCache = new Dictionary<FrameID, StackFrame>();
Function GetFunctionFromCache(FrameID frameID, ICorDebugILFrame corFrame) StackFrame GetStackFrameFromCache(FrameID frameID, ICorDebugILFrame corFrame)
{ {
Function function; StackFrame stackFrame;
if (functionCache.TryGetValue(frameID, out function) && !function.HasExpired) { if (functionCache.TryGetValue(frameID, out stackFrame) && !stackFrame.HasExpired) {
function.CorILFrame = corFrame; stackFrame.CorILFrame = corFrame;
return function; return stackFrame;
} else { } else {
function = new Function(this, frameID, corFrame); stackFrame = new StackFrame(this, frameID, corFrame);
functionCache[frameID] = function; functionCache[frameID] = stackFrame;
return function; return stackFrame;
} }
} }
@ -326,34 +325,34 @@ namespace Debugger
ICorDebugFrame lastFrame = corFrameEnum.Next(); ICorDebugFrame lastFrame = corFrameEnum.Next();
// Check the token of the current function - function can change if there are multiple handlers for an event // Check the token of the current stack frame - stack frame can change if there are multiple handlers for an event
Function function; StackFrame stackFrame;
if (lastFrame != null && if (lastFrame != null &&
functionCache.TryGetValue(new FrameID((uint)maxChainIndex, (uint)maxFrameIndex), out function) && functionCache.TryGetValue(new FrameID((uint)maxChainIndex, (uint)maxFrameIndex), out stackFrame) &&
function.MethodInfo.MetadataToken != lastFrame.FunctionToken) { stackFrame.MethodInfo.MetadataToken != lastFrame.FunctionToken) {
functionCache.Remove(new FrameID((uint)maxChainIndex, (uint)maxFrameIndex)); functionCache.Remove(new FrameID((uint)maxChainIndex, (uint)maxFrameIndex));
function.OnExpired(EventArgs.Empty); stackFrame.OnExpired(EventArgs.Empty);
} }
// Expire all functions behind the current maximum // Expire all functions behind the current maximum
// Multiple functions can expire at once (test case: Step out of Button1Click in simple winforms application) // Multiple functions can expire at once (test case: Step out of Button1Click in simple winforms application)
List<KeyValuePair<FrameID, Function>> toBeRemoved = new List<KeyValuePair<FrameID, Function>>(); List<KeyValuePair<FrameID, StackFrame>> toBeRemoved = new List<KeyValuePair<FrameID, StackFrame>>();
foreach(KeyValuePair<FrameID, Function> kvp in functionCache) { foreach(KeyValuePair<FrameID, StackFrame> kvp in functionCache) {
if ((kvp.Key.ChainIndex > maxChainIndex) || if ((kvp.Key.ChainIndex > maxChainIndex) ||
(kvp.Key.ChainIndex == maxChainIndex && kvp.Key.FrameIndex > maxFrameIndex)) { (kvp.Key.ChainIndex == maxChainIndex && kvp.Key.FrameIndex > maxFrameIndex)) {
toBeRemoved.Add(kvp); toBeRemoved.Add(kvp);
} }
} }
foreach(KeyValuePair<FrameID, Function> kvp in toBeRemoved){ foreach(KeyValuePair<FrameID, StackFrame> kvp in toBeRemoved){
functionCache.Remove(kvp.Key); functionCache.Remove(kvp.Key);
kvp.Value.OnExpired(EventArgs.Empty); kvp.Value.OnExpired(EventArgs.Empty);
} }
} }
[Debugger.Tests.ToStringOnly] [Debugger.Tests.ToStringOnly]
public Function SelectedFunction { public StackFrame SelectedStackFrame {
get { get {
return selectedFunction; return selectedFunction;
} }
@ -367,11 +366,11 @@ namespace Debugger
} }
[Debugger.Tests.ToStringOnly] [Debugger.Tests.ToStringOnly]
public Function LastFunctionWithLoadedSymbols { public StackFrame LastStackFrameWithLoadedSymbols {
get { get {
foreach (Function function in CallstackEnum) { foreach (StackFrame stackFrame in CallstackEnum) {
if (function.HasSymbols) { if (stackFrame.HasSymbols) {
return function; return stackFrame;
} }
} }
return null; return null;
@ -379,34 +378,34 @@ namespace Debugger
} }
/// <summary> /// <summary>
/// Returns the most recent function on callstack. /// Returns the most recent stack frame on callstack.
/// Returns null if callstack is empty. /// Returns null if callstack is empty.
/// </summary> /// </summary>
[Debugger.Tests.ToStringOnly] [Debugger.Tests.ToStringOnly]
public Function LastFunction { public StackFrame LastStackFrame {
get { get {
foreach(Function function in CallstackEnum) { foreach(StackFrame stackFrame in CallstackEnum) {
return function; return stackFrame;
} }
return null; return null;
} }
} }
/// <summary> /// <summary>
/// Returns the first function that was called on thread /// Returns the first stack frame that was called on thread
/// </summary> /// </summary>
[Debugger.Tests.ToStringOnly] [Debugger.Tests.ToStringOnly]
public Function FirstFunction { public StackFrame FirstStackFrame {
get { get {
Function first = null; StackFrame first = null;
foreach(Function function in Callstack) { foreach(StackFrame stackFrame in Callstack) {
first = function; first = stackFrame;
} }
return first; return first;
} }
} }
public bool IsLastFunctionNative { public bool IsLastStackFrameNative {
get { get {
process.AssertPaused(); process.AssertPaused();
return corThread.ActiveChain.IsManaged == 0; return corThread.ActiveChain.IsManaged == 0;

2
src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Variables/Evals/Eval.cs

@ -175,7 +175,7 @@ namespace Debugger
process.AssertPaused(); process.AssertPaused();
try { try {
if (targetThread.IsLastFunctionNative) { if (targetThread.IsLastStackFrameNative) {
throw new EvalSetupException("Can not evaluate because native frame is on top of stack"); throw new EvalSetupException("Can not evaluate because native frame is on top of stack");
} }
if (!targetThread.IsAtSafePoint) { if (!targetThread.IsAtSafePoint) {

6
src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Variables/Expressions/EvaluateAstVisitor.cs

@ -17,13 +17,13 @@ namespace Debugger
{ {
class EvaluateAstVisitor: NotImplementedAstVisitor class EvaluateAstVisitor: NotImplementedAstVisitor
{ {
Function stackFrame; StackFrame stackFrame;
public Function StackFrame { public StackFrame StackFrame {
get { return stackFrame; } get { return stackFrame; }
} }
public EvaluateAstVisitor(Function stackFrame) public EvaluateAstVisitor(StackFrame stackFrame)
{ {
this.stackFrame = stackFrame; this.stackFrame = stackFrame;
} }

8
src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Variables/Expressions/Expression.Create.cs

@ -45,22 +45,22 @@ namespace Debugger
); );
} }
public static ExpressionCollection StackFrameVariables(Function stackFrame) public static ExpressionCollection StackFrameVariables(StackFrame stackFrame)
{ {
throw new NotImplementedException(); throw new NotImplementedException();
} }
public static Expression StackFrameThis(Function stackFrame) public static Expression StackFrameThis(StackFrame stackFrame)
{ {
throw new NotImplementedException(); throw new NotImplementedException();
} }
public static ExpressionCollection StackFrameParameters(Function stackFrame) public static ExpressionCollection StackFrameParameters(StackFrame stackFrame)
{ {
throw new NotImplementedException(); throw new NotImplementedException();
} }
public static ExpressionCollection StackFrameLocalVariables(Function stackFrame) public static ExpressionCollection StackFrameLocalVariables(StackFrame stackFrame)
{ {
throw new NotImplementedException(); throw new NotImplementedException();
} }

2
src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Variables/Expressions/Expression.Evaluate.cs

@ -22,7 +22,7 @@ namespace Debugger
return Evaluate(null); return Evaluate(null);
} }
Value Evaluate(Function stackFrame) Value Evaluate(StackFrame stackFrame)
{ {
EvaluateAstVisitor astVisitor = new EvaluateAstVisitor(stackFrame); EvaluateAstVisitor astVisitor = new EvaluateAstVisitor(stackFrame);
return (Value)this.AbstractSynatxTree.AcceptVisitor(astVisitor, null); return (Value)this.AbstractSynatxTree.AcceptVisitor(astVisitor, null);

6
src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Variables/Values/Value.Object.cs

@ -64,10 +64,10 @@ namespace Debugger
ICorDebugFrame curFrame = null; ICorDebugFrame curFrame = null;
if (objectInstance.Process.IsPaused && if (objectInstance.Process.IsPaused &&
objectInstance.Process.SelectedThread != null && objectInstance.Process.SelectedThread != null &&
objectInstance.Process.SelectedThread.LastFunction != null && objectInstance.Process.SelectedThread.LastStackFrame != null &&
objectInstance.Process.SelectedThread.LastFunction.CorILFrame != null) { objectInstance.Process.SelectedThread.LastStackFrame.CorILFrame != null) {
curFrame = objectInstance.Process.SelectedThread.LastFunction.CorILFrame.CastTo<ICorDebugFrame>(); curFrame = objectInstance.Process.SelectedThread.LastStackFrame.CorILFrame.CastTo<ICorDebugFrame>();
} }
try { try {

74
src/AddIns/Misc/Debugger/Debugger.Tests/Project/Src/DebuggerTests.cs

@ -96,39 +96,39 @@ namespace Debugger.Tests
{ {
StartTest("Stepping"); StartTest("Stepping");
WaitForPause(); WaitForPause();
ObjectDump("SelectedFunction", process.SelectedFunction); ObjectDump("SelectedStackFrame", process.SelectedStackFrame);
process.StepOver(); // Debugger.Break process.StepOver(); // Debugger.Break
WaitForPause(); WaitForPause();
ObjectDump("SelectedFunction", process.SelectedFunction); ObjectDump("SelectedStackFrame", process.SelectedStackFrame);
process.StepOver(); // Debug.WriteLine 1 process.StepOver(); // Debug.WriteLine 1
WaitForPause(); WaitForPause();
ObjectDump("SelectedFunction", process.SelectedFunction); ObjectDump("SelectedStackFrame", process.SelectedStackFrame);
process.StepInto(); // Method Sub process.StepInto(); // Method Sub
WaitForPause(); WaitForPause();
ObjectDump("SelectedFunction", process.SelectedFunction); ObjectDump("SelectedStackFrame", process.SelectedStackFrame);
process.StepInto(); // '{' process.StepInto(); // '{'
WaitForPause(); WaitForPause();
ObjectDump("SelectedFunction", process.SelectedFunction); ObjectDump("SelectedStackFrame", process.SelectedStackFrame);
process.StepInto(); // Debug.WriteLine 2 process.StepInto(); // Debug.WriteLine 2
WaitForPause(); WaitForPause();
ObjectDump("SelectedFunction", process.SelectedFunction); ObjectDump("SelectedStackFrame", process.SelectedStackFrame);
process.StepOut(); // Method Sub process.StepOut(); // Method Sub
WaitForPause(); WaitForPause();
ObjectDump("SelectedFunction", process.SelectedFunction); ObjectDump("SelectedStackFrame", process.SelectedStackFrame);
process.StepOver(); // Method Sub process.StepOver(); // Method Sub
WaitForPause(); WaitForPause();
ObjectDump("SelectedFunction", process.SelectedFunction); ObjectDump("SelectedStackFrame", process.SelectedStackFrame);
process.StepOver(); // Method Sub2 process.StepOver(); // Method Sub2
WaitForPause(); WaitForPause();
ObjectDump("SelectedFunction", process.SelectedFunction); ObjectDump("SelectedStackFrame", process.SelectedStackFrame);
process.Continue(); process.Continue();
process.WaitForExit(); process.WaitForExit();
@ -164,7 +164,7 @@ namespace Debugger.Tests
for(int i = 0; i < 6; i++) { for(int i = 0; i < 6; i++) {
process.Continue(); process.Continue();
WaitForPause(); WaitForPause();
ObjectDump("SelectedFunction", process.SelectedFunction); ObjectDump("SelectedStackFrame", process.SelectedStackFrame);
} }
process.Continue(); process.Continue();
@ -177,7 +177,7 @@ namespace Debugger.Tests
{ {
StartTest("FunctionLocalVariables"); StartTest("FunctionLocalVariables");
WaitForPause(); WaitForPause();
ObjectDump("SelectedFunction", process.SelectedFunction); ObjectDump("SelectedStackFrame", process.SelectedStackFrame);
process.Continue(); process.Continue();
process.WaitForExit(); process.WaitForExit();
@ -187,27 +187,27 @@ namespace Debugger.Tests
[Test] [Test]
public void FunctionLifetime() public void FunctionLifetime()
{ {
Function function; StackFrame stackFrame;
StartTest("FunctionLifetime"); StartTest("FunctionLifetime");
WaitForPause(); WaitForPause();
function = process.SelectedFunction; stackFrame = process.SelectedStackFrame;
ObjectDump("Function", function); ObjectDump("StackFrame", stackFrame);
process.Continue(); // Go to the SubFunction process.Continue(); // Go to the SubFunction
WaitForPause(); WaitForPause();
ObjectDump("Function", function); ObjectDump("StackFrame", stackFrame);
ObjectDump("SubFunction", process.SelectedFunction); ObjectDump("SubStackFrame", process.SelectedStackFrame);
process.Continue(); // Go back to Function process.Continue(); // Go back to Function
WaitForPause(); WaitForPause();
Assert.AreEqual(function, process.SelectedFunction); Assert.AreEqual(stackFrame, process.SelectedStackFrame);
ObjectDump("Function", function); ObjectDump("StackFrame", stackFrame);
process.Continue(); // Setp out of function process.Continue(); // Setp out of function
WaitForPause(); WaitForPause();
ObjectDump("Main", process.SelectedFunction); ObjectDump("Main", process.SelectedStackFrame);
ObjectDump("Function", function); ObjectDump("StackFrame", stackFrame);
process.Continue(); process.Continue();
process.WaitForExit(); process.WaitForExit();
@ -224,16 +224,16 @@ namespace Debugger.Tests
StartTest("FunctionVariablesLifetime"); // 1 - Enter program StartTest("FunctionVariablesLifetime"); // 1 - Enter program
WaitForPause(); WaitForPause();
argument = process.SelectedFunction.GetArgument(0); argument = process.SelectedStackFrame.GetArgument(0);
local = process.SelectedFunction.LocalVariables["local"]; local = process.SelectedStackFrame.LocalVariables["local"];
@class = process.SelectedFunction.ContaingClassVariables["class"]; @class = process.SelectedStackFrame.ContaingClassVariables["class"];
ObjectDump("argument", argument); ObjectDump("argument", argument);
ObjectDump("local", local); ObjectDump("local", local);
ObjectDump("@class", @class); ObjectDump("@class", @class);
process.Continue(); // 2 - Go to the SubFunction process.Continue(); // 2 - Go to the SubFunction
WaitForPause(); WaitForPause();
localInSubFunction = process.SelectedFunction.LocalVariables["localInSubFunction"]; localInSubFunction = process.SelectedStackFrame.LocalVariables["localInSubFunction"];
ObjectDump("argument", argument); ObjectDump("argument", argument);
ObjectDump("local", local); ObjectDump("local", local);
ObjectDump("@class", @class); ObjectDump("@class", @class);
@ -252,7 +252,7 @@ namespace Debugger.Tests
ObjectDump("local", local); ObjectDump("local", local);
ObjectDump("@class", @class); ObjectDump("@class", @class);
ObjectDump("localInSubFunction", @localInSubFunction); ObjectDump("localInSubFunction", @localInSubFunction);
localInSubFunction = process.SelectedFunction.LocalVariables["localInSubFunction"]; localInSubFunction = process.SelectedStackFrame.LocalVariables["localInSubFunction"];
ObjectDump("localInSubFunction(new)", @localInSubFunction); ObjectDump("localInSubFunction(new)", @localInSubFunction);
process.Continue(); // 5 - Setp out of both functions process.Continue(); // 5 - Setp out of both functions
@ -272,7 +272,7 @@ namespace Debugger.Tests
{ {
StartTest("ArrayValue"); StartTest("ArrayValue");
WaitForPause(); WaitForPause();
Value array = process.SelectedFunction.LocalVariables["array"]; Value array = process.SelectedStackFrame.LocalVariables["array"];
ObjectDump("array", array); ObjectDump("array", array);
ObjectDump("array elements", array.GetArrayElements()); ObjectDump("array elements", array.GetArrayElements());
@ -288,7 +288,7 @@ namespace Debugger.Tests
StartTest("ObjectValue"); StartTest("ObjectValue");
WaitForPause(); WaitForPause();
val = process.SelectedFunction.LocalVariables["val"]; val = process.SelectedStackFrame.LocalVariables["val"];
ObjectDump("val", val); ObjectDump("val", val);
ObjectDump("val members", val.GetMembers(null, Debugger.BindingFlags.All)); ObjectDump("val members", val.GetMembers(null, Debugger.BindingFlags.All));
//ObjectDump("typeof(val)", val.Type); //ObjectDump("typeof(val)", val.Type);
@ -382,9 +382,9 @@ namespace Debugger.Tests
StartTest("SetIP"); StartTest("SetIP");
WaitForPause(); WaitForPause();
Assert.IsNotNull(process.SelectedFunction.CanSetIP("SetIP.cs", 16, 0)); Assert.IsNotNull(process.SelectedStackFrame.CanSetIP("SetIP.cs", 16, 0));
Assert.IsNull(process.SelectedFunction.CanSetIP("SetIP.cs", 100, 0)); Assert.IsNull(process.SelectedStackFrame.CanSetIP("SetIP.cs", 100, 0));
process.SelectedFunction.SetIP("SetIP.cs", 16, 0); process.SelectedStackFrame.SetIP("SetIP.cs", 16, 0);
process.Continue(); process.Continue();
WaitForPause(); WaitForPause();
Assert.AreEqual("1\r\n1\r\n", log); Assert.AreEqual("1\r\n1\r\n", log);
@ -399,8 +399,8 @@ namespace Debugger.Tests
{ {
StartTest("GenericDictionary"); StartTest("GenericDictionary");
WaitForPause(); WaitForPause();
ObjectDump("dict", process.SelectedFunction.LocalVariables["dict"]); ObjectDump("dict", process.SelectedStackFrame.LocalVariables["dict"]);
ObjectDump("dict members", process.SelectedFunction.LocalVariables["dict"].GetMembers(null, BindingFlags.All)); ObjectDump("dict members", process.SelectedStackFrame.LocalVariables["dict"].GetMembers(null, BindingFlags.All));
process.Continue(); process.Continue();
process.WaitForExit(); process.WaitForExit();
@ -433,10 +433,10 @@ namespace Debugger.Tests
StartTest("Expressions"); StartTest("Expressions");
WaitForPause(); WaitForPause();
ObjectDump("Variables", process.SelectedFunction.Variables); ObjectDump("Variables", process.SelectedStackFrame.Variables);
ObjectDump("array", process.SelectedFunction.Variables["array"].GetArrayElements()); ObjectDump("array", process.SelectedStackFrame.Variables["array"].GetArrayElements());
ObjectDump("array2", process.SelectedFunction.Variables["array2"].GetArrayElements()); ObjectDump("array2", process.SelectedStackFrame.Variables["array2"].GetArrayElements());
ObjectDump("this", process.SelectedFunction.ThisValue.GetMembers()); ObjectDump("this", process.SelectedStackFrame.ThisValue.GetMembers());
process.Continue(); process.Continue();
process.WaitForExit(); process.WaitForExit();
@ -450,7 +450,7 @@ namespace Debugger.Tests
for(int i = 0; i < 8; i++) { for(int i = 0; i < 8; i++) {
WaitForPause(); WaitForPause();
ObjectDump("SelectedFunction", process.SelectedFunction); ObjectDump("SelectedStackFrame", process.SelectedStackFrame);
process.Continue(); process.Continue();
} }

24
src/AddIns/Misc/Debugger/Debugger.Tests/Project/Src/TestPrograms/Callstack.xml

@ -9,7 +9,7 @@
<ReadOnlyCollection_x0060_1> <ReadOnlyCollection_x0060_1>
<Count>3</Count> <Count>3</Count>
<Items> <Items>
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>True</IsPrivate> <IsPrivate>True</IsPrivate>
@ -44,8 +44,8 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>True</IsPrivate> <IsPrivate>True</IsPrivate>
@ -80,8 +80,8 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -116,7 +116,7 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</Items> </Items>
</ReadOnlyCollection_x0060_1> </ReadOnlyCollection_x0060_1>
</ObjectDump> </ObjectDump>
@ -125,7 +125,7 @@
<ReadOnlyCollection_x0060_1> <ReadOnlyCollection_x0060_1>
<Count>2</Count> <Count>2</Count>
<Items> <Items>
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>True</IsPrivate> <IsPrivate>True</IsPrivate>
@ -160,8 +160,8 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -196,7 +196,7 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</Items> </Items>
</ReadOnlyCollection_x0060_1> </ReadOnlyCollection_x0060_1>
</ObjectDump> </ObjectDump>
@ -205,7 +205,7 @@
<ReadOnlyCollection_x0060_1> <ReadOnlyCollection_x0060_1>
<Count>1</Count> <Count>1</Count>
<Items> <Items>
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -240,7 +240,7 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</Items> </Items>
</ReadOnlyCollection_x0060_1> </ReadOnlyCollection_x0060_1>
</ObjectDump> </ObjectDump>

36
src/AddIns/Misc/Debugger/Debugger.Tests/Project/Src/TestPrograms/FunctionArgumentVariables.xml

@ -6,8 +6,8 @@
<ModuleLoaded symbols="True">FunctionArgumentVariables.exe</ModuleLoaded> <ModuleLoaded symbols="True">FunctionArgumentVariables.exe</ModuleLoaded>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>True</IsPrivate> <IsPrivate>True</IsPrivate>
@ -88,11 +88,11 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>True</IsPrivate> <IsPrivate>True</IsPrivate>
@ -173,11 +173,11 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>True</IsPrivate> <IsPrivate>True</IsPrivate>
@ -258,11 +258,11 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>True</IsPrivate> <IsPrivate>True</IsPrivate>
@ -359,11 +359,11 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>True</IsPrivate> <IsPrivate>True</IsPrivate>
@ -460,11 +460,11 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>True</IsPrivate> <IsPrivate>True</IsPrivate>
@ -561,7 +561,7 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<ProcessExited /> <ProcessExited />
</Test> </Test>

38
src/AddIns/Misc/Debugger/Debugger.Tests/Project/Src/TestPrograms/FunctionLifetime.xml

@ -5,8 +5,8 @@
<ModuleLoaded symbols="False">mscorlib.dll</ModuleLoaded> <ModuleLoaded symbols="False">mscorlib.dll</ModuleLoaded>
<ModuleLoaded symbols="True">FunctionLifetime.exe</ModuleLoaded> <ModuleLoaded symbols="True">FunctionLifetime.exe</ModuleLoaded>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="Function"> <ObjectDump name="StackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>True</IsPrivate> <IsPrivate>True</IsPrivate>
@ -57,11 +57,11 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="Function"> <ObjectDump name="StackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>True</IsPrivate> <IsPrivate>True</IsPrivate>
@ -112,10 +112,10 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<ObjectDump name="SubFunction"> <ObjectDump name="SubStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>True</IsPrivate> <IsPrivate>True</IsPrivate>
@ -150,11 +150,11 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="Function"> <ObjectDump name="StackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>True</IsPrivate> <IsPrivate>True</IsPrivate>
@ -205,11 +205,11 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="Main"> <ObjectDump name="Main">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -244,10 +244,10 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<ObjectDump name="Function"> <ObjectDump name="StackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>True</IsPrivate> <IsPrivate>True</IsPrivate>
@ -261,7 +261,7 @@
</MethodInfo> </MethodInfo>
<HasSymbols>True</HasSymbols> <HasSymbols>True</HasSymbols>
<HasExpired>True</HasExpired> <HasExpired>True</HasExpired>
<NextStatement exception="Function has expired" /> <NextStatement exception="StackFrame has expired" />
<ThisValue exception="Static method does not have 'this'." /> <ThisValue exception="Static method does not have 'this'." />
<ContaingClassVariables> <ContaingClassVariables>
<ValueCollection> <ValueCollection>
@ -269,7 +269,7 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</ContaingClassVariables> </ContaingClassVariables>
<ArgumentCount exception="Function has expired" /> <ArgumentCount exception="StackFrame has expired" />
<Arguments> <Arguments>
<ValueCollection> <ValueCollection>
<Count>1</Count> <Count>1</Count>
@ -298,7 +298,7 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<ProcessExited /> <ProcessExited />
</Test> </Test>

6
src/AddIns/Misc/Debugger/Debugger.Tests/Project/Src/TestPrograms/FunctionLocalVariables.xml

@ -5,8 +5,8 @@
<ModuleLoaded symbols="False">mscorlib.dll</ModuleLoaded> <ModuleLoaded symbols="False">mscorlib.dll</ModuleLoaded>
<ModuleLoaded symbols="True">FunctionLocalVariables.exe</ModuleLoaded> <ModuleLoaded symbols="True">FunctionLocalVariables.exe</ModuleLoaded>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -117,7 +117,7 @@
</Items> </Items>
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<ProcessExited /> <ProcessExited />
</Test> </Test>

48
src/AddIns/Misc/Debugger/Debugger.Tests/Project/Src/TestPrograms/Generics.xml

@ -5,8 +5,8 @@
<ModuleLoaded symbols="False">mscorlib.dll</ModuleLoaded> <ModuleLoaded symbols="False">mscorlib.dll</ModuleLoaded>
<ModuleLoaded symbols="True">Generics.exe</ModuleLoaded> <ModuleLoaded symbols="True">Generics.exe</ModuleLoaded>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -88,11 +88,11 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -174,11 +174,11 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -244,11 +244,11 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -314,11 +314,11 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -379,11 +379,11 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -444,11 +444,11 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -514,11 +514,11 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -584,7 +584,7 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ProcessExited /> <ProcessExited />

54
src/AddIns/Misc/Debugger/Debugger.Tests/Project/Src/TestPrograms/Stepping.xml

@ -6,8 +6,8 @@
<ModuleLoaded symbols="True">Stepping.exe</ModuleLoaded> <ModuleLoaded symbols="True">Stepping.exe</ModuleLoaded>
<ModuleLoaded symbols="False">System.dll</ModuleLoaded> <ModuleLoaded symbols="False">System.dll</ModuleLoaded>
<DebuggingPaused>Break</DebuggingPaused> <DebuggingPaused>Break</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -42,11 +42,11 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>StepComplete</DebuggingPaused> <DebuggingPaused>StepComplete</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -81,14 +81,14 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<ModuleLoaded symbols="False">System.Configuration.dll</ModuleLoaded> <ModuleLoaded symbols="False">System.Configuration.dll</ModuleLoaded>
<ModuleLoaded symbols="False">System.Xml.dll</ModuleLoaded> <ModuleLoaded symbols="False">System.Xml.dll</ModuleLoaded>
<LogMessage>1\r\n</LogMessage> <LogMessage>1\r\n</LogMessage>
<DebuggingPaused>StepComplete</DebuggingPaused> <DebuggingPaused>StepComplete</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -123,11 +123,11 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>StepComplete</DebuggingPaused> <DebuggingPaused>StepComplete</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -162,11 +162,11 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>StepComplete</DebuggingPaused> <DebuggingPaused>StepComplete</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -201,12 +201,12 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<LogMessage>2\r\n</LogMessage> <LogMessage>2\r\n</LogMessage>
<DebuggingPaused>StepComplete</DebuggingPaused> <DebuggingPaused>StepComplete</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -241,13 +241,13 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<LogMessage>3\r\n</LogMessage> <LogMessage>3\r\n</LogMessage>
<LogMessage>4\r\n</LogMessage> <LogMessage>4\r\n</LogMessage>
<DebuggingPaused>StepComplete</DebuggingPaused> <DebuggingPaused>StepComplete</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -282,11 +282,11 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<DebuggingPaused>StepComplete</DebuggingPaused> <DebuggingPaused>StepComplete</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -321,12 +321,12 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<LogMessage>5\r\n</LogMessage> <LogMessage>5\r\n</LogMessage>
<DebuggingPaused>StepComplete</DebuggingPaused> <DebuggingPaused>StepComplete</DebuggingPaused>
<ObjectDump name="SelectedFunction"> <ObjectDump name="SelectedStackFrame">
<Function> <StackFrame>
<MethodInfo> <MethodInfo>
<MethodInfo> <MethodInfo>
<IsPrivate>False</IsPrivate> <IsPrivate>False</IsPrivate>
@ -361,7 +361,7 @@
<Items /> <Items />
</ValueCollection> </ValueCollection>
</LocalVariables> </LocalVariables>
</Function> </StackFrame>
</ObjectDump> </ObjectDump>
<ProcessExited /> <ProcessExited />
</Test> </Test>

Loading…
Cancel
Save