Browse Source

Include property and event return types in `RequiredNamespaceCollector`

pull/2843/head
ElektroKill 3 years ago
parent
commit
cd3d23e406
No known key found for this signature in database
GPG Key ID: 7E3C5C084E40E3EC
  1. 2
      ICSharpCode.Decompiler/CSharp/RequiredNamespaceCollector.cs

2
ICSharpCode.Decompiler/CSharp/RequiredNamespaceCollector.cs

@ -137,11 +137,13 @@ namespace ICSharpCode.Decompiler.CSharp
break; break;
case IProperty property: case IProperty property:
HandleAttributes(property.GetAttributes()); HandleAttributes(property.GetAttributes());
CollectNamespacesForTypeReference(property.ReturnType);
CollectNamespaces(property.Getter, module, mappingInfo); CollectNamespaces(property.Getter, module, mappingInfo);
CollectNamespaces(property.Setter, module, mappingInfo); CollectNamespaces(property.Setter, module, mappingInfo);
break; break;
case IEvent @event: case IEvent @event:
HandleAttributes(@event.GetAttributes()); HandleAttributes(@event.GetAttributes());
CollectNamespacesForTypeReference(@event.ReturnType);
CollectNamespaces(@event.AddAccessor, module, mappingInfo); CollectNamespaces(@event.AddAccessor, module, mappingInfo);
CollectNamespaces(@event.RemoveAccessor, module, mappingInfo); CollectNamespaces(@event.RemoveAccessor, module, mappingInfo);
break; break;

Loading…
Cancel
Save