diff --git a/Debugger/ILSpy.Debugger/ILSpy.Debugger.csproj b/Debugger/ILSpy.Debugger/ILSpy.Debugger.csproj
index 897214855..80f4efa04 100644
--- a/Debugger/ILSpy.Debugger/ILSpy.Debugger.csproj
+++ b/Debugger/ILSpy.Debugger/ILSpy.Debugger.csproj
@@ -87,7 +87,6 @@
-
diff --git a/Debugger/ILSpy.Debugger/Services/Debugger/DebuggerHelper.cs b/Debugger/ILSpy.Debugger/Services/Debugger/DebuggerHelper.cs
index abaf37995..b4445c7e7 100644
--- a/Debugger/ILSpy.Debugger/Services/Debugger/DebuggerHelper.cs
+++ b/Debugger/ILSpy.Debugger/Services/Debugger/DebuggerHelper.cs
@@ -12,7 +12,7 @@ using ICSharpCode.NRefactory.CSharp;
namespace ICSharpCode.ILSpy.Debugger.Services.Debugger
{
- public static class DebuggerHelpers
+ static class DebuggerHelpers
{
///
/// Creates an expression which, when evaluated, creates a List<T> in the debugee
diff --git a/Debugger/ILSpy.Debugger/Services/Debugger/DefaultDebugger.cs b/Debugger/ILSpy.Debugger/Services/Debugger/DefaultDebugger.cs
deleted file mode 100644
index 66301471e..000000000
--- a/Debugger/ILSpy.Debugger/Services/Debugger/DefaultDebugger.cs
+++ /dev/null
@@ -1,188 +0,0 @@
-// Copyright (c) AlphaSierraPapa for the SharpDevelop Team (for details please see \doc\copyright.txt)
-// This code is distributed under the GNU LGPL (for details please see \doc\license.txt)
-
-using System;
-using System.Diagnostics;
-using System.Threading;
-
-using ICSharpCode.NRefactory;
-
-namespace ILSpy.Debugger.Services
-{
- public class DefaultDebugger : IDebugger
- {
- Process attachedProcess = null;
-
- public bool IsDebugging {
- get {
- return attachedProcess != null;
- }
- }
-
- public bool IsProcessRunning {
- get {
- return IsDebugging;
- }
- }
-
- ///
- public bool BreakAtBeginning {
- get; set;
- }
-
- public void Start(ProcessStartInfo processStartInfo)
- {
- if (attachedProcess != null) {
- return;
- }
-
- OnDebugStarting(EventArgs.Empty);
- try {
- attachedProcess = new Process();
- attachedProcess.StartInfo = processStartInfo;
- attachedProcess.Exited += new EventHandler(AttachedProcessExited);
- attachedProcess.EnableRaisingEvents = true;
- attachedProcess.Start();
- OnDebugStarted(EventArgs.Empty);
- } catch (Exception) {
- OnDebugStopped(EventArgs.Empty);
- throw new ApplicationException("Can't execute \"" + processStartInfo.FileName + "\"\n");
- }
- }
-
- public void ShowAttachDialog()
- {
- }
-
- public void Attach(Process process)
- {
- }
-
- public void Detach()
- {
- }
-
- void AttachedProcessExited(object sender, EventArgs e)
- {
- attachedProcess.Exited -= new EventHandler(AttachedProcessExited);
- attachedProcess.Dispose();
- attachedProcess = null;
- OnDebugStopped(EventArgs.Empty);
- }
-
- public void StartWithoutDebugging(ProcessStartInfo processStartInfo)
- {
- Process.Start(processStartInfo);
- }
-
- public void Stop()
- {
- if (attachedProcess != null) {
- attachedProcess.Exited -= new EventHandler(AttachedProcessExited);
- attachedProcess.Kill();
- attachedProcess.Close();
- attachedProcess.Dispose();
- attachedProcess = null;
- }
- }
-
- // ExecutionControl:
-
- public void Break()
- {
- throw new NotSupportedException();
- }
-
- public void Continue()
- {
- throw new NotSupportedException();
- }
- // Stepping:
-
- public void StepInto()
- {
- throw new NotSupportedException();
- }
-
- public void StepOver()
- {
- throw new NotSupportedException();
- }
-
- public void StepOut()
- {
- throw new NotSupportedException();
- }
-
- ///
- /// Gets the current value of the variable as string that can be displayed in tooltips.
- ///
- public string GetValueAsString(string variable)
- {
- return null;
- }
-
- ///
- /// Gets the tooltip control that shows the value of given variable.
- /// Return null if no tooltip is available.
- ///
- public object GetTooltipControl(Location logicalPosition, string variable)
- {
- return null;
- }
-
- public bool CanSetInstructionPointer(string filename, int line, int column)
- {
- return false;
- }
-
- public bool SetInstructionPointer(string filename, int line, int column)
- {
- return false;
- }
-
-
- public event EventHandler DebugStarted;
-
- protected virtual void OnDebugStarted(EventArgs e)
- {
- if (DebugStarted != null) {
- DebugStarted(this, e);
- }
- }
-
-
- public event EventHandler IsProcessRunningChanged;
-
- protected virtual void OnIsProcessRunningChanged(EventArgs e)
- {
- if (IsProcessRunningChanged != null) {
- IsProcessRunningChanged(this, e);
- }
- }
-
-
- public event EventHandler DebugStopped;
-
- protected virtual void OnDebugStopped(EventArgs e)
- {
- if (DebugStopped != null) {
- DebugStopped(this, e);
- }
- }
-
- public event EventHandler DebugStarting;
-
- protected virtual void OnDebugStarting(EventArgs e)
- {
- if (DebugStarting != null) {
- DebugStarting(this, e);
- }
- }
-
- public void Dispose()
- {
- Stop();
- }
- }
-}
diff --git a/Debugger/ILSpy.Debugger/Services/Debugger/ListHelper.cs b/Debugger/ILSpy.Debugger/Services/Debugger/ListHelper.cs
index c56e5acb3..1b08d76a2 100644
--- a/Debugger/ILSpy.Debugger/Services/Debugger/ListHelper.cs
+++ b/Debugger/ILSpy.Debugger/Services/Debugger/ListHelper.cs
@@ -9,7 +9,7 @@ namespace ICSharpCode.ILSpy.Debugger.Services.Debugger
/// ListHelper wraps System.Collection.Generic.List methods to return the original list,
/// instead of returning 'void', so we can write eg. list.Sorted().First()
///
- public static class ListHelper
+ static class ListHelper
{
public static List Sorted(this List list, IComparer comparer)
{
diff --git a/Debugger/ILSpy.Debugger/Services/Debugger/RemotingConfigurationHelpper.cs b/Debugger/ILSpy.Debugger/Services/Debugger/RemotingConfigurationHelpper.cs
deleted file mode 100644
index 2649d74f7..000000000
--- a/Debugger/ILSpy.Debugger/Services/Debugger/RemotingConfigurationHelpper.cs
+++ /dev/null
@@ -1,81 +0,0 @@
-// Copyright (c) AlphaSierraPapa for the SharpDevelop Team (for details please see \doc\copyright.txt)
-// This code is distributed under the GNU LGPL (for details please see \doc\license.txt)
-using System;
-using System.IO;
-using System.Reflection;
-using System.Runtime.Remoting;
-using System.Security.Policy;
-
-namespace ICSharpCode.ILSpy.Debugger.Services.Debugger
-{
- [Serializable]
- class RemotingConfigurationHelpper
- {
- public string path;
-
- public RemotingConfigurationHelpper(string path)
- {
- this.path = path;
- }
-
- public static string GetLoadedAssemblyPath(string assemblyName)
- {
- string path = null;
- foreach (Assembly assembly in AppDomain.CurrentDomain.GetAssemblies()) {
- try {
- string fullFilename = assembly.Location;
- if (Path.GetFileName(fullFilename).Equals(assemblyName, StringComparison.OrdinalIgnoreCase)) {
- path = Path.GetDirectoryName(fullFilename);
- break;
- }
- } catch (NotSupportedException) {
- // assembly.Location throws NotSupportedException for assemblies emitted using
- // Reflection.Emit by custom controls used in the forms designer
- }
- }
- if (path == null) {
- throw new Exception("Assembly " + assemblyName + " is not loaded");
- }
- return path;
- }
-
- public void Configure()
- {
- AppDomain.CurrentDomain.AssemblyResolve += AssemblyResolve;
-
- RemotingConfiguration.Configure(Path.Combine(path, "Client.config"), false);
-
- string baseDir = Directory.GetDirectoryRoot(AppDomain.CurrentDomain.BaseDirectory);
- string relDirs = AppDomain.CurrentDomain.BaseDirectory + ";" + path;
- AppDomain serverAppDomain = AppDomain.CreateDomain("Debugging server",
- new Evidence(AppDomain.CurrentDomain.Evidence),
- baseDir,
- relDirs,
- AppDomain.CurrentDomain.ShadowCopyFiles);
- serverAppDomain.DoCallBack(new CrossAppDomainDelegate(ConfigureServer));
- }
-
- private void ConfigureServer()
- {
- AppDomain.CurrentDomain.AssemblyResolve += AssemblyResolve;
- RemotingConfiguration.Configure(Path.Combine(path, "Server.config"), false);
- }
-
- Assembly AssemblyResolve(object sender, ResolveEventArgs args)
- {
- foreach (Assembly assembly in AppDomain.CurrentDomain.GetAssemblies()) {
- try {
- string fullFilename = assembly.Location;
- if (Path.GetFileNameWithoutExtension(fullFilename).Equals(args.Name, StringComparison.OrdinalIgnoreCase) ||
- assembly.FullName == args.Name) {
- return assembly;
- }
- } catch (NotSupportedException) {
- // assembly.Location throws NotSupportedException for assemblies emitted using
- // Reflection.Emit by custom controls used in the forms designer
- }
- }
- return null;
- }
- }
-}
diff --git a/Debugger/ILSpy.Debugger/Services/Debugger/TypeResolverExtension.cs b/Debugger/ILSpy.Debugger/Services/Debugger/TypeResolverExtension.cs
index 01a61d431..160bb490a 100644
--- a/Debugger/ILSpy.Debugger/Services/Debugger/TypeResolverExtension.cs
+++ b/Debugger/ILSpy.Debugger/Services/Debugger/TypeResolverExtension.cs
@@ -11,7 +11,7 @@ namespace ICSharpCode.ILSpy.Debugger.Services.Debugger
///
/// Helper for obtaining information about DebugType.
///
- public static class TypeResolverExtension
+ static class TypeResolverExtension
{
///
/// Gets generic interface this type implements.
diff --git a/Debugger/ILSpy.Debugger/Services/Debugger/WindowsDebugger.cs b/Debugger/ILSpy.Debugger/Services/Debugger/WindowsDebugger.cs
index 93f9990e6..7935348a9 100644
--- a/Debugger/ILSpy.Debugger/Services/Debugger/WindowsDebugger.cs
+++ b/Debugger/ILSpy.Debugger/Services/Debugger/WindowsDebugger.cs
@@ -34,13 +34,9 @@ namespace ICSharpCode.ILSpy.Debugger.Services
Cancel = 2
}
- bool useRemotingForThreadInterop = false;
bool attached;
-
NDebugger debugger;
-
ICorPublish corPublish;
-
Process debuggedProcess;
//DynamicTreeDebuggerRow currentTooltipRow;
@@ -512,12 +508,6 @@ namespace ICSharpCode.ILSpy.Debugger.Services
public void InitializeService()
{
- if (useRemotingForThreadInterop) {
- // This needs to be called before instance of NDebugger is created
- string path = RemotingConfigurationHelpper.GetLoadedAssemblyPath("Debugger.Core.dll");
- new RemotingConfigurationHelpper(path).Configure();
- }
-
debugger = new NDebugger();
//debugger.Options = DebuggingOptions.Instance;
diff --git a/Debugger/ILSpy.Debugger/Services/ExtensionMethods.cs b/Debugger/ILSpy.Debugger/Services/ExtensionMethods.cs
index 720434589..3ee49f1d8 100644
--- a/Debugger/ILSpy.Debugger/Services/ExtensionMethods.cs
+++ b/Debugger/ILSpy.Debugger/Services/ExtensionMethods.cs
@@ -19,9 +19,9 @@ using Mono.Cecil;
namespace ICSharpCode.ILSpy.Debugger.Services
{
///
- /// Extension methods used in SharpDevelop.
+ /// Extension methods used in ILSpy debugger.
///
- public static class ExtensionMethods
+ static class ExtensionMethods
{
///
/// Raises the event.
diff --git a/ILSpy.sln b/ILSpy.sln
index 93390f94a..cb21371b9 100644
--- a/ILSpy.sln
+++ b/ILSpy.sln
@@ -1,15 +1,15 @@
Microsoft Visual Studio Solution File, Format Version 11.00
# Visual Studio 2010
-# SharpDevelop 4.1.0.7383-alpha
+# SharpDevelop 4.1.0.7414-alpha
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Debugger", "Debugger", "{1DEB3B4E-03AC-437C-821D-B09FBFCC3E5B}"
ProjectSection(SolutionItems) = postProject
EndProjectSection
EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ILSpy.Debugger", "Debugger\ILSpy.Debugger\ILSpy.Debugger.csproj", "{6D3D0F0D-348D-456A-A6ED-E9BD5EFABB6A}"
-EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Debugger.Core", "Debugger\Debugger.Core\Debugger.Core.csproj", "{1D18D788-F7EE-4585-A23B-34DC8EC63CB8}"
EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ILSpy.Debugger", "Debugger\ILSpy.Debugger\ILSpy.Debugger.csproj", "{6D3D0F0D-348D-456A-A6ED-E9BD5EFABB6A}"
+EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ILSpy", "ILSpy\ILSpy.csproj", "{1E85EFF9-E370-4683-83E4-8A3D063FF791}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ICSharpCode.TreeView", "SharpTreeView\ICSharpCode.TreeView.csproj", "{DDE2A481-8271-4EAC-A330-8FA6A38D13D1}"
@@ -129,7 +129,7 @@ Global
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
- {1D18D788-F7EE-4585-A23B-34DC8EC63CB8} = {1DEB3B4E-03AC-437C-821D-B09FBFCC3E5B}
{6D3D0F0D-348D-456A-A6ED-E9BD5EFABB6A} = {1DEB3B4E-03AC-437C-821D-B09FBFCC3E5B}
+ {1D18D788-F7EE-4585-A23B-34DC8EC63CB8} = {1DEB3B4E-03AC-437C-821D-B09FBFCC3E5B}
EndGlobalSection
EndGlobal
diff --git a/ILSpy/CSharpLanguage.cs b/ILSpy/CSharpLanguage.cs
index 453892a20..0f1cc6e19 100644
--- a/ILSpy/CSharpLanguage.cs
+++ b/ILSpy/CSharpLanguage.cs
@@ -23,7 +23,6 @@ using System.ComponentModel.Composition;
using System.IO;
using System.Linq;
using System.Resources;
-using System.Text;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
using System.Xaml;
@@ -33,7 +32,6 @@ using ICSharpCode.Decompiler;
using ICSharpCode.Decompiler.Ast;
using ICSharpCode.Decompiler.Ast.Transforms;
using ICSharpCode.ILSpy.Baml;
-using ICSharpCode.ILSpy.Debugger;
using ICSharpCode.NRefactory.CSharp;
using Mono.Cecil;
diff --git a/ILSpy/ILLanguage.cs b/ILSpy/ILLanguage.cs
index 030a5d13f..7097fd26c 100644
--- a/ILSpy/ILLanguage.cs
+++ b/ILSpy/ILLanguage.cs
@@ -18,11 +18,8 @@
using System;
using System.Collections.Generic;
-using System.IO;
-
using ICSharpCode.Decompiler;
using ICSharpCode.Decompiler.Disassembler;
-using ICSharpCode.ILSpy.Debugger;
using Mono.Cecil;
namespace ICSharpCode.ILSpy
diff --git a/ILSpy/MainWindow.xaml.cs b/ILSpy/MainWindow.xaml.cs
index 58add211b..b59b5bd1e 100644
--- a/ILSpy/MainWindow.xaml.cs
+++ b/ILSpy/MainWindow.xaml.cs
@@ -32,15 +32,11 @@ using System.Windows.Interop;
using System.Windows.Media;
using System.Windows.Media.Imaging;
-
-using ICSharpCode.Decompiler;
+using ICSharpCode.ILSpy.Debugger.Services;
using ICSharpCode.ILSpy.TextView;
using ICSharpCode.ILSpy.TreeNodes;
-using ICSharpCode.ILSpy.TreeNodes.Analyzer;
using ICSharpCode.ILSpy.XmlDoc;
using ICSharpCode.TreeView;
-using ICSharpCode.ILSpy.Debugger;
-using ICSharpCode.ILSpy.Debugger.Services;
using Microsoft.Win32;
using Mono.Cecil;
diff --git a/ILSpy/TreeNodes/MethodTreeNode.cs b/ILSpy/TreeNodes/MethodTreeNode.cs
index d329830e8..6435cbfb7 100644
--- a/ILSpy/TreeNodes/MethodTreeNode.cs
+++ b/ILSpy/TreeNodes/MethodTreeNode.cs
@@ -21,7 +21,6 @@ using System.Text;
using System.Windows.Media;
using ICSharpCode.Decompiler;
-using ICSharpCode.ILSpy.Debugger;
using Mono.Cecil;
namespace ICSharpCode.ILSpy.TreeNodes
diff --git a/ILSpy/TreeNodes/PropertyTreeNode.cs b/ILSpy/TreeNodes/PropertyTreeNode.cs
index 5f6333485..2ead5dc71 100644
--- a/ILSpy/TreeNodes/PropertyTreeNode.cs
+++ b/ILSpy/TreeNodes/PropertyTreeNode.cs
@@ -19,7 +19,6 @@
using System;
using System.Windows.Media;
using ICSharpCode.Decompiler;
-using ICSharpCode.ILSpy.Debugger;
using Mono.Cecil;
namespace ICSharpCode.ILSpy.TreeNodes
diff --git a/ILSpy/TreeNodes/TypeTreeNode.cs b/ILSpy/TreeNodes/TypeTreeNode.cs
index e5b6214c5..23bce5df7 100644
--- a/ILSpy/TreeNodes/TypeTreeNode.cs
+++ b/ILSpy/TreeNodes/TypeTreeNode.cs
@@ -22,8 +22,6 @@ using System.Linq;
using System.Windows.Media;
using ICSharpCode.Decompiler;
-using ICSharpCode.ILSpy.Debugger;
-using ICSharpCode.ILSpy.Debugger.AvalonEdit;
using Mono.Cecil;
namespace ICSharpCode.ILSpy.TreeNodes