diff --git a/ICSharpCode.Decompiler/TypeSystem/FullTypeName.cs b/ICSharpCode.Decompiler/TypeSystem/FullTypeName.cs index 9df4bf8a41..36712ee645 100644 --- a/ICSharpCode.Decompiler/TypeSystem/FullTypeName.cs +++ b/ICSharpCode.Decompiler/TypeSystem/FullTypeName.cs @@ -165,6 +165,22 @@ public string ReflectionName { } } + public string FullName { + get { + if (nestedTypes == null) + return topLevelType.Namespace + "." + topLevelType.Name; + StringBuilder b = new StringBuilder(topLevelType.Namespace); + b.Append('.'); + b.Append(topLevelType.Name); + foreach (NestedTypeName nt in nestedTypes) + { + b.Append('.'); + b.Append(nt.Name); + } + return b.ToString(); + } + } + /// /// Gets the total type parameter count. /// diff --git a/ICSharpCode.Decompiler/TypeSystem/Implementation/UnknownType.cs b/ICSharpCode.Decompiler/TypeSystem/Implementation/UnknownType.cs index 28a0f33b7e..9489194bf4 100644 --- a/ICSharpCode.Decompiler/TypeSystem/Implementation/UnknownType.cs +++ b/ICSharpCode.Decompiler/TypeSystem/Implementation/UnknownType.cs @@ -95,6 +95,10 @@ public override string ReflectionName { get { return namespaceKnown ? fullTypeName.ReflectionName : "?"; } } + public override string FullName { + get { return namespaceKnown ? fullTypeName.FullName : "?"; } + } + public FullTypeName FullTypeName => fullTypeName; public override int TypeParameterCount => fullTypeName.TypeParameterCount;