Browse Source

Fix NullReferenceException in XmlDocKeyProvider when decompiling C++/CLI code. Closes #173.

pull/194/merge
Daniel Grunwald 15 years ago
parent
commit
a15ecd533b
  1. 4
      ILSpy/XmlDoc/XmlDocKeyProvider.cs

4
ILSpy/XmlDoc/XmlDocKeyProvider.cs

@ -79,6 +79,10 @@ namespace ICSharpCode.ILSpy.XmlDoc @@ -79,6 +79,10 @@ namespace ICSharpCode.ILSpy.XmlDoc
static void AppendTypeName(StringBuilder b, TypeReference type)
{
if (type == null) {
// could happen when a TypeSpecification has no ElementType; e.g. function pointers in C++/CLI assemblies
return;
}
if (type is GenericInstanceType) {
GenericInstanceType giType = (GenericInstanceType)type;
if (type.DeclaringType != null) {

Loading…
Cancel
Save