Browse Source

Add information about debug info source to ILSpy UI.

pull/1030/head
Siegfried Pammer 8 years ago
parent
commit
2e5ed08be4
  1. 4
      ILSpy/Languages/CSharpLanguage.cs
  2. 4
      ILSpy/TreeNodes/AssemblyTreeNode.cs

4
ILSpy/Languages/CSharpLanguage.cs

@ -356,6 +356,10 @@ namespace ICSharpCode.ILSpy
if (runtimeName != null) { if (runtimeName != null) {
output.WriteLine("// Runtime: " + runtimeName); output.WriteLine("// Runtime: " + runtimeName);
} }
var debugInfo = assembly.GetDebugInfoOrNull();
if (debugInfo != null) {
output.WriteLine("// Debug info: " + debugInfo.Description);
}
output.WriteLine(); output.WriteLine();
CSharpDecompiler decompiler = new CSharpDecompiler(typeSystem, assemblyResolver, options.DecompilerSettings); CSharpDecompiler decompiler = new CSharpDecompiler(typeSystem, assemblyResolver, options.DecompilerSettings);

4
ILSpy/TreeNodes/AssemblyTreeNode.cs

@ -103,6 +103,10 @@ namespace ICSharpCode.ILSpy.TreeNodes
tooltip.Inlines.Add(new Bold(new Run("Runtime: "))); tooltip.Inlines.Add(new Bold(new Run("Runtime: ")));
tooltip.Inlines.Add(new Run(runtimeName)); tooltip.Inlines.Add(new Run(runtimeName));
} }
var debugInfo = LoadedAssembly.GetDebugInfoOrNull();
tooltip.Inlines.Add(new LineBreak());
tooltip.Inlines.Add(new Bold(new Run("Debug info: ")));
tooltip.Inlines.Add(new Run(debugInfo?.Description ?? "none"));
} }
return tooltip; return tooltip;

Loading…
Cancel
Save